pub struct Agent { /* private fields */ }Expand description
Structure that provides combined information about an individual derived from an outside service, such as a Directory Service.
Implementations§
Source§impl Agent
impl Agent
Sourcepub fn from_json_obj(map: Map<String, Value>) -> Result<Self, DataError>
pub fn from_json_obj(map: Map<String, Value>) -> Result<Self, DataError>
Construct and validate an Agent from a JSON Object.
Sourcepub fn builder() -> AgentBuilder
pub fn builder() -> AgentBuilder
Return an Agent Builder.
Sourcepub fn check_object_type(&self) -> bool
pub fn check_object_type(&self) -> bool
Return TRUE if the objectType property is as expected; FALSE otherwise.
Sourcepub fn name_as_str(&self) -> Option<&str>
pub fn name_as_str(&self) -> Option<&str>
Return name as a string reference if set; None otherwise.
Sourcepub fn mbox(&self) -> Option<&MyEmailAddress>
pub fn mbox(&self) -> Option<&MyEmailAddress>
Return mbox as an MyEmailAddress if set; None otherwise.
Sourcepub fn mbox_sha1sum(&self) -> Option<&str>
pub fn mbox_sha1sum(&self) -> Option<&str>
Return mbox_sha1sum field (hex-encoded SHA1 hash of this entity’s
mbox URI) if set; None otherwise.
Sourcepub fn openid(&self) -> Option<&UriStr>
pub fn openid(&self) -> Option<&UriStr>
Return openid field (openID URI of this entity) if set; None otherwise.
Sourcepub fn account(&self) -> Option<&Account>
pub fn account(&self) -> Option<&Account>
Return account field (reference to this entity’s Account) if set;
None otherwise.
Sourcepub fn equivalent(&self, that: &Agent) -> bool
pub fn equivalent(&self, that: &Agent) -> bool
Return TRUE if this is Equivalent to that; FALSE otherwise.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Agent
impl<'de> Deserialize<'de> for Agent
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
Source§impl Fingerprint for Agent
impl Fingerprint for Agent
Source§impl Ord for Agent
impl Ord for Agent
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for Agent
impl PartialOrd for Agent
Source§impl Validate for Agent
impl Validate for Agent
Source§fn validate(&self) -> Vec<ValidationError>
fn validate(&self) -> Vec<ValidationError>
Validate the instance and return a potentially empty collection of
ValidationError.
Source§fn is_valid(&self) -> bool
fn is_valid(&self) -> bool
Convenience method to quickly assert if the type implementing this
trait is indeed valid. Read more
Source§fn check_validity(&self) -> Result<(), ValidationError>
fn check_validity(&self) -> Result<(), ValidationError>
Convenience method that checks the validity of a Validate instance and
raises a ValidationError if it was found to be invalid.
impl Eq for Agent
impl StructuralPartialEq for Agent
Auto Trait Implementations§
impl Freeze for Agent
impl RefUnwindSafe for Agent
impl Send for Agent
impl Sync for Agent
impl Unpin for Agent
impl UnsafeUnpin for Agent
impl UnwindSafe for Agent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.