AutoMovie API
    Preparing search index...

    Interface IAutoMovieMotionHumanMutual<Params, Role>

    A mutual action: one thing two or more people do together, such as a handshake, a handover or a lift, stated once for all of them.

    It names the roles and says which action each role performs for the shared parameters and the cast. The roles' actions are ordinary laws that read one meeting record, so the contact is planned once from where every role stands and no role chases another. HumanChain.mutual joins the cast's chains through it.

    interface IAutoMovieMotionHumanMutual<
        Params = object,
        Role extends string = string,
    > {
        name: string;
        roles: readonly Role[];
        act(
            role: Role,
            params: Params,
            cast: Readonly<Record<Role, string>>,
            anchor?: string,
        ): IAct;
    }

    Type Parameters

    • Params = object
    • Role extends string = string
    Index
    name: string

    The mutual action's name.

    roles: readonly Role[]

    The roles, in the order their actions are placed.

    • The action one role performs.

      Parameters

      • role: Role

        The role.

      • params: Params

        The shared parameters.

      • cast: Readonly<Record<Role, string>>

        Who performs each role, by subject id.

      • Optionalanchor: string

        The joined action's anchor, when the author gave one: each role's action is anchored ${anchor}.${role}, so a role can name another's instants (a catch reads its throw). Absent when the author gave none.

      Returns IAct

      The action's name and its own parameters.