bitVectorHasState() public static method

public static bitVectorHasState ( integer $bit_vector, integer $flag ) : boolean
$bit_vector integer The bit vector we'd like to get the state for
$flag integer The flag we'd like to get the state for
return boolean True if all bits in the flag are eanbled in the bit vector, else false.
Beispiel #1
0
 /**
  * @return bool
  * True if this is an abstract class
  */
 public function isAbstract() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\MODIFIER_ABSTRACT);
 }
Beispiel #2
0
 /**
  * @return bool
  * True if this parameter is pass-by-reference
  * i.e. prefixed with '&'.
  */
 public function isPassByReference() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\PARAM_REF);
 }
Beispiel #3
0
 /**
  * @return bool
  * True if this is a static method
  */
 public function isStatic() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\MODIFIER_STATIC);
 }
Beispiel #4
0
 /**
  * @return bool
  * True if this method overrides another method
  */
 public function getIsOverride() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), Flags::IS_OVERRIDE);
 }
Beispiel #5
0
 /**
  * @return bool
  * True if this is a private property
  */
 public function isPrivate() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\MODIFIER_PRIVATE);
 }
Beispiel #6
0
 /**
  * @return bool
  * True if this class is a trait
  */
 public function isTrait() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\CLASS_TRAIT);
 }
Beispiel #7
0
 /**
  * @return bool
  * True if this was an internal PHP object
  */
 public function isInternal() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), Flags::IS_INTERNAL);
 }
Beispiel #8
0
 /**
  * @return bool
  * True if this method returns reference
  */
 public function returnsRef() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), \ast\flags\RETURNS_REF);
 }
Beispiel #9
0
 /**
  * @return bool
  * True if this method returns a value
  */
 public function getHasReturn() : bool
 {
     return Flags::bitVectorHasState($this->getFlags(), Flags::HAS_RETURN);
 }
Beispiel #10
0
 /**
  * @return bool
  * True if this method yields any value(i.e. it is a \Generator)
  */
 public function getHasYield() : bool
 {
     return Flags::bitVectorHasState($this->getPhanFlags(), Flags::HAS_YIELD);
 }