Pinq\Parsing\IMagicConstants::getFile PHP 메소드

getFile() 공개 메소드

Gets the value of the __FILE__ magic constant.
public getFile ( ) : string
리턴 string
    public function getFile();

Usage Example

예제 #1
0
 private function resolveMagicConstantValue($name)
 {
     switch (strtoupper($name)) {
         case '__DIR__':
             return $this->magicConstants->getDirectory();
         case '__FILE__':
             return $this->magicConstants->getFile();
         case '__NAMESPACE__':
             return $this->magicConstants->getNamespace();
         case '__CLASS__':
             return $this->magicConstants->getClass();
         case '__TRAIT__':
             return $this->magicConstants->getTrait();
         case '__METHOD__':
             return $this->magicConstants->getMethod($this->closureNestingLevel > 0);
         case '__FUNCTION__':
             return $this->magicConstants->getFunction($this->closureNestingLevel > 0);
         default:
             return null;
     }
 }