Struct selene_lib::standard_library::StandardLibrary
source · [−]pub struct StandardLibrary {
pub meta: Option<StandardLibraryMeta>,
pub globals: BTreeMap<String, Field>,
pub structs: BTreeMap<String, Field>,
}
Fields
meta: Option<StandardLibraryMeta>
globals: BTreeMap<String, Field>
structs: BTreeMap<String, Field>
Implementations
sourceimpl StandardLibrary
impl StandardLibrary
pub fn from_name(name: &str) -> Option<StandardLibrary>
pub fn from_config_name(
name: &str,
directory: Option<&Path>
) -> Result<Option<StandardLibrary>, StandardLibraryError>
pub fn from_file(
filename: &Path
) -> Result<Option<StandardLibrary>, StandardLibraryError>
pub fn find_global(&self, names: &[String]) -> Option<&Field>
pub fn unstruct<'a>(&'a self, field: &'a Field) -> &'a Field
pub fn extend(&mut self, other: StandardLibrary)
pub fn inflate(&mut self)
Trait Implementations
sourceimpl Clone for StandardLibrary
impl Clone for StandardLibrary
sourcefn clone(&self) -> StandardLibrary
fn clone(&self) -> StandardLibrary
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for StandardLibrary
impl Debug for StandardLibrary
sourceimpl Default for StandardLibrary
impl Default for StandardLibrary
sourcefn default() -> StandardLibrary
fn default() -> StandardLibrary
Returns the “default value” for a type. Read more
sourceimpl<'de> Deserialize<'de> for StandardLibrary
impl<'de> Deserialize<'de> for StandardLibrary
sourcefn 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
sourceimpl PartialEq<StandardLibrary> for StandardLibrary
impl PartialEq<StandardLibrary> for StandardLibrary
sourcefn eq(&self, other: &StandardLibrary) -> bool
fn eq(&self, other: &StandardLibrary) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &StandardLibrary) -> bool
fn ne(&self, other: &StandardLibrary) -> bool
This method tests for !=
.
sourceimpl Serialize for StandardLibrary
impl Serialize for StandardLibrary
impl Eq for StandardLibrary
impl StructuralEq for StandardLibrary
impl StructuralPartialEq for StandardLibrary
Auto Trait Implementations
impl RefUnwindSafe for StandardLibrary
impl Send for StandardLibrary
impl Sync for StandardLibrary
impl Unpin for StandardLibrary
impl UnwindSafe for StandardLibrary
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more