Trait AsyncComputeRepresentationService

Source
pub trait AsyncComputeRepresentationService {
    // Required methods
    fn compute_to_expression(
        &self,
        auth_: BearerToken,
        request: CompiledNode,
    ) -> impl Future<Output = Result<ComputeExpression, Error>> + Send;
    fn batch_compute_to_expression(
        &self,
        auth_: BearerToken,
        request: BTreeMap<String, CompiledNode>,
    ) -> impl Future<Output = Result<BTreeMap<String, ComputeExpression>, Error>> + Send;
    fn expression_to_compute(
        &self,
        auth_: BearerToken,
        request: ExpressionToComputeRequest,
    ) -> impl Future<Output = Result<ExpressionToComputeResult, Error>> + Send;
    fn batch_expression_to_compute(
        &self,
        auth_: BearerToken,
        request: BatchExpressionToComputeRequest,
    ) -> impl Future<Output = Result<BTreeMap<ComputeExpression, ExpressionToComputeResult>, Error>> + Send;
}
Expand description

The Compute Representation Service provides the ability to translate between a human-readable expression language and a compute graph. Bidirectional translation is supported.

Required Methods§

Source

fn compute_to_expression( &self, auth_: BearerToken, request: CompiledNode, ) -> impl Future<Output = Result<ComputeExpression, Error>> + Send

Converts a compute graph and its context into a its expression language representation.

Source

fn batch_compute_to_expression( &self, auth_: BearerToken, request: BTreeMap<String, CompiledNode>, ) -> impl Future<Output = Result<BTreeMap<String, ComputeExpression>, Error>> + Send

Converts a batch of compute graphs and their contexts into their expression language representation. Requires a string key reference to be provided for each graph.

Source

fn expression_to_compute( &self, auth_: BearerToken, request: ExpressionToComputeRequest, ) -> impl Future<Output = Result<ExpressionToComputeResult, Error>> + Send

Converts an expression language representation into a compute graph. The outputted graph can be passed to the compute service or checks service for execution.

Source

fn batch_expression_to_compute( &self, auth_: BearerToken, request: BatchExpressionToComputeRequest, ) -> impl Future<Output = Result<BTreeMap<ComputeExpression, ExpressionToComputeResult>, Error>> + Send

Converts a batch of expressions into their compute graph representation.

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.

Implementors§