Пример #1
0
 public function __construct($object)
 {
     if (!is_object($object)) {
         throw new InvalidArgumentException("No provided object is not of type 'object'.");
     }
     $this->object = $object;
     $this->beanId = get_class($this->object);
     $this->classes = Customweb_Core_Util_Class::getAllTypes($this->beanId);
 }
Пример #2
0
 protected function isActionMethodContainParameterTransaction(ReflectionMethod $method)
 {
     foreach ($method->getParameters() as $parameter) {
         $type = self::getParameterType($parameter);
         $tpyes = Customweb_Core_Util_Class::getAllTypes($type);
         if (in_array('Customweb_Payment_Authorization_ITransaction', $tpyes)) {
             return true;
         }
     }
     return false;
 }
Пример #3
0
 /**
  * This method adds the container to the internal bean list. Hence beans
  * can access the bean container.
  * 
  * @return void
  */
 protected function addSelfToContainer()
 {
     $className = get_class($this);
     $classes = Customweb_Core_Util_Class::getAllTypes($className);
     $this->addBean($classes, $this);
     // We need to add the bean container to the range query index.
     foreach ($classes as $class) {
         $class = strtolower($class);
         if (!isset($this->beansByClasses[$class])) {
             $this->beansByClasses[$class] = array();
         }
         $this->beansByClasses[$class][] = $this;
     }
 }
Пример #4
0
 public function getClasses()
 {
     $classes = Customweb_Core_Util_Class::getAllTypes($this->getBeanClassName());
     return $classes;
 }