Trait svc_assets::rest::structs::AssetsInfo
source · pub trait AssetsInfo {
// Required methods
fn basics(&self) -> Basics;
fn id(&self) -> Result<Uuid, Error>;
fn group_id(&self) -> Result<Option<Uuid>, Error>;
fn name(&self) -> String;
fn owner(&self) -> Result<Uuid, Error>;
fn created_at(&self) -> DateTime<Utc>;
fn updated_at(&self) -> DateTime<Utc>;
fn is_grouped(&self) -> bool;
fn is_public(&self) -> bool;
fn whitelist(&self) -> Result<Vec<Uuid>, Error>;
fn status(&self) -> AssetStatus;
}
Expand description
Get information about an asset.
This trait is implemented by all asset types.
Required Methods§
sourcefn created_at(&self) -> DateTime<Utc>
fn created_at(&self) -> DateTime<Utc>
Get the asset’s creation time.
sourcefn updated_at(&self) -> DateTime<Utc>
fn updated_at(&self) -> DateTime<Utc>
Get the asset’s last update time. If the asset has never been updated, this will return None.
sourcefn is_grouped(&self) -> bool
fn is_grouped(&self) -> bool
Check if the asset is grouped.
sourcefn whitelist(&self) -> Result<Vec<Uuid>, Error>
fn whitelist(&self) -> Result<Vec<Uuid>, Error>
Get the list of clients that have access to the asset.
sourcefn status(&self) -> AssetStatus
fn status(&self) -> AssetStatus
Get the status of the asset.