Exemplo n.º 1
0
 protected function parseNodeInfo(NodeInterface $node, $definition)
 {
     if ($attributes = $this->getAttributes($definition)) {
         $node->setAttributes($attributes);
     }
     if (isset($definition['tag-name'])) {
         $node->setTagName($definition['tag-name']);
     }
     if (isset($definition['editor'])) {
         $node->setEditor($definition['editor']);
     }
 }
Exemplo n.º 2
0
 /**
  * Renders the content of the passed node.
  *
  * Example usage:
  *
  *      <div {{ createphp_attributes(entity) }}>
  *          <span {{ createphp_attributes(entity.title) }}>
  *              {{ createphp_content(entity.title}}
  *          </span>
  *      </div>
  *
  * @param NodeInterface $node the node for which to render the content
  *
  * @return string The html markup
  */
 public function renderContent(NodeInterface $node)
 {
     return $node->renderContent();
 }