pub struct Buffer {
pub elements: IndexMap<Uuid, Element>,
pub weak_images: WeakImages,
pub weak_path_pressures: WeakPathPressures,
pub weak_viewport_settings: WeakViewportSettings,
pub master_transform_changed: bool,
pub id_map: HashMap<Uuid, String>,
}Fields§
§elements: IndexMap<Uuid, Element>§weak_images: WeakImages§weak_path_pressures: WeakPathPressures§weak_viewport_settings: WeakViewportSettings§master_transform_changed: bool§id_map: HashMap<Uuid, String>Implementations§
Source§impl Buffer
impl Buffer
pub fn new(content: &str) -> Self
pub fn reload( local_elements: &mut IndexMap<Uuid, Element>, local_weak_images: &mut WeakImages, local_weak_pressures: &mut WeakPathPressures, local_viewport_settings: &mut WeakViewportSettings, base_buffer: &Self, remote_buffer: &Self, )
pub fn insert(&mut self, id: Uuid, el: Element)
pub fn hard_remove(&mut self, id: Uuid)
Sourcepub fn remove(&mut self, id: Uuid)
pub fn remove(&mut self, id: Uuid)
soft remove that marks the element as deleted but retains it in memeory
pub fn serialize(&self) -> String
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Buffer
impl RefUnwindSafe for Buffer
impl Send for Buffer
impl Sync for Buffer
impl Unpin for Buffer
impl UnsafeUnpin for Buffer
impl UnwindSafe for Buffer
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
Converts
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>
Converts
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