Lisphp_Symbol::get PHP Method

get() public static method

public static get ( $symbol )
    public static function get($symbol)
    {
        if (isset(self::$map[$symbol])) {
            return self::$map[$symbol];
        }
        return self::$map[$symbol] = new self($symbol);
    }

Usage Example

Beispiel #1
0
 function testGet()
 {
     $this->assertEquals(1, $this->scope['abc']);
     $this->assertEquals(true, $this->scope[Lisphp_Symbol::get('def')]);
     $this->assertNull($this->scope['ghi']);
     $this->assertNull($this->scope['x']);
 }
All Usage Examples Of Lisphp_Symbol::get