pub struct LambdaCodeGenerator { /* private fields */ }Expand description
Lambda-specific code generation for Rust output
Implementations§
Source§impl LambdaCodeGenerator
impl LambdaCodeGenerator
pub fn new() -> LambdaCodeGenerator
pub fn with_optimization_profile( self, profile: OptimizationProfile, ) -> LambdaCodeGenerator
Sourcepub fn generate_lambda_project(
&self,
context: &LambdaGenerationContext,
) -> Result<LambdaProject, Error>
pub fn generate_lambda_project( &self, context: &LambdaGenerationContext, ) -> Result<LambdaProject, Error>
Generate complete Lambda Rust project from Python handler
Sourcepub fn generate_handler(
&self,
context: &LambdaGenerationContext,
) -> Result<String, Error>
pub fn generate_handler( &self, context: &LambdaGenerationContext, ) -> Result<String, Error>
Generate the main handler Rust code
Sourcepub fn generate_cargo_toml(
&self,
context: &LambdaGenerationContext,
) -> Result<String, Error>
pub fn generate_cargo_toml( &self, context: &LambdaGenerationContext, ) -> Result<String, Error>
Generate Cargo.toml for Lambda project
Sourcepub fn generate_build_script(
&self,
context: &LambdaGenerationContext,
) -> Result<String, Error>
pub fn generate_build_script( &self, context: &LambdaGenerationContext, ) -> Result<String, Error>
Generate build script for cargo-lambda
Sourcepub fn generate_sam_template(
&self,
context: &LambdaGenerationContext,
) -> Result<String, Error>
pub fn generate_sam_template( &self, context: &LambdaGenerationContext, ) -> Result<String, Error>
Generate SAM template
Sourcepub fn generate_cdk_construct(
&self,
context: &LambdaGenerationContext,
) -> Result<String, Error>
pub fn generate_cdk_construct( &self, context: &LambdaGenerationContext, ) -> Result<String, Error>
Generate CDK construct
Trait Implementations§
Source§impl Clone for LambdaCodeGenerator
impl Clone for LambdaCodeGenerator
Source§fn clone(&self) -> LambdaCodeGenerator
fn clone(&self) -> LambdaCodeGenerator
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LambdaCodeGenerator
impl Debug for LambdaCodeGenerator
Source§impl Default for LambdaCodeGenerator
impl Default for LambdaCodeGenerator
Source§fn default() -> LambdaCodeGenerator
fn default() -> LambdaCodeGenerator
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LambdaCodeGenerator
impl RefUnwindSafe for LambdaCodeGenerator
impl Send for LambdaCodeGenerator
impl Sync for LambdaCodeGenerator
impl Unpin for LambdaCodeGenerator
impl UnwindSafe for LambdaCodeGenerator
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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