コード例 #1
0
 public function testCanConstructImportValueParser()
 {
     $instance = new ValueParserFactory();
     $this->assertInstanceOf('\\SMW\\DataValues\\ValueParsers\\ImportValueParser', $instance->newImportValueParser());
 }
コード例 #2
0
 /**
  * @param string $typeid
  */
 public function __construct($typeid)
 {
     parent::__construct($typeid);
     $this->importValueParser = ValueParserFactory::getInstance()->newImportValueParser();
 }
コード例 #3
0
 public function testCanConstructAllowsPatternContentParser()
 {
     $instance = new ValueParserFactory();
     $this->assertInstanceOf('\\SMW\\DataValues\\ValueParsers\\AllowsPatternContentParser', $instance->newAllowsPatternContentParser());
 }
コード例 #4
0
 /**
  * @since 2.4
  */
 public function __construct()
 {
     $this->allowsPatternContentParser = ValueParserFactory::getInstance()->newAllowsPatternContentParser();
 }
コード例 #5
0
 /**
  * @param string $typeid
  */
 public function __construct($typeid = '')
 {
     parent::__construct('__pvap');
     $this->allowsPatternContentParser = ValueParserFactory::getInstance()->newAllowsPatternContentParser();
 }
コード例 #6
0
 private function getValueParser()
 {
     if ($this->monolingualTextValueParser === null) {
         $this->monolingualTextValueParser = ValueParserFactory::getInstance()->newMonolingualTextValueParser();
     }
     return $this->monolingualTextValueParser;
 }