[][src]Struct activitystreams::activity::properties::ActorAndOriginProperties

pub struct ActorAndOriginProperties {
    pub actor: ActorAndOriginPropertiesActorEnum,
    pub origin: ActorAndOriginPropertiesOriginEnum,
}

Struct with actor and origin properties

Fields

actor: ActorAndOriginPropertiesActorEnum

Describes one or more entities that either performed or are expected to perform the activity.

Any single activity can have multiple actors. The actor MAY be specified using an indirect Link.

  • Range: Object | Link
  • Functional: false
origin: ActorAndOriginPropertiesOriginEnum

Describes an indirect object of the activity from which the activity is directed.

The precise meaning of the origin is the object of the English preposition "from". For instance, in the activity "John moved an item to List B from List A", the origin of the activity is "List A".

  • Range: Object | Link
  • Functional: false

Implementations

impl ActorAndOriginProperties[src]

pub fn get_actor_xsd_string(&self) -> Option<&XsdString>[src]

Get the actor as a XsdString

This returns None if

  • There is more than one value present
  • The requested type is not the stored type

pub fn set_actor_xsd_string<T>(
    &mut self,
    item: T
) -> Result<&mut Self, <T as TryInto<XsdString>>::Error> where
    T: TryInto<XsdString>, 
[src]

Set actor with a value that can be converted into XsdString

pub fn get_many_actor_xsd_strings(
    &self
) -> Option<impl Iterator<Item = &XsdString>>
[src]

Get actor as a vec of &XsdStrings

This returns None if

  • There is only one value present

The returned vec will be empty if no values match the requested type, but values are present.

pub fn set_many_actor_xsd_strings<T>(
    &mut self,
    item: Vec<T>
) -> Result<&mut Self, <T as TryInto<XsdString>>::Error> where
    T: TryInto<XsdString>, 
[src]

Set actor from a vec of items that can be converted into XsdStrings

pub fn get_actor_base_box(&self) -> Option<&BaseBox>[src]

Get the actor as a BaseBox

This returns None if

  • There is more than one value present
  • The requested type is not the stored type

pub fn set_actor_base_box<T>(
    &mut self,
    item: T
) -> Result<&mut Self, <T as TryInto<BaseBox>>::Error> where
    T: TryInto<BaseBox>, 
[src]

Set actor with a value that can be converted into BaseBox

pub fn get_many_actor_base_boxes(
    &self
) -> Option<impl Iterator<Item = &BaseBox>>
[src]

Get actor as a vec of &BaseBoxs

This returns None if

  • There is only one value present

The returned vec will be empty if no values match the requested type, but values are present.

pub fn set_many_actor_base_boxes<T>(
    &mut self,
    item: Vec<T>
) -> Result<&mut Self, <T as TryInto<BaseBox>>::Error> where
    T: TryInto<BaseBox>, 
[src]

Set actor from a vec of items that can be converted into BaseBoxs

pub fn get_origin_xsd_any_uri(&self) -> Option<&XsdAnyUri>[src]

Get the origin as a XsdAnyUri

This returns None if

  • There is more than one value present
  • The requested type is not the stored type

pub fn set_origin_xsd_any_uri<T>(
    &mut self,
    item: T
) -> Result<&mut Self, <T as TryInto<XsdAnyUri>>::Error> where
    T: TryInto<XsdAnyUri>, 
[src]

Set origin with a value that can be converted into XsdAnyUri

pub fn get_many_origin_xsd_any_uris(
    &self
) -> Option<impl Iterator<Item = &XsdAnyUri>>
[src]

Get origin as a vec of &XsdAnyUris

This returns None if

  • There is only one value present

The returned vec will be empty if no values match the requested type, but values are present.

pub fn set_many_origin_xsd_any_uris<T>(
    &mut self,
    item: Vec<T>
) -> Result<&mut Self, <T as TryInto<XsdAnyUri>>::Error> where
    T: TryInto<XsdAnyUri>, 
[src]

Set origin from a vec of items that can be converted into XsdAnyUris

pub fn get_origin_base_box(&self) -> Option<&BaseBox>[src]

Get the origin as a BaseBox

This returns None if

  • There is more than one value present
  • The requested type is not the stored type

pub fn set_origin_base_box<T>(
    &mut self,
    item: T
) -> Result<&mut Self, <T as TryInto<BaseBox>>::Error> where
    T: TryInto<BaseBox>, 
[src]

Set origin with a value that can be converted into BaseBox

pub fn get_many_origin_base_boxes(
    &self
) -> Option<impl Iterator<Item = &BaseBox>>
[src]

Get origin as a vec of &BaseBoxs

This returns None if

  • There is only one value present

The returned vec will be empty if no values match the requested type, but values are present.

pub fn set_many_origin_base_boxes<T>(
    &mut self,
    item: Vec<T>
) -> Result<&mut Self, <T as TryInto<BaseBox>>::Error> where
    T: TryInto<BaseBox>, 
[src]

Set origin from a vec of items that can be converted into BaseBoxs

Trait Implementations

impl AsMut<ActorAndOriginProperties> for Arrive[src]

impl AsRef<ActorAndOriginProperties> for Arrive[src]

impl Clone for ActorAndOriginProperties[src]

impl Debug for ActorAndOriginProperties[src]

impl Default for ActorAndOriginProperties[src]

impl<'de> Deserialize<'de> for ActorAndOriginProperties[src]

impl Serialize for ActorAndOriginProperties[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.