@param Shopgate_Model_XmlResultObject $itemNode

@return Shopgate_Model_XmlResultObject
551197
public function asXml(Shopgate_Model_XmlResultObject $itemNode)
    {
        /**
         * @var Shopgate_Model_XmlResultObject $visibilityNode
         */
        $visibilityNode = $itemNode->addChild('visibility');
        $visibilityNode->addAttribute('level', $this->getLevel());
        $visibilityNode->addAttribute('marketplace', $this->getMarketplace());

        return $itemNode;
    }
892928
protected function getNodeValueAsObject($xquery, $className)
    {
      $nodeList = $this->document->getXPath()->query($xquery, $this->node);

      if($nodeList->length == 0)
        throw new Exception(__METHOD__ . '; ' . $xquery . ' node is missing');

      return new $className(utf8_decode($nodeList->item(0)->nodeValue));
    }
671408
public function buildMenu(ItemInterface $node, ItemEntity $item)
    {
        if ($item->getPath() && $this->fs->exists($item->getPath())) {
            $node->addChild('Fill folder', [
                'route' => 'item_folder_filler_fill',
                'routeParameters' => [
                    'id' => $item->getId(),
                    'name' => $item->getUrlName()
                ]
            ])
                ->setLinkAttribute('class', 'icon-label icon-fill');
        }
    }
1298344
public function deserializeQuestion(array $itemData, AbstractItem $item = null, array $options = [])
    {
        return $this->getItemSerializer()->deserialize($itemData, $item, $options);
    }
185994
protected function createNewItem($itemData)
    {
        $item = array_flip($this->columns);

        foreach ($item as $key => $value) {
            if (isset($itemData[$key])) {
                $item[$key] = $itemData[$key];
            } else {
                $item[$key] = null;
            }
        }

        return $item;
    }
79967
public function fillFromSearchResult(ItemSearch $item)
    {
        $query = parse_url($item->getLink(), PHP_URL_QUERY);
        parse_str($query, $query);
        if (empty($query[$this->getForm()->getName()])) {
            return;
        }

        return $this->fill($query[$this->getForm()->getName()]);
    }
1048738
protected function buildMenuItemRecursive(NodeInterface $currentNode)
    {
        if ($this->isNodeHidden($currentNode)) {
            return null;
        }

        $item = [
            'node' => $currentNode,
            'state' => self::STATE_NORMAL,
            'label' => $currentNode->getLabel(),
            'menuLevel' => $this->currentLevel
        ];

        $item['state'] = $this->calculateItemState($currentNode);
        if (!$this->isOnLastLevelOfMenu($currentNode)) {
            $this->currentLevel++;
            $item['subItems'] = $this->buildMenuLevelRecursive($currentNode->getChildNodes($this->getFilter()));
            $this->currentLevel--;
        }

        return $item;
    }
1304562
public function asXml(Shopgate_Model_XmlResultObject $itemNode)
    {
        /**
         * @var Shopgate_Model_XmlResultObject    $inputNode
         * @var Shopgate_Model_XmlResultObject    $optionsNode
         * @var Shopgate_Model_Catalog_Validation $validationItem
         * @var Shopgate_Model_Catalog_Option     $optionItem
         */
        $inputNode = $itemNode->addChild('input');
        $inputNode->addAttribute('uid', $this->getUid());
        $inputNode->addAttribute('type', $this->getType());
        $inputNode->addAttribute('required', (int)$this->getRequired());
        $inputNode->addAttribute('additional_price', $this->getAdditionalPrice());
        $inputNode->addAttribute('sort_order', $this->getSortOrder());
        $inputNode->addChildWithCDATA('label', $this->getLabel());
        $inputNode->addChildWithCDATA('info_text', $this->getInfoText());
        $optionsNode = $inputNode->addChild('options');

        /**
         * options
         */
        foreach ($this->getOptions() as $optionItem) {
            $optionItem->asXml($optionsNode);
        }

        /**
         * validation
         */
        $this->getValidation()->asXml($inputNode);

        return $itemNode;
    }
126991
public function asXml(Shopgate_Model_XmlResultObject $itemNode)
    {
        /**
         * @var Shopgate_Model_XmlResultObject $shippingNode
         */
        $shippingNode = $itemNode->addChild('shipping');
        $shippingNode->addChild('costs_per_order', $this->getCostsPerOrder(), null, false);
        $shippingNode->addChild('additional_costs_per_unit', $this->getAdditionalCostsPerUnit(), null, false);
        $shippingNode->addChild('is_free', (int)$this->getIsFree());

        return $itemNode;
    }
1363751
protected function getQueryBuilderForContainsMethods(string $itemType, int $itemUid) : QueryBuilder
    {
        $queryBuilder = $this->getQueryBuilder();
        return $queryBuilder->count('uid')->from($this->table)
            ->andWhere(
                $queryBuilder->expr()->eq('item_type', $queryBuilder->createNamedParameter($itemType)),
                $queryBuilder->expr()->eq('item_uid', $itemUid)
            );
    }
263415
public function toXML( DOMDocument $dom )
    {
        if ( !$this->XMLStorable )
        {
            return false;
        }

        $itemNode = $dom->createElement( 'item' );

        foreach ( $this->attributes as $attrName => $attrValue )
        {
            switch ( $attrName )
            {
                case 'id':
                    $itemNode->setAttribute( 'id', $attrValue );
                    break;

                case 'action':
                    $itemNode->setAttribute( 'action', $attrValue );
                    break;

                default:
                    $node = $dom->createElement( $attrName );
                    $nodeValue = $dom->createTextNode( $attrValue );
                    $node->appendChild( $nodeValue );
                    $itemNode->appendChild( $node );
                    break;
            }
        }

        return $itemNode;
    }
792704
public function getMostRevelantItemForNode($nodeId)
    {
        if (isset($this->perNode[$nodeId])) {
            return reset($this->perNode[$nodeId]);
        }
    }
193558
public function createMenuNode($data) {
		$cls = $this->itemClass;
		$node = $cls::create($data, $this);
		$this->items[$node->ID] = $node;
		return $node;
	}
103438
protected function findItem($tableName,$itemId)
  {
    $tableAlias = $this->getTableAlias($tableName);

    $qb = $this->dbConn->createQueryBuilder();
    $qb->select($this->getTableSelects($tableName,$tableAlias));
    $qb->from($tableName,$tableAlias);

    $primaryKeyName = $this->getTablePrimaryKey($tableName);

    $qb->andWhere($primaryKeyName . ' = :' . $primaryKeyName);

    $qb->setParameter($primaryKeyName,$itemId);

    $rows = $qb->execute()->fetchAll();

    return count($rows) === 1 ? $this->extractItem($tableAlias . '__',$rows[0]) : null;
  }
867214
public function addItemInstance(Nodes\NodeInterface $item, $location = null)
	{
		$location = (int) $location;

		$this->items[$location][] = $item;

		if ($id = $item->getId()) {
			$this->ids[$id] = $item;
		}

		return $item;
	}
885741
public static function fromItemset( $itemSet, $allowSameElementRepeat = false )
	{
		$result = new DocumentOrderNodeIterator();
		$result->allowSameElementRepeat = $allowSameElementRepeat;
		$result->itemSet = array_values( $itemSet );
		return $result;
	}
215708
public CmsTreeItem getChild(String itemId) {

        CmsTreeItem result = m_children.getItem(itemId);
        return result;
    }