pub struct FileFacts {
pub file_name: String,
pub origin: String,
pub size_bytes: Option<i64>,
pub filament: Option<Vec<ToolFilament>>,
pub successes: i64,
pub failures: i64,
pub last_print: Option<FilePrint>,
}Expand description
One file the printer holds, as its source describes it.
Fields§
§file_name: StringThe file’s name, as the source reported it.
origin: StringWhere the file lives, in the source’s own vocabulary.
size_bytes: Option<i64>The file’s size in bytes, when the source reported it.
filament: Option<Vec<ToolFilament>>The filament the source’s analysis of the file says each tool uses.
Absent when the file has no analysis: one still pending, or a file the source never analyses, such as one on an SD card.
successes: i64How many prints of the file completed, by the source’s own tally.
failures: i64How many prints of the file did not, by the source’s own tally.
last_print: Option<FilePrint>The file’s most recent print, when it has been printed.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for FileFacts
impl<'de> Deserialize<'de> for FileFacts
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 FileFacts
impl JsonSchema for FileFacts
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 Sample for FileFacts
impl Sample for FileFacts
Source§fn sample_full() -> Self
fn sample_full() -> Self
A value carrying every field the type declares.
Source§fn sample_minimal() -> Self
fn sample_minimal() -> Self
A value carrying every optional field absent.
Source§fn sample_alternates() -> Vec<Self>
fn sample_alternates() -> Vec<Self>
One value per further arm, for a type whose wire form is a union. Read more
impl StructuralPartialEq for FileFacts
Auto Trait Implementations§
impl Freeze for FileFacts
impl RefUnwindSafe for FileFacts
impl Send for FileFacts
impl Sync for FileFacts
impl Unpin for FileFacts
impl UnsafeUnpin for FileFacts
impl UnwindSafe for FileFacts
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