pub struct StaticEngine {
pub descriptor: EngineDescriptor,
pub answers: BTreeMap<String, RawAnswer>,
}Expand description
Replays fixed answers. Useful for tests, fixtures, and replaying a recorded engine response.
Fields§
§descriptor: EngineDescriptor§answers: BTreeMap<String, RawAnswer>Trait Implementations§
Source§impl Clone for StaticEngine
impl Clone for StaticEngine
Source§impl Debug for StaticEngine
impl Debug for StaticEngine
Source§impl DecisionEngine for StaticEngine
impl DecisionEngine for StaticEngine
fn descriptor(&self) -> EngineDescriptor
fn decide(&self, request: &DecisionRequest) -> Result<RawDecision>
Auto Trait Implementations§
impl Freeze for StaticEngine
impl RefUnwindSafe for StaticEngine
impl Send for StaticEngine
impl Sync for StaticEngine
impl Unpin for StaticEngine
impl UnsafeUnpin for StaticEngine
impl UnwindSafe for StaticEngine
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more