Struct modalkit::editing::store::BufferStore
source · pub struct BufferStore<I: ApplicationInfo> { /* private fields */ }
Expand description
Globally track allocated buffers.
Implementations§
source§impl<I> BufferStore<I>where
I: ApplicationInfo,
impl<I> BufferStore<I>where
I: ApplicationInfo,
sourcepub fn entry(
&mut self,
id: I::ContentId
) -> Entry<'_, I::ContentId, SharedBuffer<I>>
pub fn entry( &mut self, id: I::ContentId ) -> Entry<'_, I::ContentId, SharedBuffer<I>>
Get a buffer for storing the sub-content of a window.
sourcepub fn load(&mut self, id: I::ContentId) -> SharedBuffer<I>
pub fn load(&mut self, id: I::ContentId) -> SharedBuffer<I>
Get a buffer for storing the sub-content of a window.
sourcepub fn load_str(&mut self, id: I::ContentId, s: &str) -> SharedBuffer<I>
pub fn load_str(&mut self, id: I::ContentId, s: &str) -> SharedBuffer<I>
Get a buffer for storing the sub-content of a window; if it doesn’t exist yet, create one
whose initial contents are s
.
Trait Implementations§
source§impl<I> Default for BufferStore<I>where
I: ApplicationInfo,
impl<I> Default for BufferStore<I>where
I: ApplicationInfo,
Auto Trait Implementations§
impl<I> Freeze for BufferStore<I>
impl<I> RefUnwindSafe for BufferStore<I>
impl<I> Send for BufferStore<I>
impl<I> Sync for BufferStore<I>
impl<I> Unpin for BufferStore<I>
impl<I> UnwindSafe for BufferStore<I>
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