Struct utoipa::openapi::schema::ArrayBuilder
source · pub struct ArrayBuilder { /* private fields */ }
Implementations§
source§impl ArrayBuilder
impl ArrayBuilder
sourcepub fn new() -> ArrayBuilder
pub fn new() -> ArrayBuilder
Constructs a new ArrayBuilder
.
source§impl ArrayBuilder
impl ArrayBuilder
sourcepub fn title<I: Into<String>>(self, title: Option<I>) -> Self
pub fn title<I: Into<String>>(self, title: Option<I>) -> Self
Add or change the title of the Array
.
sourcepub fn description<I: Into<String>>(self, description: Option<I>) -> Self
pub fn description<I: Into<String>>(self, description: Option<I>) -> Self
Add or change description of the property. Markdown syntax is supported.
sourcepub fn deprecated(self, deprecated: Option<Deprecated>) -> Self
pub fn deprecated(self, deprecated: Option<Deprecated>) -> Self
Add or change deprecated status for Array
.
sourcepub fn example(self, example: Option<Value>) -> Self
pub fn example(self, example: Option<Value>) -> Self
Add or change example shown in UI of the value for richer documentation.
sourcepub fn default(self, default: Option<Value>) -> Self
pub fn default(self, default: Option<Value>) -> Self
Add or change default value for the object which is provided when user has not provided the input in Swagger UI.
sourcepub fn unique_items(self, unique_items: bool) -> Self
pub fn unique_items(self, unique_items: bool) -> Self
Set or change whether Array
should enforce all items to be unique.
sourcepub fn to_array_builder(self) -> ArrayBuilder
pub fn to_array_builder(self) -> ArrayBuilder
Construct a new ArrayBuilder
with this component set to ArrayBuilder::items
.
Trait Implementations§
source§impl Default for ArrayBuilder
impl Default for ArrayBuilder
source§impl From<Array> for ArrayBuilder
impl From<Array> for ArrayBuilder
source§impl From<ArrayBuilder> for Array
impl From<ArrayBuilder> for Array
source§fn from(value: ArrayBuilder) -> Self
fn from(value: ArrayBuilder) -> Self
Converts to this type from the input type.
source§impl From<ArrayBuilder> for RefOr<Schema>
impl From<ArrayBuilder> for RefOr<Schema>
source§fn from(array: ArrayBuilder) -> Self
fn from(array: ArrayBuilder) -> Self
Converts to this type from the input type.
source§impl From<ArrayBuilder> for Schema
impl From<ArrayBuilder> for Schema
source§fn from(builder: ArrayBuilder) -> Self
fn from(builder: ArrayBuilder) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ArrayBuilder
impl RefUnwindSafe for ArrayBuilder
impl Send for ArrayBuilder
impl Sync for ArrayBuilder
impl Unpin for ArrayBuilder
impl UnwindSafe for ArrayBuilder
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