pub struct Declared {
pub tables: Schema,
pub access: AccessMap,
pub privacy: TablePrivacyMap,
}Expand description
A venture’s [tables] section, in the three parts the API needs.
Fields§
§tables: SchemaThe tables themselves.
access: AccessMapWho may reach each one.
privacy: TablePrivacyMapWhat each one holds — read for the subject column, which is what
owner matches a caller against.
Implementations§
Source§impl Declared
impl Declared
Sourcepub fn into_apis(self) -> Vec<TableApi>
pub fn into_apis(self) -> Vec<TableApi>
The declared tables, ready to serve.
A table with no access level is left out rather than given
one. fz build refuses a manifest that omits one (#359), so this
cannot happen from a generated module; if it somehow does, a table
nobody can reach is the only safe answer, and a 404 is what a
caller gets. Defaulting to public-read here would publish it and
defaulting to admin would hide a real bug behind a plausible
refusal.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Declared
impl<'de> Deserialize<'de> for Declared
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
Auto Trait Implementations§
impl Freeze for Declared
impl RefUnwindSafe for Declared
impl Send for Declared
impl Sync for Declared
impl Unpin for Declared
impl UnsafeUnpin for Declared
impl UnwindSafe for Declared
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