pub fn validate<Ctx>(
ctx: &Ctx,
router: &impl Router,
msg: MsgEnvelope,
) -> Result<(), HandlerError>where
Ctx: ValidationContext,
<<<Ctx as ValidationContext>::V as ClientValidationContext>::ClientStateRef as TryFrom<Any>>::Error: Into<ClientError>,
<<Ctx as ValidationContext>::HostClientState as TryFrom<Any>>::Error: Into<ClientError>,
Expand description
Entrypoint which only performs message validation
If a transaction contains n
messages m_1
… m_n
, then
they MUST be processed as follows:
validate(m_1), execute(m_1), …, validate(m_n), execute(m_n)
That is, the state transition of message i
must be applied before
message i+1
is validated. This is equivalent to calling
dispatch()
on each successively.