pub struct ProposalMode { /* private fields */ }Implementations§
Source§impl ProposalMode
impl ProposalMode
Sourcepub fn new(evaluator: Arc<dyn PolicyEvaluator>) -> Self
pub fn new(evaluator: Arc<dyn PolicyEvaluator>) -> Self
Construct the mode with an injected governance policy evaluator.
Trait Implementations§
Source§impl Mode for ProposalMode
impl Mode for ProposalMode
Authorize the sender for this message. Modes can override to customize
authorization (e.g., allowing orchestrator bypass for Commitment messages).
fn on_session_start( &self, session: &Session, _env: &Envelope, ) -> Result<ModeResponse, MacpError>
fn on_message( &self, session: &Session, env: &Envelope, ) -> Result<ModeResponse, MacpError>
Auto Trait Implementations§
impl !RefUnwindSafe for ProposalMode
impl !UnwindSafe for ProposalMode
impl Freeze for ProposalMode
impl Send for ProposalMode
impl Sync for ProposalMode
impl Unpin for ProposalMode
impl UnsafeUnpin for ProposalMode
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