equal
deleted
inserted
replaced
13 |
13 |
14 use IRI\Bundle\WikiTagBundle\Utils\WikiTagUtils; |
14 use IRI\Bundle\WikiTagBundle\Utils\WikiTagUtils; |
15 |
15 |
16 abstract class Tag implements TagInterface { |
16 abstract class Tag implements TagInterface { |
17 |
17 |
18 public static $TAG_URL_STATUS_DICT = array('null_result'=>0,'redirection'=>1,'homonyme'=>2,'match'=>3); |
18 public static $TAG_URL_STATUS_DICT = array('null_result'=>0,'redirection'=>1,'homonyme'=>2,'match'=>3, 'unsemantized'=>4); |
19 |
19 |
20 /** |
20 /** |
21 * @var integer $id |
21 * @var integer $id |
22 */ |
22 */ |
23 protected $id; |
23 protected $id; |
315 * |
315 * |
316 * @return string |
316 * @return string |
317 */ |
317 */ |
318 public function getUrlStatusText() |
318 public function getUrlStatusText() |
319 { |
319 { |
|
320 if(is_null($this->getUrlStatus())) |
|
321 { |
|
322 return null; |
|
323 } |
320 switch ($this->getUrlStatus()) { |
324 switch ($this->getUrlStatus()) { |
321 case 0: |
325 case 0: |
322 return "null_result"; |
326 return "null_result"; |
323 case 1: |
327 case 1: |
324 return "redirection"; |
328 return "redirection"; |
325 case 2: |
329 case 2: |
326 return "homonyme"; |
330 return "homonyme"; |
327 case 3: |
331 case 3: |
328 return "match"; |
332 return "match"; |
|
333 case 4: |
|
334 return "unsemantized"; |
|
335 default: |
|
336 return ""; |
329 } |
337 } |
330 } |
338 } |
331 |
339 |
332 |
340 |
333 /** |
341 /** |