Struct progenitor_impl::Generator
source · pub struct Generator { /* private fields */ }Expand description
OpenAPI generator.
Implementations§
source§impl Generator
impl Generator
sourcepub fn new(settings: &GenerationSettings) -> Self
pub fn new(settings: &GenerationSettings) -> Self
Create a new generator with default values.
sourcepub fn generate_tokens(&mut self, spec: &OpenAPI) -> Result<TokenStream>
pub fn generate_tokens(&mut self, spec: &OpenAPI) -> Result<TokenStream>
Emit a TokenStream containing the generated client code.
sourcepub fn get_type_space(&self) -> &TypeSpace
pub fn get_type_space(&self) -> &TypeSpace
Get the [TypeSpace] for schemas present in the OpenAPI specification.
sourcepub fn uses_futures(&self) -> bool
pub fn uses_futures(&self) -> bool
Whether the generated client needs to use additional crates to support futures.
sourcepub fn uses_websockets(&self) -> bool
pub fn uses_websockets(&self) -> bool
Whether the generated client needs to use additional crates to support websockets.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Generator
impl !Send for Generator
impl !Sync for Generator
impl Unpin for Generator
impl UnwindSafe for Generator
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