#[non_exhaustive]pub struct User {
pub attributes: Option<UserAttributes>,
pub id: Option<String>,
pub relationships: Option<UserResponseRelationships>,
pub type_: Option<UsersType>,
pub additional_properties: BTreeMap<String, Value>,
/* private fields */
}
Expand description
User object returned by the API.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.attributes: Option<UserAttributes>
Attributes of user object returned by the API.
id: Option<String>
ID of the user.
relationships: Option<UserResponseRelationships>
Relationships of the user object returned by the API.
type_: Option<UsersType>
Users resource type.
additional_properties: BTreeMap<String, Value>
Implementations§
Source§impl User
impl User
pub fn new() -> User
pub fn attributes(self, value: UserAttributes) -> Self
pub fn id(self, value: String) -> Self
pub fn relationships(self, value: UserResponseRelationships) -> Self
pub fn type_(self, value: UsersType) -> Self
pub fn additional_properties(self, value: BTreeMap<String, Value>) -> Self
Trait Implementations§
Source§impl<'de> Deserialize<'de> for User
impl<'de> Deserialize<'de> for User
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
impl StructuralPartialEq for User
Auto Trait Implementations§
impl Freeze for User
impl RefUnwindSafe for User
impl Send for User
impl Sync for User
impl Unpin for User
impl UnwindSafe for User
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