Enum swc_ecma_ast::TsEntityName[][src]

pub enum TsEntityName {
    TsQualifiedName(Box<TsQualifiedName>),
    Ident(Ident),
}

Variants

TsQualifiedName(Box<TsQualifiedName>)
Ident(Ident)

Implementations

impl TsEntityName[src]

pub fn is_ts_qualified_name(&self) -> bool[src]

Returns true if self is of variant TsQualifiedName.

pub fn expect_ts_qualified_name(self) -> Box<TsQualifiedName> where
    Self: Debug
[src]

Unwraps the value, yielding the content of TsQualifiedName.

Panics

Panics if the value is not TsQualifiedName, with a panic message including the content of self.

pub fn ts_qualified_name(self) -> Option<Box<TsQualifiedName>>[src]

Returns Some if self is of variant TsQualifiedName, and None otherwise.

pub fn is_ident(&self) -> bool[src]

Returns true if self is of variant Ident.

pub fn expect_ident(self) -> Ident where
    Self: Debug
[src]

Unwraps the value, yielding the content of Ident.

Panics

Panics if the value is not Ident, with a panic message including the content of self.

pub fn ident(self) -> Option<Ident>[src]

Returns Some if self is of variant Ident, and None otherwise.

Trait Implementations

impl Clone for TsEntityName[src]

impl Debug for TsEntityName[src]

impl<'de> Deserialize<'de> for TsEntityName[src]

impl Eq for TsEntityName[src]

impl EqIgnoreSpan for TsEntityName[src]

impl From<Box<TsQualifiedName, Global>> for TsEntityName[src]

impl From<Ident> for TsEntityName[src]

impl From<TsEntityName> for TsTypeQueryExpr[src]

impl From<TsEntityName> for TsModuleRef[src]

impl Hash for TsEntityName[src]

impl PartialEq<TsEntityName> for TsEntityName[src]

impl Serialize for TsEntityName[src]

impl Spanned for TsEntityName[src]

impl StructuralEq for TsEntityName[src]

impl StructuralPartialEq for TsEntityName[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Send for T where
    T: ?Sized
[src]

impl<T> Sync for T where
    T: ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.