Skip to main content

ProtocolDriver

Trait ProtocolDriver 

Source
pub trait ProtocolDriver: Send + Sync {
    // Required methods
    fn descriptor(&self) -> ProtocolDescriptor;
    fn build<'life0, 'async_trait>(
        &'life0 self,
        spec: ProtocolLaunchSpec,
        extensions: RuntimeExtensions,
    ) -> Pin<Box<dyn Future<Output = RuntimeResult<Arc<dyn ManagedService>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;

    // Provided methods
    fn features(&self) -> &'static [&'static str] { ... }
    fn schema(&self) -> Option<JsonValue> { ... }
}
Expand description

Compile-time extensibility point for protocol service creation.

Required Methods§

Source

fn descriptor(&self) -> ProtocolDescriptor

Returns the driver descriptor.

Source

fn build<'life0, 'async_trait>( &'life0 self, spec: ProtocolLaunchSpec, extensions: RuntimeExtensions, ) -> Pin<Box<dyn Future<Output = RuntimeResult<Arc<dyn ManagedService>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Builds a managed service from the generic launch request.

Provided Methods§

Source

fn features(&self) -> &'static [&'static str]

Returns a short feature list for CLI inspection surfaces.

Source

fn schema(&self) -> Option<JsonValue>

Returns an optional schema summary for CLI inspection surfaces.

Implementors§