SgmlIgnoredTag.class.php

Go to the documentation of this file.
00001 <?php
00002 /***************************************************************************
00003  *   Copyright (C) 2007 by Ivan Y. Khvostishkov                            *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU Lesser General Public License as        *
00007  *   published by the Free Software Foundation; either version 3 of the    *
00008  *   License, or (at your option) any later version.                       *
00009  *                                                                         *
00010  ***************************************************************************/
00011 /* $Id: SgmlIgnoredTag.class.php 4687 2007-12-09 18:57:18Z voxus $ */
00012 
00016     final class SgmlIgnoredTag extends SgmlTag
00017     {
00018         private $cdata      = null;
00019         private $endMark    = null;
00020         
00024         public static function create()
00025         {
00026             return new self;
00027         }
00028         
00032         public static function comment()
00033         {
00034             return self::create()->setId('!--')->setEndMark('--');
00035         }
00036         
00040         public function setCdata(Cdata $cdata)
00041         {
00042             $this->cdata = $cdata;
00043             
00044             return $this;
00045         }
00046         
00050         public function getCdata()
00051         {
00052             return $this->cdata;
00053         }
00054         
00058         public function setEndMark($endMark)
00059         {
00060             $this->endMark = $endMark;
00061             
00062             return $this;
00063         }
00064         
00065         public function getEndMark()
00066         {
00067             return $this->endMark;
00068         }
00069         
00070         public function isComment()
00071         {
00072             return $this->id == '!--';
00073         }
00074         
00075         public function isExternal()
00076         {
00077             return ($this->id && $this->id[0] == '?');
00078         }
00079     }
00080 ?>

Generated on Sun Dec 9 21:56:24 2007 for onPHP by  doxygen 1.5.4