Enum swc_ecma_ast::TsTypeQueryExpr[][src]

pub enum TsTypeQueryExpr {
    TsEntityName(TsEntityName),
    Import(TsImportType),
}

Variants

TsEntityName(TsEntityName)
Import(TsImportType)

Implementations

impl TsTypeQueryExpr[src]

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

Returns true if self is of variant TsEntityName.

pub fn expect_ts_entity_name(self) -> TsEntityName where
    Self: Debug
[src]

Unwraps the value, yielding the content of TsEntityName.

Panics

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

pub fn ts_entity_name(self) -> Option<TsEntityName>[src]

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

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

Returns true if self is of variant Import.

pub fn expect_import(self) -> TsImportType where
    Self: Debug
[src]

Unwraps the value, yielding the content of Import.

Panics

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

pub fn import(self) -> Option<TsImportType>[src]

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

Trait Implementations

impl Clone for TsTypeQueryExpr[src]

impl Debug for TsTypeQueryExpr[src]

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

impl Eq for TsTypeQueryExpr[src]

impl EqIgnoreSpan for TsTypeQueryExpr[src]

impl From<TsEntityName> for TsTypeQueryExpr[src]

impl From<TsImportType> for TsTypeQueryExpr[src]

impl Hash for TsTypeQueryExpr[src]

impl PartialEq<TsTypeQueryExpr> for TsTypeQueryExpr[src]

impl Serialize for TsTypeQueryExpr[src]

impl Spanned for TsTypeQueryExpr[src]

impl StructuralEq for TsTypeQueryExpr[src]

impl StructuralPartialEq for TsTypeQueryExpr[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.