pub trait ProtoProcessor: Send + Sync {
// Required methods
fn discover_proto_files<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<Vec<ProtoFile>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn parse_proto_services<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceDefinition>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn generate_code<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
input: &'life1 Path,
output: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<GenerationResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn validate_proto_syntax<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<ValidationReport>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Protocol Buffers file processing
Required Methods§
Sourcefn discover_proto_files<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<Vec<ProtoFile>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn discover_proto_files<'life0, 'life1, 'async_trait>(
&'life0 self,
path: &'life1 Path,
) -> Pin<Box<dyn Future<Output = Result<Vec<ProtoFile>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Discover proto files
Sourcefn parse_proto_services<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceDefinition>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn parse_proto_services<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceDefinition>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Parse proto services
Sourcefn generate_code<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
input: &'life1 Path,
output: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<GenerationResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn generate_code<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
input: &'life1 Path,
output: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<GenerationResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Generate code
Sourcefn validate_proto_syntax<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<ValidationReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn validate_proto_syntax<'life0, 'life1, 'async_trait>(
&'life0 self,
files: &'life1 [ProtoFile],
) -> Pin<Box<dyn Future<Output = Result<ValidationReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Validate proto syntax
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".