eZ\Publish\Core\Repository\ObjectStateService::loadObjectStateGroups PHP Method

loadObjectStateGroups() public method

Loads all object state groups.
public loadObjectStateGroups ( integer $offset, integer $limit ) : eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup[]
$offset integer
$limit integer
return eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup[]
    public function loadObjectStateGroups($offset = 0, $limit = -1)
    {
        $spiObjectStateGroups = $this->objectStateHandler->loadAllGroups($offset, $limit);
        $objectStateGroups = array();
        foreach ($spiObjectStateGroups as $spiObjectStateGroup) {
            $objectStateGroups[] = $this->buildDomainObjectStateGroupObject($spiObjectStateGroup);
        }
        return $objectStateGroups;
    }