/**
  * Import a sample structure, suitable for testing elements sort order
  * @return void
  */
 protected function _populateSampleSortStructure()
 {
     $child = [\Magento\Framework\Data\Structure::PARENT => 'parent'];
     $this->_structure->importElements(['parent' => [\Magento\Framework\Data\Structure::CHILDREN => ['one' => 'e1', 'two' => 'e2', 'three' => 'e3', 'four' => 'e4', 'five' => 'e5']], 'one' => $child, 'two' => $child, 'three' => $child, 'four' => $child, 'five' => $child, 'x' => []]);
 }
Example #2
0
 /**
  * Import a sample structure, suitable for testing elements sort order
  */
 protected function _populateSampleSortStructure()
 {
     $child = array(\Magento\Framework\Data\Structure::PARENT => 'parent');
     $this->_structure->importElements(array('parent' => array(\Magento\Framework\Data\Structure::CHILDREN => array('one' => 'e1', 'two' => 'e2', 'three' => 'e3', 'four' => 'e4', 'five' => 'e5')), 'one' => $child, 'two' => $child, 'three' => $child, 'four' => $child, 'five' => $child, 'x' => array()));
 }
Example #3
0
 /**
  * Constructor
  *
  * @param \Psr\Log\LoggerInterface $logger
  * @param array $elements
  */
 public function __construct(\Psr\Log\LoggerInterface $logger, array $elements = null)
 {
     $this->logger = $logger;
     parent::__construct($elements);
 }
Example #4
0
 /**
  * Get element alias by name
  *
  * @param string $name
  * @return bool|string
  */
 public function getElementAlias($name)
 {
     return $this->_structure->getChildAlias($this->_structure->getParentId($name), $name);
 }