pub struct Extensions<'a> { /* private fields */ }Expand description
Holds data on all the Extensions which are active for a given evaluation.
Clone is cheap for this type.
Implementations§
Source§impl Extensions<'static>
impl Extensions<'static>
Sourcepub fn all_available() -> Extensions<'static>
pub fn all_available() -> Extensions<'static>
Get a new Extensions containing data on all the available extensions.
Sourcepub fn none() -> Extensions<'static>
pub fn none() -> Extensions<'static>
Get a new Extensions with no extensions enabled.
Source§impl<'a> Extensions<'a>
impl<'a> Extensions<'a>
Sourcepub fn specific_extensions(extensions: &'a [Extension]) -> Extensions<'a>
pub fn specific_extensions(extensions: &'a [Extension]) -> Extensions<'a>
Get a new Extensions with these specific extensions enabled.
Sourcepub fn func(&self, name: &Name) -> Result<&ExtensionFunction>
pub fn func(&self, name: &Name) -> Result<&ExtensionFunction>
Get the extension function with the given name, from these extensions.
Returns an error if the function is not defined by any extension, or if it is defined multiple times.
Trait Implementations§
Source§impl<'a> Clone for Extensions<'a>
impl<'a> Clone for Extensions<'a>
Source§fn clone(&self) -> Extensions<'a>
fn clone(&self) -> Extensions<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl<'a> Freeze for Extensions<'a>
impl<'a> !RefUnwindSafe for Extensions<'a>
impl<'a> Send for Extensions<'a>
impl<'a> Sync for Extensions<'a>
impl<'a> Unpin for Extensions<'a>
impl<'a> !UnwindSafe for Extensions<'a>
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> 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