pub struct TargetResolverBuilder { /* private fields */ }Expand description
Builds a TargetResolver for one turn.
Implementations§
Source§impl TargetResolverBuilder
impl TargetResolverBuilder
Sourcepub fn candidate(self, candidate: AuthorizedCase) -> Self
pub fn candidate(self, candidate: AuthorizedCase) -> Self
Adds an authorized case; a token is issued for it when the resolver is built.
Sourcepub fn candidates(
self,
candidates: impl IntoIterator<Item = AuthorizedCase>,
) -> Self
pub fn candidates( self, candidates: impl IntoIterator<Item = AuthorizedCase>, ) -> Self
Adds several authorized cases.
Sourcepub fn origin(self, origin: OriginToken, candidate: AuthorizedCase) -> Self
pub fn origin(self, origin: OriginToken, candidate: AuthorizedCase) -> Self
Binds a server-validated origin token to the record the surface named (§12.4).
Sourcepub fn active_interaction(self, summary: ActiveInteractionSummary) -> Self
pub fn active_interaction(self, summary: ActiveInteractionSummary) -> Self
Declares the card on screen, which a Card target resolves through.
Sourcepub fn resuming(self, workflow: WorkflowKey) -> Self
pub fn resuming(self, workflow: WorkflowKey) -> Self
Declares that starting workflow reaches the case it already has.
Sourcepub fn case_id_factory(self, factory: Arc<dyn CaseIdFactory>) -> Self
pub fn case_id_factory(self, factory: Arc<dyn CaseIdFactory>) -> Self
Replaces the identifier factory used for new cases.
Sourcepub fn build(self) -> TargetResolver
pub fn build(self) -> TargetResolver
Issues the tokens and freezes the candidate list.
Trait Implementations§
Source§impl Clone for TargetResolverBuilder
impl Clone for TargetResolverBuilder
Auto Trait Implementations§
impl !RefUnwindSafe for TargetResolverBuilder
impl !UnwindSafe for TargetResolverBuilder
impl Freeze for TargetResolverBuilder
impl Send for TargetResolverBuilder
impl Sync for TargetResolverBuilder
impl Unpin for TargetResolverBuilder
impl UnsafeUnpin for TargetResolverBuilder
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