pub enum TypeScriptType<'a> {
Struct(&'a Struct),
NewType(&'a NewType),
Alias(&'a Alias),
Enum(&'a Enum),
Union(&'a Union),
}
Expand description
An enum representing the possible top-level types in TypeScript
This shouldn’t be instaniated directly but passed using turbofish operator to registry_to_output enabling it to write out in TypeScript
Variants§
Struct(&'a Struct)
A struct variant
NewType(&'a NewType)
A new type variant
Alias(&'a Alias)
A type alias variant
Enum(&'a Enum)
A simple enum variant (does not contain data)
Union(&'a Union)
A union variant (enums with data)
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for TypeScriptType<'a>
impl<'a> RefUnwindSafe for TypeScriptType<'a>
impl<'a> Send for TypeScriptType<'a>
impl<'a> Sync for TypeScriptType<'a>
impl<'a> Unpin for TypeScriptType<'a>
impl<'a> UnwindSafe for TypeScriptType<'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