pub struct StyleStorage<T> {
pub entity_indices: Vec<Index>,
pub rule_indices: Vec<usize>,
pub data: Vec<T>,
pub inline_data: Vec<T>,
}Fields§
§entity_indices: Vec<Index>§rule_indices: Vec<usize>§data: Vec<T>§inline_data: Vec<T>Implementations§
Source§impl<T> StyleStorage<T>
impl<T> StyleStorage<T>
pub fn new() -> StyleStorage<T>
pub fn insert(&mut self, entity: Entity, value: T)
pub fn link(&mut self, entity: Entity, rule: usize) -> LinkType
pub fn unlink(&mut self, entity: Entity)
pub fn link_rule(&mut self, entity: Entity, rule_list: &Vec<usize>) -> bool
pub fn insert_rule(&mut self, rule: usize, value: T)
pub fn get(&self, entity: Entity) -> Option<&T>
pub fn get_mut(&mut self, entity: Entity) -> Option<&mut T>
pub fn get_rule_mut(&mut self, rule: usize) -> Option<&mut T>
pub fn set_rule(&mut self, rule: usize, value: T)
pub fn has_rule(&self, rule: usize) -> bool
pub fn remove_styles(&mut self)
Trait Implementations§
Source§impl<T> Clone for StyleStorage<T>where
T: Clone,
impl<T> Clone for StyleStorage<T>where
T: Clone,
Source§fn clone(&self) -> StyleStorage<T>
fn clone(&self) -> StyleStorage<T>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<T> Default for StyleStorage<T>where
T: Default,
impl<T> Default for StyleStorage<T>where
T: Default,
Source§fn default() -> StyleStorage<T>
fn default() -> StyleStorage<T>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<T> Freeze for StyleStorage<T>
impl<T> RefUnwindSafe for StyleStorage<T>where
T: RefUnwindSafe,
impl<T> Send for StyleStorage<T>where
T: Send,
impl<T> Sync for StyleStorage<T>where
T: Sync,
impl<T> Unpin for StyleStorage<T>where
T: Unpin,
impl<T> UnsafeUnpin for StyleStorage<T>
impl<T> UnwindSafe for StyleStorage<T>where
T: UnwindSafe,
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