[−][src]Struct aml::AmlName
Methods
impl AmlName
[src]
pub fn root() -> AmlName
[src]
pub fn from_name_seg(seg: NameSeg) -> AmlName
[src]
pub fn from_str(string: &str) -> Option<AmlName>
[src]
Convert a string representation of an AML name into an AmlName
. Returns None
if the
passed string is not a valid AML path.
pub fn as_string(&self) -> String
[src]
pub fn is_normal(&self) -> bool
[src]
An AML path is normal if it does not contain any prefix elements ("^" characters, when expressed as a string).
pub fn is_absolute(&self) -> bool
[src]
pub fn search_rules_apply(&self) -> bool
[src]
Special rules apply when searching for certain paths (specifically, those that are made up
of a single name segment). Returns true
if those rules apply.
pub fn normalize(self) -> Result<AmlName, AmlError>
[src]
Normalize an AML path, resolving prefix chars. Returns None
if the path normalizes to an
invalid path (e.g. \^_FOO
)
pub fn parent(&self) -> Result<AmlName, AmlError>
[src]
Get the parent of this AmlName
. For example, the parent of \_SB.PCI0._PRT
is \_SB.PCI0
. The root
path has no parent, and so returns None
.
pub fn resolve(&self, scope: &AmlName) -> Result<AmlName, AmlError>
[src]
Resolve this path against a given scope, making it absolute. If the path is absolute, it is returned directly. The path is also normalized.
Trait Implementations
impl Display for AmlName
[src]
impl Debug for AmlName
[src]
impl PartialEq<AmlName> for AmlName
[src]
impl Eq for AmlName
[src]
impl Ord for AmlName
[src]
fn cmp(&self, other: &AmlName) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
[src]
clamp
)Restrict a value to a certain interval. Read more
impl PartialOrd<AmlName> for AmlName
[src]
fn partial_cmp(&self, other: &AmlName) -> Option<Ordering>
[src]
fn lt(&self, other: &AmlName) -> bool
[src]
fn le(&self, other: &AmlName) -> bool
[src]
fn gt(&self, other: &AmlName) -> bool
[src]
fn ge(&self, other: &AmlName) -> bool
[src]
impl Clone for AmlName
[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,