pub struct AttributeDef {
pub description: Option<String>,
pub attr_type: String,
pub required: bool,
pub default: Option<String>,
pub enum_values: Vec<String>,
pub pattern: Option<String>,
}Expand description
Attribute definition
Fields§
§description: Option<String>Human-readable description
attr_type: StringAttribute type: “string”, “integer”, “boolean”, “date”, “uri”, “enum”
required: boolWhether the attribute is required
default: Option<String>Default value
enum_values: Vec<String>Valid values if type is “enum”
pattern: Option<String>Regex pattern for validation
Trait Implementations§
Source§impl Clone for AttributeDef
impl Clone for AttributeDef
Source§fn clone(&self) -> AttributeDef
fn clone(&self) -> AttributeDef
Returns a duplicate of the value. Read more
1.0.0 · 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 AttributeDef
impl Debug for AttributeDef
Source§impl<'de> Deserialize<'de> for AttributeDef
impl<'de> Deserialize<'de> for AttributeDef
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
Auto Trait Implementations§
impl Freeze for AttributeDef
impl RefUnwindSafe for AttributeDef
impl Send for AttributeDef
impl Sync for AttributeDef
impl Unpin for AttributeDef
impl UnwindSafe for AttributeDef
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