$checkpoint Current normalized checkpoint. * @param array $step_context Authorized presentation context. * * @return string Translated primary action label. */ public function get_primary_action_label( array $checkpoint, array $step_context = array() ); /** * Save one validated step through its domain boundary. * * @param array $validated_fields Validated current-step fields. * @param array $checkpoint Current normalized checkpoint. * @param array $operation_context Stable operation metadata. * * @return array|WP_Error Domain result or error. */ public function save( array $validated_fields, array $checkpoint, array $operation_context ); /** * Determine whether a successful save completes the active route. * * @return bool True for a terminal step. */ public function is_terminal(); } /** * Define the per-step operation lock required by the progressive coordinator. */ interface WPBC_Setup_Wizard_Operation_Lock { /** * Acquire one context- and step-scoped operation lock. * * @param string $lock_scope Opaque checkpoint storage scope. * @param string $step_id Stable step identifier. * @param string $operation_id Stable operation identifier. * * @return string|WP_Error Opaque lock token or a busy error. */ public function acquire( $lock_scope, $step_id, $operation_id ); /** * Release a lock only when the caller still owns its token. * * @param string $lock_scope Opaque checkpoint storage scope. * @param string $step_id Stable step identifier. * @param string $lock_token Opaque token returned by acquire(). * * @return void */ public function release( $lock_scope, $step_id, $lock_token ); }