Adds a PClass to the storage.

@param KlarnaPClass $pclass PClass object.

@throws KlarnaException
@return void
488805
public function addPClass($pclass)
    {
        if (! $pclass instanceof KlarnaPClass) {
            throw new Klarna_InvalidTypeException('pclass', 'KlarnaPClass');
        }

        if (!isset($this->pclasses) || !is_array($this->pclasses)) {
            $this->pclasses = array();
        }

        if ($pclass->getDescription() === null || $pclass->getType() === null) {
            //Something went wrong, do not save these!
            return;
        }

        if (!isset($this->pclasses[$pclass->getEid()])) {
            $this->pclasses[$pclass->getEid()] = array();
        }
        $this->pclasses[$pclass->getEid()][$pclass->getId()] = $pclass;
    }
503055
public function addClass($classes)
    {
        $classes = (array)$classes;
        foreach ($classes as $class) {
            if (class_exists($class) || interface_exists($class)) {
                $this->classes[] = $class;
            } else {
                echo "Class not exists: $class\r\n";
            }
        }
    }
930824
public void add(final Class<?> clazz) {
		if (this.clazzes.contains(clazz)) {
			throw new IllegalArgumentException(
					"Only one class-instance per benchmark allowed");
		} else {
			this.clazzes.add(clazz);
		}
	}
1007849
public function addClass(string $class): self
    {
        $classes = explode(' ', $class);

        foreach ($classes as $class) {
            if (!in_array($class, $this->rowClasses)) {
                $this->rowClasses[] = $class;
            }
        }

        return $this;
    }
1003685
protected function addClass(string $class)
    {
        if ($this->initialized) {
            throw new RuntimeException("You can't register provider class as registry as been initialized.");
        }

        if (!class_exists($class)) {
            throw new InvalidArgumentException("Class $class does not exist.");
        }

        if (!is_subclass_of($class, ProviderInterface::class)) {
            throw new InvalidArgumentException("Class $class must implement " . ProviderInterface::class);
        }

        $this->classes[] = $class;
    }
753341
public function addDiscriminator(string $class, string $key, string $discriminatorClass): void
    {
        if (!isset($this->discriminators[$class])) {
            $this->discriminators[$class] = [];
        }

        if (!isset($this->discriminators[$class][$key])) {
            $this->discriminators[$class][$key] = $discriminatorClass;
        }
    }
117354
public function addClass($class, $extends = null, $implements = [])
    {
        $classId = $this->registerClass($class);
        if ($extends) {
            $parentClassId = $this->registerClass($extends);
            $this->extends[$classId] = [$parentClassId];
        }
        if (!empty($implements)) {
            $interfaceIds = [];
            foreach ($implements as $interface) {
                $interfaceIds[] = $this->registerInterface($interface);
            }
            $this->implements[$classId] = $interfaceIds;
        }
    }
1249933
public function addClass(&$class)
    {
        if (isset($this->_classes[$class->name()])) {
            $phpdoctor =& $this->_root->phpdoctor();
            echo "\n";
            $phpdoctor->warning('Found class '.$class->name().' again, overwriting previous version');
        }
        $this->_classes[$class->name()] =& $class;
    }
81955
public function add($class = null)
        {
            $class = $this->getClass($class);

            if (!Arrays::exists($class, $this->reflections)) {
                $this->reflections[$class] = new ReflectionClass($class);
            }

            return $this;
        }
1128510
protected function addProductClass()
    {
        if (!$this->isError()) {
            $id = $this->product_class->add($this->getSubmitted());
            if (empty($id)) {
                $this->errorAndExit($this->text('Unexpected result'));
            }
            $this->line($id);
        }
    }
109330
public function addType($name, $class)
    {
        if (!Type::hasType($name)) {
            Type::addType($name, $class);
        } else {
            Type::overrideType($name, $class);
        }
    }
561759
public function loadClass($class)
    {
        if ((true === $this->apc && ($file = $this->findFileInApc($class))) or
            ($file = $this->findFile($class))
        ) {
            require_once $file;
        }
    }
852718
public function add($name, $class)
    {
        $ref = new ReflectionClass($class);
        if ($ref->isSubclassOf('Phalcon\Config') === false) {
            throw new NotFoundTrueParentClassException(
                $class . ' is\'t subclass of Phalcon/Config'
            );
        }
        $this->adapters[$name] = $class;
    }
683698
public function addClass(?string $class): void
  {
    // If class is empty return immediately.
    if ($class===null || $class==='') return;

    if (isset($this->attributes['class']))
    {
      $this->attributes['class'] .= ' ';
      $this->attributes['class'] .= $class;
    }
    else
    {
      $this->attributes['class'] = $class;
    }
  }
635226
public static function addListeners($objOrClass)
    {
        self::getAllListeners(); //fill cache
        if ($objOrClass instanceof Kwf_Events_Subscriber) {
            self::_addListenersFromSubscribers(self::$_listeners, array($objOrClass));
        } else if (is_string($objOrClass)) {
            if (is_instance_of($objOrClass, 'Kwf_Model_Interface')) {
                self::_addListenersFromSubscribers(self::$_listeners,
                    self::_getSubscribersFromModel($objOrClass)
                );
            } else if (is_instance_of($objOrClass, 'Kwf_Component_Abstract')) {
                self::_addListenersFromSubscribers(self::$_listeners,
                    self::_getSubscribersFromComponent($objOrClass)
                );
            }
        }
    }
761272
public function addClass($class)
    {
        if (is_array($class)) {
            foreach ($class as $c) {
                $this->addClass($class);
            }

            return $this;
        }
        $this->template->append('class', ' '.$class);

        return $this;
    }
1315880
public static function load($pClassName)
    {
        if ((class_exists($pClassName, false)) || (strpos($pClassName, 'PHPExcel') !== 0)) {
            // Either already loaded, or not a PHPExcel class request
            return false;
        }

        $pClassFilePath = PHPEXCEL_ROOT .
            str_replace('_', DIRECTORY_SEPARATOR, $pClassName) .
            '.php';

        if ((file_exists($pClassFilePath) === false) || (is_readable($pClassFilePath) === false)) {
            // Can't load
            return false;
        }

        require($pClassFilePath);
    }