models/classes/runner/synchronisation/action/NextItemData.php
protected function getItemData($itemIdentifier)
    {
        $serviceContext = $this->getServiceContext();
        $itemRef = $this->getRunnerService()->getItemHref($serviceContext, $itemIdentifier);
        $itemData = $this->getRunnerService()->getItemData($serviceContext, $itemRef);
        $baseUrl = $this->getRunnerService()->getItemPublicUrl($serviceContext, $itemRef);

        $itemState = $this->getRunnerService()->getItemState($serviceContext, $itemIdentifier);
        if ($itemState === null || !count($itemState)) {
            $itemState = new stdClass();
        }

        return [
            'baseUrl' => $baseUrl,
            'itemData' => $itemData,
            'itemState' => $itemState,
            'itemIdentifier' => $itemIdentifier,
        ];
    }
protected function getItemData($itemIdentifier)
    {
        $serviceContext = $this->getServiceContext();
        $itemRef = $this->getRunnerService()->getItemHref($serviceContext, $itemIdentifier);
        $itemData = $this->getRunnerService()->getItemData($serviceContext, $itemRef);
        $baseUrl = $this->getRunnerService()->getItemPublicUrl($serviceContext, $itemRef);

        $itemState = $this->getRunnerService()->getItemState($serviceContext, $itemIdentifier);
        if ($itemState === null || !count($itemState)) {
            $itemState = new stdClass();
        }

        return [
            'baseUrl' => $baseUrl,
            'itemData' => $itemData,
            'itemState' => $itemState,
            'itemIdentifier' => $itemIdentifier,
        ];
    }
protected function getItemData ( $ itemIdentifier ) { $ serviceContext = $ this -> getServiceContext ( ) ; $ itemRef = $ this -> getRunnerService ( ) -> getItemHref ( $ serviceContext , $ itemIdentifier ) ; $ itemData = $ this -> getRunnerService ( ) -> getItemData ( $ serviceContext , $ itemRef ) ; $ baseUrl = $ this -> getRunnerService ( ) -> getItemPublicUrl ( $ serviceContext , $ itemRef ) ; $ itemState = $ this -> getRunnerService ( ) -> getItemState ( $ serviceContext , $ itemIdentifier ) ; if ( $ itemState === null || ! count ( $ itemState ) ) { $ itemState = new stdClass ( ) ; } return [ 'baseUrl' => $ baseUrl , 'itemData' => $ itemData , 'itemState' => $ itemState , 'itemIdentifier' => $ itemIdentifier , ] ; }
Create the item definition response for a given item
@param string $itemIdentifier the item id
@return array the item data
@throws \common_Exception
Create the item definition response for a given item