Exemplo n.º 1
0
 /**
  * @return FullyQualifiedClassConstantName|FullyQualifiedConstantName
  * The fully-qualified structural element name of this
  * structural element
  */
 public function getFQSEN() : FQSEN
 {
     // Get the stored FQSEN if it exists
     if ($this->fqsen) {
         return $this->fqsen;
     }
     return FullyQualifiedConstantName::fromStringInContext($this->getName(), $this->getContext());
 }
Exemplo n.º 2
0
 public function testFullyQualifiedConstantName()
 {
     $this->assertFQSENEqual(FullyQualifiedConstantName::make('\\Name\\Space', 'c'), '\\Name\\Space\\c');
     $this->assertFQSENEqual(FullyQualifiedConstantName::make('', 'c'), '\\c');
     $this->assertFQSENEqual(FullyQualifiedConstantName::make('', 'c'), '\\c');
     $this->assertFQSENEqual(FullyQualifiedConstantName::fromFullyQualifiedString('\\c'), '\\c');
     $this->assertFQSENEqual(FullyQualifiedConstantName::fromStringInContext('c', $this->context), '\\c');
 }