pub struct TypeAlias { /* private fields */ }Implementations§
Source§impl TypeAlias
impl TypeAlias
pub fn ty(&self) -> Option<Type>
pub fn semicolon_token(&self) -> Option<SyntaxToken<RustLanguage>>
pub fn eq_token(&self) -> Option<SyntaxToken<RustLanguage>>
pub fn default_token(&self) -> Option<SyntaxToken<RustLanguage>>
pub fn type_token(&self) -> Option<SyntaxToken<RustLanguage>>
Trait Implementations§
Source§impl AstNode for TypeAlias
impl AstNode for TypeAlias
Source§fn kind() -> SyntaxKind
fn kind() -> SyntaxKind
This panics if the
SyntaxKind is not statically known.fn can_cast(kind: SyntaxKind) -> bool
fn cast(syntax: SyntaxNode<RustLanguage>) -> Option<TypeAlias>
fn syntax(&self) -> &SyntaxNode<RustLanguage>
fn clone_for_update(&self) -> Selfwhere
Self: Sized,
fn clone_subtree(&self) -> Selfwhere
Self: Sized,
impl Eq for TypeAlias
Source§impl From<TypeAlias> for ExternItem
impl From<TypeAlias> for ExternItem
Source§fn from(node: TypeAlias) -> ExternItem
fn from(node: TypeAlias) -> ExternItem
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasAttrs
impl From<TypeAlias> for AnyHasAttrs
Source§fn from(node: TypeAlias) -> AnyHasAttrs
fn from(node: TypeAlias) -> AnyHasAttrs
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasDocComments
impl From<TypeAlias> for AnyHasDocComments
Source§fn from(node: TypeAlias) -> AnyHasDocComments
fn from(node: TypeAlias) -> AnyHasDocComments
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasGenericParams
impl From<TypeAlias> for AnyHasGenericParams
Source§fn from(node: TypeAlias) -> AnyHasGenericParams
fn from(node: TypeAlias) -> AnyHasGenericParams
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasName
impl From<TypeAlias> for AnyHasName
Source§fn from(node: TypeAlias) -> AnyHasName
fn from(node: TypeAlias) -> AnyHasName
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasTypeBounds
impl From<TypeAlias> for AnyHasTypeBounds
Source§fn from(node: TypeAlias) -> AnyHasTypeBounds
fn from(node: TypeAlias) -> AnyHasTypeBounds
Converts to this type from the input type.
Source§impl From<TypeAlias> for AnyHasVisibility
impl From<TypeAlias> for AnyHasVisibility
Source§fn from(node: TypeAlias) -> AnyHasVisibility
fn from(node: TypeAlias) -> AnyHasVisibility
Converts to this type from the input type.
Source§impl GetOrCreateWhereClause for TypeAlias
impl GetOrCreateWhereClause for TypeAlias
fn where_clause_position(&self) -> Option<Position>
fn get_or_create_where_clause( &self, editor: &SyntaxEditor, new_preds: impl Iterator<Item = WherePred>, )
Source§impl HasAttrs for TypeAlias
impl HasAttrs for TypeAlias
fn attrs(&self) -> AstChildren<Attr> ⓘ
Source§fn inner_attributes_node(&self) -> Option<SyntaxNode<RustLanguage>>
fn inner_attributes_node(&self) -> Option<SyntaxNode<RustLanguage>>
This may return the same node as called with (with
SourceFile). The caller has the responsibility
to avoid duplicate attributes.Source§impl HasDocComments for TypeAlias
impl HasDocComments for TypeAlias
fn doc_comments(&self) -> DocCommentIter ⓘ
Source§impl HasGenericParams for TypeAlias
impl HasGenericParams for TypeAlias
fn generic_param_list(&self) -> Option<GenericParamList>
fn where_clause(&self) -> Option<WhereClause>
Source§impl HasTypeBounds for TypeAlias
impl HasTypeBounds for TypeAlias
fn type_bound_list(&self) -> Option<TypeBoundList>
fn colon_token(&self) -> Option<SyntaxToken<RustLanguage>>
Source§impl HasVisibility for TypeAlias
impl HasVisibility for TypeAlias
fn visibility(&self) -> Option<Visibility>
Auto Trait Implementations§
impl !RefUnwindSafe for TypeAlias
impl !Send for TypeAlias
impl !Sync for TypeAlias
impl !UnwindSafe for TypeAlias
impl Freeze for TypeAlias
impl Unpin for TypeAlias
impl UnsafeUnpin for TypeAlias
Blanket Implementations§
Source§impl<N> AstNodeEdit for N
impl<N> AstNodeEdit for N
fn indent_level(&self) -> IndentLevel
fn indent(&self, level: IndentLevel) -> Self
fn indent_with_mapping(&self, level: IndentLevel, make: &SyntaxFactory) -> Self
fn dedent(&self, level: IndentLevel) -> Self
fn reset_indent(&self) -> Self
Source§impl<T> AttrsOwnerEdit for Twhere
T: HasAttrs,
impl<T> AttrsOwnerEdit for Twhere
T: HasAttrs,
fn remove_attrs_and_docs(&self, editor: &SyntaxEditor)
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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