pub struct OpenApiParameter {
pub name: String,
pub location: OpenApiParameterLocation,
pub required: bool,
pub schema: OpenApiSchema,
pub description: Option<String>,
}Expand description
OpenAPI parameter metadata.
Fields§
§name: String§location: OpenApiParameterLocation§required: bool§schema: OpenApiSchema§description: Option<String>Implementations§
Source§impl OpenApiParameter
impl OpenApiParameter
pub fn new( location: OpenApiParameterLocation, name: impl Into<String>, required: bool, schema: OpenApiSchema, ) -> Self
pub fn path(name: impl Into<String>, schema: OpenApiSchema) -> Self
pub fn query( name: impl Into<String>, required: bool, schema: OpenApiSchema, ) -> Self
pub fn header( name: impl Into<String>, required: bool, schema: OpenApiSchema, ) -> Self
pub fn with_description(self, description: impl Into<String>) -> Self
Trait Implementations§
Source§impl Clone for OpenApiParameter
impl Clone for OpenApiParameter
Source§fn clone(&self) -> OpenApiParameter
fn clone(&self) -> OpenApiParameter
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 OpenApiParameter
impl Debug for OpenApiParameter
Source§impl PartialEq for OpenApiParameter
impl PartialEq for OpenApiParameter
Source§fn eq(&self, other: &OpenApiParameter) -> bool
fn eq(&self, other: &OpenApiParameter) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for OpenApiParameter
impl Serialize for OpenApiParameter
impl StructuralPartialEq for OpenApiParameter
Auto Trait Implementations§
impl Freeze for OpenApiParameter
impl RefUnwindSafe for OpenApiParameter
impl Send for OpenApiParameter
impl Sync for OpenApiParameter
impl Unpin for OpenApiParameter
impl UnsafeUnpin for OpenApiParameter
impl UnwindSafe for OpenApiParameter
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