pub struct SourcesFile {
pub schema: i64,
pub sources: BTreeMap<String, SourceRecord>,
pub extra: Table,
}Fields§
§schema: i64Schema version; always 1.
sources: BTreeMap<String, SourceRecord>Decisions by source key.
extra: TableImplementations§
Source§impl SourcesFile
impl SourcesFile
pub fn new() -> Self
Sourcepub fn validate(&self) -> Diagnostics
pub fn validate(&self) -> Diagnostics
Every key is a canonical source key (the key its own URL gets) whose shape fits its record’s scope.
Trait Implementations§
Source§impl Clone for SourcesFile
impl Clone for SourcesFile
Source§impl Debug for SourcesFile
impl Debug for SourcesFile
Source§impl Default for SourcesFile
impl Default for SourcesFile
Source§impl<'de> Deserialize<'de> for SourcesFile
impl<'de> Deserialize<'de> for SourcesFile
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 SourcesFile
impl JsonSchema for SourcesFile
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 SourcesFile
impl PartialEq for SourcesFile
Source§impl Serialize for SourcesFile
impl Serialize for SourcesFile
Source§impl StoreModel for SourcesFile
impl StoreModel for SourcesFile
Source§const SCHEMA_NAME: &'static str = "sources"
const SCHEMA_NAME: &'static str = "sources"
File stem of the generated JSON Schema:
docs/schema/<NAME>.schema.json.impl StructuralPartialEq for SourcesFile
Auto Trait Implementations§
impl Forget for SourcesFile
impl Freeze for SourcesFilewhere
*const LeafNode<String, SourceRecord> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, SourceRecord)>>: Freeze,
*const LeafNode<String, Value> is !null: Freeze,
PhantomData<Box<(String, Value)>>: Freeze,
impl Move for SourcesFile
impl RefUnwindSafe for SourcesFile
impl Send for SourcesFile
impl Sync for SourcesFile
impl Unpin for SourcesFile
impl UnsafeUnpin for SourcesFilewhere
*const LeafNode<String, SourceRecord> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, SourceRecord)>>: UnsafeUnpin,
*const LeafNode<String, Value> is !null: UnsafeUnpin,
PhantomData<Box<(String, Value)>>: UnsafeUnpin,
impl UnwindSafe for SourcesFile
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