pub struct PackNotes { /* private fields */ }Expand description
Pack notes for documentation and collaboration.
Notes are stored within the pack and include both pack-level notes (general documentation) and file-specific notes (annotations on individual files or tables). Notes are serialized as JSON and can be shared when the pack is distributed.
Implementations§
Source§impl PackNotes
impl PackNotes
Sourcepub fn pack_notes(&self) -> &String
pub fn pack_notes(&self) -> &String
General notes for the entire pack (Markdown format).
Source§impl PackNotes
impl PackNotes
Sourcepub fn pack_notes_mut(&mut self) -> &mut String
pub fn pack_notes_mut(&mut self) -> &mut String
General notes for the entire pack (Markdown format).
Source§impl PackNotes
impl PackNotes
Sourcepub fn set_pack_notes(&mut self, val: String) -> &mut Self
pub fn set_pack_notes(&mut self, val: String) -> &mut Self
General notes for the entire pack (Markdown format).
Source§impl PackNotes
impl PackNotes
Sourcepub fn load(data: &[u8]) -> Result<Self>
pub fn load(data: &[u8]) -> Result<Self>
This function tries to load the notes from the current Pack and return them.
Sourcepub fn notes_by_path(&self, path: &str) -> Vec<Note>
pub fn notes_by_path(&self, path: &str) -> Vec<Note>
This function returns all notes afecting the provided path.
Sourcepub fn add_note(&mut self, note: Note) -> Note
pub fn add_note(&mut self, note: Note) -> Note
This function adds a note for an specific path.
Note: for DB tables, notes are added for all tables with the same table name instead of specific tables.
Sourcepub fn delete_note(&mut self, path: &str, id: u64)
pub fn delete_note(&mut self, path: &str, id: u64)
This function deletes a note with the specified path and id.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for PackNotes
impl<'de> Deserialize<'de> for PackNotes
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>,
impl Eq for PackNotes
impl StructuralPartialEq for PackNotes
Auto Trait Implementations§
impl Freeze for PackNotes
impl RefUnwindSafe for PackNotes
impl Send for PackNotes
impl Sync for PackNotes
impl Unpin for PackNotes
impl UnsafeUnpin for PackNotes
impl UnwindSafe for PackNotes
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.