pub struct AssetInfo {
    pub asset_id: String,
    pub name: String,
    pub content: String,
    pub data_type: DataType,
    pub content_type: String,
}
Expand description

Struct representing an asset ready for upload. An AssetInfo can represent a physical file, in which case the content will correspond to the name of the file; or an in-memory asset, in which case the content will correspond to the content of the asset.

For example, for image files, the content contains the path of the file on the file system. In the case of json metadata files, the content contains the string representation of the json metadata.

Fields§

§asset_id: String

Id of the asset in the cache.

§name: String

Name (file name) of the asset.

§content: String

Content of the asset - either a file path or the string representation of the content.

§data_type: DataType

Type of the asset.

§content_type: String

MIME content type.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more