コード例 #1
0
ファイル: TagTest.php プロジェクト: CryptArc/TextFormatter
 /**
  * @testdox getName() returns the tag's name
  */
 public function testGetName()
 {
     $tag = new Tag(Tag::START_TAG, 'X', 12, 34);
     $this->assertSame('X', $tag->getName());
 }
コード例 #2
0
ファイル: Parser.php プロジェクト: skywalker512/FlarumChina
 public function addCopyTag(Tag $tag, $pos, $len)
 {
     $copy = $this->addTag($tag->getType(), $tag->getName(), $pos, $len);
     $copy->setAttributes($tag->getAttributes());
     $copy->setSortPriority($tag->getSortPriority());
     return $copy;
 }