pub struct HttpAnnotations {
pub method: HttpMethod,
pub path: String,
pub param_bindings: BTreeMap<String, HttpParamBinding>,
pub request_body_name: Option<String>,
pub status_codes: Vec<u16>,
pub auth: Option<AuthRequirement>,
pub tags: Vec<String>,
pub summary: Option<String>,
pub description: Option<String>,
}Expand description
Parsed HTTP metadata for a single SQL query.
Fields§
§method: HttpMethod§path: StringPath normalized to spikard’s canonical {name} form. Both :id and
{id} are accepted in source and emitted as {id}.
param_bindings: BTreeMap<String, HttpParamBinding>Explicit param-location overrides, keyed by parameter name. Names
absent from this map fall back to inference rules (see
bin_param_locations).
request_body_name: Option<String>Name of the bundled body object when multiple body params exist.
status_codes: Vec<u16>Status codes the route documents (defaults derived from the SQL
QueryCommand when empty).
auth: Option<AuthRequirement>§summary: Option<String>§description: Option<String>Trait Implementations§
Source§impl Clone for HttpAnnotations
impl Clone for HttpAnnotations
Source§fn clone(&self) -> HttpAnnotations
fn clone(&self) -> HttpAnnotations
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HttpAnnotations
impl Debug for HttpAnnotations
Source§impl<'de> Deserialize<'de> for HttpAnnotations
impl<'de> Deserialize<'de> for HttpAnnotations
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for HttpAnnotations
impl PartialEq for HttpAnnotations
Source§fn eq(&self, other: &HttpAnnotations) -> bool
fn eq(&self, other: &HttpAnnotations) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for HttpAnnotations
impl Serialize for HttpAnnotations
impl Eq for HttpAnnotations
impl StructuralPartialEq for HttpAnnotations
Auto Trait Implementations§
impl Freeze for HttpAnnotations
impl RefUnwindSafe for HttpAnnotations
impl Send for HttpAnnotations
impl Sync for HttpAnnotations
impl Unpin for HttpAnnotations
impl UnsafeUnpin for HttpAnnotations
impl UnwindSafe for HttpAnnotations
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.