pub trait OperationDefinition {
type Parameters: Clone + Serialize + DeserializeOwned + Send + Sync + 'static;
type Output: Clone + Serialize + DeserializeOwned + Send + Sync + 'static;
// Required methods
fn spec() -> OperationSpec;
fn target(
parameters: &Self::Parameters,
) -> Result<TargetRef, TargetRefError>;
}Expand description
Typed definition implemented by a concrete infrastructure operation.
Required Associated Types§
Sourcetype Parameters: Clone + Serialize + DeserializeOwned + Send + Sync + 'static
type Parameters: Clone + Serialize + DeserializeOwned + Send + Sync + 'static
Operation-specific request parameters.
Required Methods§
Sourcefn spec() -> OperationSpec
fn spec() -> OperationSpec
Returns the operation catalog specification.
Sourcefn target(parameters: &Self::Parameters) -> Result<TargetRef, TargetRefError>
fn target(parameters: &Self::Parameters) -> Result<TargetRef, TargetRefError>
Resolves the request parameters to a typed target.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.