CoreFiles by mySites.guru
WorkflowServiceInterface.php92 lines, 2,090 bytes, from Joomla_4.0.0-beta1-Beta-Full_Package.zip
Raw History Compare with 3.9.0-beta4
md5
cea2cfa3fec3d2e26e51ed9b04e30aa9
sha1
38180e905a92e9e8311c71082f7cf5c9c6ab9950
sha256
864f7764b767e059ed2e8325e3074572e046e10b22ea19803fefa39343fbf35e
<?php
/**
 * Joomla! Content Management System
 *
 * @copyright  Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
 * @license    GNU General Public License version 2 or later; see LICENSE.txt
 */

namespace Joomla\CMS\Workflow;

\defined('JPATH_PLATFORM') or die;

/**
 * The workflow service.
 *
 * @since  4.0.0
 */
interface WorkflowServiceInterface
{
	/**
	 * Check if the functionality is supported by the context
	 *
	 * @param   string  $functionality  The functionality
	 * @param   string  $context        The context of the functionality
	 *
	 * @return boolean
	 *
	 * @since  4.0.0
	 */
	public function supportFunctionality($functionality, $context): bool;

	/**
	 * Returns the model name, based on the context
	 *
	 * @param   string  $context  The context of the workflow
	 *
	 * @return boolean
	 */
	public function getModelName($context): string;

	/**
	 * Check if the workflow is active
	 *
	 * @param   string  $context  The context of the workflow
	 *
	 * @return boolean
	 */
	public function isWorkflowActive($context): bool;

	/**
	 * Method to filter transitions by given id of state.
	 *
	 * @param   integer[]  $transitions  Array of transitions to filter for
	 * @param   integer    $pk           Id of the state on which the transitions are performed
	 *
	 * @return  array
	 *
	 * @since  4.0.0
	 */
	public function filterTransitions(array $transitions, int $pk): array;

	/**
	 * Returns an array of possible conditions for the component.
	 *
	 * @param   string  $extension  Full extension string
	 *
	 * @return  array
	 *
	 * @since   4.0.0
	 */
	public static function getConditions(string $extension): array;

	/**
	 * Returns a table name for the state association
	 *
	 * @param   string  $section  An optional section to differ different areas in the component
	 *
	 * @return  string
	 *
	 * @since   4.0.0
	 */
	public function getWorkflowTableBySection(?string $section = null): string;

	/**
	 * Returns valid contexts.
	 *
	 * @return  array
	 *
	 * @since   4.0.0
	 */
	public function getWorkflowContexts(): array;
}

The same content is in 5 releases, Joomla 4.0.0-beta to 4.0.0-beta5. See them all, or every version of this file.