Struct revolt_models::v0::File
source · pub struct File {
pub id: String,
pub tag: String,
pub filename: String,
pub metadata: Metadata,
pub content_type: String,
pub size: isize,
pub deleted: Option<bool>,
pub reported: Option<bool>,
pub message_id: Option<String>,
pub user_id: Option<String>,
pub server_id: Option<String>,
pub object_id: Option<String>,
}Expand description
File
Fields§
§id: StringUnique Id
tag: StringTag / bucket this file was uploaded to
filename: StringOriginal filename
metadata: MetadataParsed metadata of this file
content_type: StringRaw content type of this file
size: isizeSize of this file (in bytes)
deleted: Option<bool>Whether this file was deleted
reported: Option<bool>Whether this file was reported
message_id: Option<String>§user_id: Option<String>§server_id: Option<String>§object_id: Option<String>Id of the object this file is associated with
Trait Implementations§
source§impl<'de> Deserialize<'de> for File
impl<'de> Deserialize<'de> for File
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 JsonSchema for File
impl JsonSchema for File
source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
source§fn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref keyword. Read moresource§impl PartialEq for File
impl PartialEq for File
impl Eq for File
impl StructuralEq for File
impl StructuralPartialEq for File
Auto Trait Implementations§
impl RefUnwindSafe for File
impl Send for File
impl Sync for File
impl Unpin for File
impl UnwindSafe for File
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more