pub struct CatalogCustomAttributeValue {
pub name: Option<String>,
pub string_value: Option<String>,
pub custom_attribute_definition_id: Option<String>,
pub type: Option<CatalogCustomAttributeDefinitionType>,
pub number_value: Option<String>,
pub boolean_value: Option<bool>,
pub selection_uid_values: Option<Vec<String>>,
pub key: Option<String>,
}
Expand description
An instance of a custom attribute.
Custom attributes can be defined and added to ITEM
and ITEM_VARIATION
type catalog objects.
Read more about custom
attributes.
Fields
name: Option<String>
The name of the custom attribute.
string_value: Option<String>
The string value of the custom attribute. Populated if type
= STRING
.
custom_attribute_definition_id: Option<String>
Read-only. The id of the [CatalogCustomAttributeDefinition] this value belongs to.
type: Option<CatalogCustomAttributeDefinitionType>
Read-only. A copy of type from the associated CatalogCustomAttributeDefinition
.
number_value: Option<String>
Populated if type
= NUMBER
. Contains a string representation of a decimal number, using
a .
as the decimal separator.
boolean_value: Option<bool>
A true
or false
value. Populated if type
= BOOLEAN
.
selection_uid_values: Option<Vec<String>>
One or more choices from allowed_selections
. Populated if type
= SELECTION
.
key: Option<String>
Read-only. A copy of key from the associated CatalogCustomAttributeDefinition
.
Trait Implementations
sourceimpl Clone for CatalogCustomAttributeValue
impl Clone for CatalogCustomAttributeValue
sourcefn clone(&self) -> CatalogCustomAttributeValue
fn clone(&self) -> CatalogCustomAttributeValue
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for CatalogCustomAttributeValue
impl Debug for CatalogCustomAttributeValue
sourceimpl Default for CatalogCustomAttributeValue
impl Default for CatalogCustomAttributeValue
sourcefn default() -> CatalogCustomAttributeValue
fn default() -> CatalogCustomAttributeValue
Returns the “default value” for a type. Read more
sourceimpl<'de> Deserialize<'de> for CatalogCustomAttributeValue
impl<'de> Deserialize<'de> for CatalogCustomAttributeValue
sourcefn 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
sourceimpl PartialEq<CatalogCustomAttributeValue> for CatalogCustomAttributeValue
impl PartialEq<CatalogCustomAttributeValue> for CatalogCustomAttributeValue
sourcefn eq(&self, other: &CatalogCustomAttributeValue) -> bool
fn eq(&self, other: &CatalogCustomAttributeValue) -> bool
impl Eq for CatalogCustomAttributeValue
impl StructuralEq for CatalogCustomAttributeValue
impl StructuralPartialEq for CatalogCustomAttributeValue
Auto Trait Implementations
impl RefUnwindSafe for CatalogCustomAttributeValue
impl Send for CatalogCustomAttributeValue
impl Sync for CatalogCustomAttributeValue
impl Unpin for CatalogCustomAttributeValue
impl UnwindSafe for CatalogCustomAttributeValue
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.