pub trait TransformContextRequestExtension: Sized {
// Required methods
fn set_transform_context(&mut self, value: TransformContext);
fn get_transform_context(&self) -> Option<&TransformContext>;
// Provided method
fn transform_context(self, value: TransformContext) -> Self { ... }
}Expand description
Add support for transform context to specify how the response will be canonicalized by the replica to maximize chances of consensus.
See the docs on HTTPs outcalls for more details.
Required Methods§
Sourcefn set_transform_context(&mut self, value: TransformContext)
fn set_transform_context(&mut self, value: TransformContext)
Set the transform context.
Sourcefn get_transform_context(&self) -> Option<&TransformContext>
fn get_transform_context(&self) -> Option<&TransformContext>
Retrieve the current transform context, if any.
Provided Methods§
Sourcefn transform_context(self, value: TransformContext) -> Self
fn transform_context(self, value: TransformContext) -> Self
Convenience method to use the builder pattern.
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.