pub struct FileMetadata {
pub file_id: String,
pub relative_path: String,
pub size: u64,
pub content_type: Option<String>,
pub original_filename: Option<String>,
pub created_at: DateTime<Utc>,
pub updated_at: DateTime<Utc>,
pub checksum: Option<String>,
pub stats: Option<FileStats>,
pub preview: Option<String>,
}Expand description
Pure filesystem metadata about a file - no artifact context
Fields§
§file_id: StringUnique file ID
relative_path: StringRelative path from filesystem base
size: u64File size in bytes
content_type: Option<String>Content type/mime type if known
original_filename: Option<String>Original filename if available
created_at: DateTime<Utc>When the file was created
updated_at: DateTime<Utc>When the file was last modified
checksum: Option<String>File checksum for integrity verification
stats: Option<FileStats>Rich statistics about the file content
preview: Option<String>Short preview of the content for context
Implementations§
Source§impl FileMetadata
impl FileMetadata
Sourcepub fn display_name(&self) -> String
pub fn display_name(&self) -> String
Get the full display name for this file
Sourcepub fn size_display(&self) -> String
pub fn size_display(&self) -> String
Get a human readable size string
Sourcepub fn is_text_file(&self) -> bool
pub fn is_text_file(&self) -> bool
Check if this appears to be a text file
Trait Implementations§
Source§impl Clone for FileMetadata
impl Clone for FileMetadata
Source§fn clone(&self) -> FileMetadata
fn clone(&self) -> FileMetadata
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileMetadata
impl Debug for FileMetadata
Source§impl<'de> Deserialize<'de> for FileMetadata
impl<'de> Deserialize<'de> for FileMetadata
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 FileMetadata
impl JsonSchema for FileMetadata
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(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for FileMetadata
impl PartialEq for FileMetadata
Source§impl Serialize for FileMetadata
impl Serialize for FileMetadata
impl StructuralPartialEq for FileMetadata
Auto Trait Implementations§
impl Freeze for FileMetadata
impl RefUnwindSafe for FileMetadata
impl Send for FileMetadata
impl Sync for FileMetadata
impl Unpin for FileMetadata
impl UnsafeUnpin for FileMetadata
impl UnwindSafe for FileMetadata
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