classOrInterfaceExists() 공개 메소드

Checks that a class or interface has been declared.
public classOrInterfaceExists ( ) : boolean
리턴 boolean True if defined.
예제 #1
0
 function testClassNonExistence()
 {
     $reflection = new SimpleReflection('UnknownThing');
     $this->assertFalse($reflection->classOrInterfaceExists());
     $this->assertFalse($reflection->classOrInterfaceExistsSansAutoload());
 }
 function testInterfaceExistence()
 {
     $reflection = new SimpleReflection('AnyOldInterface');
     $this->assertTrue($reflection->classOrInterfaceExists());
     $this->assertTrue($reflection->classOrInterfaceExistsSansAutoload());
 }