__construct() public method

This is default constructor of ATK4. Please do not re-define it and avoid calling it directly. Always use add() and init() methods.
public __construct ( array $options = [] )
$options array will initialize class properties
 public function __construct($array = null, $success = true)
 {
     parent::__construct($array, $success);
     $this->authenticated = false;
     $this->verified = false;
     $this->ibssoToken = '';
 }
 /**
  * Constructor.
  *
  * @param array $attributes
  */
 public function __construct(array $attributes = [])
 {
     parent::__construct($attributes);
     $this->setAttribute('value', 0);
     $this->setValueIfAttributeExists('SCRIPT', 1);
     $this->setValueIfAttributeExists('ACCOUNTDISABLE', 2);
     $this->setValueIfAttributeExists('HOMEDIR_REQUIRED', 8);
     $this->setValueIfAttributeExists('LOCKOUT', 16);
     $this->setValueIfAttributeExists('PASSWD_NOTREQD', 32);
     $this->setValueIfAttributeExists('ENCRYPTED_TEXT_PWD_ALLOWED', 128);
     $this->setValueIfAttributeExists('TEMP_DUPLICATE_ACCOUNT', 256);
     $this->setValueIfAttributeExists('NORMAL_ACCOUNT', 512);
     $this->setValueIfAttributeExists('INTERDOMAIN_TRUST_ACCOUNT', 2048);
     $this->setValueIfAttributeExists('WORKSTATION_TRUST_ACCOUNT', 4096);
     $this->setValueIfAttributeExists('SERVER_TRUST_ACCOUNT', 8192);
     $this->setValueIfAttributeExists('DONT_EXPIRE_PASSWORD', 65536);
     $this->setValueIfAttributeExists('MNS_LOGON_ACCOUNT', 131072);
     $this->setValueIfAttributeExists('SMARTCARD_REQUIRED', 262144);
     $this->setValueIfAttributeExists('TRUSTED_FOR_DELEGATION', 524288);
     $this->setValueIfAttributeExists('NOT_DELEGATED', 1048576);
     $this->setValueIfAttributeExists('USE_DES_KEY_ONLY', 2097152);
     $this->setValueIfAttributeExists('DONT_REQ_PREAUTH', 4194304);
     $this->setValueIfAttributeExists('PASSWORD_EXPIRED', 8388608);
     $this->setValueIfAttributeExists('TRUSTED_TO_AUTH_FOR_DELEGATION', 16777216);
 }
    public function __construct() {
        parent::__construct();
        $parameters = $this->initiateParameters();
        $this->checkParameters($parameters);

        $this->parameters = $parameters;
    }
 public function __construct($name, $publicName = NULL, $required = TRUE, $defaultValue = NULL) {
     parent::__construct();
     $this->name = $name;
     $this->publicName = t(isset($publicName) ? $publicName : $name);
     $this->required = $required;
     $this->defaultValue = $defaultValue;
 }
 public function __construct($propertyName, $isSortAscending = TRUE)
 {
     parent::__construct();
     $this->propertyName = $propertyName;
     $this->isSortAscending = $isSortAscending;
     $this->checkPropertyName();
 }
Example #6
0
 public function __construct($nType, $sSource, $nPostion = 0, $nLine = 0)
 {
     parent::__construct($sSource, $nPostion, $nLine);
     $this->nType = $nType;
     $this->setTokenType($nType);
     $this->sType = $this->tokenTypeName();
 }
Example #7
0
 public function __construct(AbstractObject $parent, $name = null, $url = null, $email = null)
 {
     parent::__construct($parent);
     $this->name = empty($name) ? null : $name;
     $this->url = empty($url) ? null : $url;
     $this->email = empty($email) ? null : $email;
 }
 public function __construct(DataSourceHandler $datasourceHandler, AbstractQueryRequest $request, $columnName)
 {
     parent::__construct();
     $this->datasourceHandler = $datasourceHandler;
     $this->request = $request;
     $this->columnName = $columnName;
 }
Example #9
0
 /**
  * Constructor.
  *
  * @param array $attributes
  */
 public function __construct(array $attributes = [])
 {
     parent::__construct($attributes);
     $this->setAttribute('value', 0);
     $this->setValueIfAttributeExists('SCRIPT', 1);
     $this->setValueIfAttributeExists('ACCOUNTDISABLE', 2);
     $this->setValueIfAttributeExists('HOMEDIR_REQUIRED', 8);
     $this->setValueIfAttributeExists('LOCKOUT', 16);
     $this->setValueIfAttributeExists('PASSWD_NOTREQD', 32);
     //PASSWD_CANT_CHANGE Note You cannot assign this permission by directly modifying the UserAccountControl attribute.
     //For information about how to set the permission programmatically, see the "Property flag descriptions" section.
     $this->setValueIfAttributeExists('ENCRYPTED_TEXT_PWD_ALLOWED', 128);
     $this->setValueIfAttributeExists('TEMP_DUPLICATE_ACCOUNT', 256);
     $this->setValueIfAttributeExists('NORMAL_ACCOUNT', 512);
     $this->setValueIfAttributeExists('INTERDOMAIN_TRUST_ACCOUNT', 2048);
     $this->setValueIfAttributeExists('WORKSTATION_TRUST_ACCOUNT', 4096);
     $this->setValueIfAttributeExists('SERVER_TRUST_ACCOUNT', 8192);
     $this->setValueIfAttributeExists('DONT_EXPIRE_PASSWORD', 65536);
     $this->setValueIfAttributeExists('MNS_LOGON_ACCOUNT', 131072);
     $this->setValueIfAttributeExists('SMARTCARD_REQUIRED', 262144);
     $this->setValueIfAttributeExists('TRUSTED_FOR_DELEGATION', 524288);
     $this->setValueIfAttributeExists('NOT_DELEGATED', 1048576);
     $this->setValueIfAttributeExists('USE_DES_KEY_ONLY', 2097152);
     $this->setValueIfAttributeExists('DONT_REQ_PREAUTH', 4194304);
     $this->setValueIfAttributeExists('PASSWORD_EXPIRED', 8388608);
     $this->setValueIfAttributeExists('TRUSTED_TO_AUTH_FOR_DELEGATION', 16777216);
 }
 public function __construct($select, $from, $where, $groupBy, $having) {
     parent::__construct();
     $this->select = $select;
     $this->from = $from;
     $this->where = $where;
     $this->groupBy = $groupBy;
     $this->having = $having;
 }
Example #11
0
 public function __construct(array $data = NULL, $keyColumnNames = NULL, $columnPrefix = NULL, $columnSuffix = NULL)
 {
     parent::__construct();
     $this->keyColumnNames = ArrayHelper::toArray($keyColumnNames);
     $this->columnPrefix = $columnPrefix;
     $this->columnSuffix = $columnSuffix;
     $this->data = $data;
 }
Example #12
0
 public function __construct(DateTime $datetime)
 {
     parent::__construct();
     if ($datetime === FALSE) {
         throw new IllegalArgumentException(t('Invalid date and/or time value'));
     }
     $this->datetime = $datetime;
 }
Example #13
0
 public function __construct($prefix, CacheHandler $handler, $allowCopyInLocalCache)
 {
     parent::__construct();
     $this->prefix = $prefix;
     $this->handler = $handler;
     if ($allowCopyInLocalCache) {
         $this->localCacheHandler = new InMemoryCacheHandler($prefix);
     }
 }
 public function __construct(AbstractObject $parent, $data, $required = false)
 {
     parent::__construct($parent);
     $type = self::words_shift($data);
     $this->name = self::words_shift($data);
     $this->description = $data;
     $this->required = (bool) $required;
     $this->schema = new Schema($this, $type);
 }
Example #15
0
 public function __construct($attributes_)
 {
     parent::__construct($attributes_);
     if (!$this->is_valid()) {
         return;
     }
     $this->id = $attributes_['id'];
     $this->status = $attributes_['status'];
 }
Example #16
0
 public function __construct(AbstractObject $parent, $type, $description = null)
 {
     parent::__construct($parent);
     $this->type = strtolower($type);
     if (!in_array($this->type, array('string', 'number', 'integer', 'boolean', 'array'))) {
         throw new \SwaggerGen\Exception('Header type not valid: ' . $type);
     }
     $this->description = $description;
 }
Example #17
0
 public function __construct(AbstractObject $parent, $name, $url = null)
 {
     parent::__construct($parent);
     $this->name = empty($name) ? null : $name;
     if (!empty($url)) {
         $this->url = $url;
     } elseif (!empty(self::$licenses[strtolower($name)])) {
         $this->url = self::$licenses[strtolower($name)];
     }
 }
Example #18
0
 public function __construct($attributes_)
 {
     parent::__construct($attributes_);
     if (!$this->is_valid()) {
         return;
     }
     $this->id = $attributes_['id'];
     $this->title = $attributes_['title'];
     $this->content = $attributes_['content'];
     $this->timestamp = $attributes_['timestamp'];
 }
 public function __construct($attributes_)
 {
     parent::__construct($attributes_);
     if (!$this->is_valid()) {
         return;
     }
     $this->id = $attributes_['id'];
     $this->name = $attributes_['name'];
     $this->description = $attributes_['description'];
     $this->published = $attributes_['published'];
 }
Example #20
0
 public function __construct($attributes_)
 {
     parent::__construct($attributes_);
     if (!$this->is_valid()) {
         return;
     }
     $this->id = $attributes_['id'];
     $this->name = $attributes_['name'];
     $this->type = $attributes_['type'];
     $this->os = $attributes_['os'];
     $this->data = $attributes_['data'];
 }
Example #21
0
 public function __construct(AbstractObject $parent, $code, $definition, $description = null)
 {
     parent::__construct($parent);
     if ($definition) {
         $this->schema = new Schema($this, $definition);
     }
     if (!empty($description)) {
         $this->description = $description;
     } elseif (isset(self::$httpCodes[$code])) {
         $this->description = self::$httpCodes[$code];
     }
 }
Example #22
0
 public function __construct($attributes_)
 {
     parent::__construct($attributes_);
     if (!$this->is_valid()) {
         return;
     }
     $this->id = $attributes_['id'];
     $this->type = $attributes_['type'];
     $this->t_begin = $attributes_['t_begin'];
     $this->t_end = $attributes_['t_end'];
     $this->server = $attributes_['server'];
     $this->status = $attributes_['status'];
 }
 /**
  * Constructs a MultiDimensionalArray with the specified dimensions.
  *
  */
 public function __construct($dimensions)
 {
     parent::__construct();
     $length = sizeof($dimensions);
     $this->dimensions = new BasicArray($length);
     $this->factors = new BasicArray($length);
     $product = 1;
     for ($i = $length - 1; $i >= 0; --$i) {
         $this->dimensions[$i] = $dimensions[$i];
         $this->factors[$i] = $product;
         $product *= $this->dimensions[$i];
     }
     $this->data = new BasicArray($product);
 }
    public function __construct(
            $datatype, $isVisible = TRUE, $parentDataType = NULL,
            $isParentShownOnSelect = FALSE, $isAutomaticallyExpanded = FALSE,
            $isKeyCompatible = FALSE, $isFormulaExpressionCompatible = FALSE) {
        parent::__construct();

        $this->datatype = $datatype;
        $this->isVisible = $isVisible;

        $this->parentDataType = $parentDataType;
        $this->isParentShownOnSelect = $isParentShownOnSelect;
        $this->isAutomaticallyExpanded = $isAutomaticallyExpanded;

        $this->isKeyCompatible = $isKeyCompatible;
        $this->isFormulaExpressionCompatible = $isFormulaExpressionCompatible;
    }
 /**
  * Create a new SecurityScheme object
  * @param \SwaggerGen\Swagger\AbstractObject $parent
  * @param string $type
  * @param string $data
  * @throws \SwaggerGen\Exception
  */
 public function __construct(AbstractObject $parent, $type, $data = null)
 {
     parent::__construct($parent);
     if (!in_array(strtolower($type), array('basic', 'apikey', 'oauth2'))) {
         throw new \SwaggerGen\Exception("Security scheme type must be either 'basic', 'apiKey' or 'oauth2', not '{$type}'");
     }
     $this->type = strtolower($type);
     switch ($this->type) {
         case 'basic':
             $this->description = $data;
             break;
         case 'apikey':
             $this->name = self::words_shift($data);
             $in = strtolower(self::words_shift($data));
             if (!in_array($in, array('query', 'header'))) {
                 throw new \SwaggerGen\Exception("ApiKey in must be either 'query' or 'header', not '{$in}'");
             }
             $this->in = $in;
             $this->description = $data;
             break;
         case 'oauth2':
             $flow = strtolower(self::words_shift($data));
             if (!in_array($flow, array('implicit', 'password', 'application', 'accesscode'))) {
                 throw new \SwaggerGen\Exception("OAuth2 flow must be either 'implicit', 'password', 'application' or 'accesscode', not '{$flow}'");
             }
             $this->flow = $flow;
             if (in_array($flow, array('implicit', 'password'))) {
                 $authUrl = self::words_shift($data);
                 if (!filter_var($authUrl, FILTER_VALIDATE_URL)) {
                     throw new \SwaggerGen\Exception("OAuth2 authorization URL invalid: '{$authUrl}'");
                 }
                 $this->authorizationUrl = $authUrl;
             }
             if (in_array($flow, array('password', 'application', 'accesscode'))) {
                 $tokenUrl = self::words_shift($data);
                 if (!filter_var($tokenUrl, FILTER_VALIDATE_URL)) {
                     throw new \SwaggerGen\Exception("OAuth2 token URL invalid: '{$tokenUrl}'");
                 }
                 $this->tokenUrl = $tokenUrl;
             }
             $this->description = $data;
             break;
     }
 }
Example #26
0
 public function __construct(AbstractObject $parent, $in, $data, $required = false)
 {
     parent::__construct($parent);
     $this->in = $in;
     $definition = self::words_shift($data);
     $this->name = self::words_shift($data);
     $this->description = $data;
     $this->required = (bool) $required;
     // Parse regex
     $match = array();
     $count = preg_match('/^([a-z]+)/i', $definition, $match);
     $format = strtolower($match[1]);
     if (isset(self::$classTypes[$format])) {
         $type = self::$classTypes[$format];
         $class = "SwaggerGen\\Swagger\\Type\\{$type}Type";
         $this->Type = new $class($this, $definition);
     } else {
         throw new \SwaggerGen\Exception('Type format not recognized: ' . $format);
     }
 }
Example #27
0
 /**
  * Constructs a BasicArray.
  *
  * @param mixed $arg1 Either an integer or an array.
  * If an integer, this argument specifies the array length.
  * If an array, this array is initialized with contents of the given array.
  * @param integer $arg2 The base index. (Optional).
  */
 public function __construct($arg1 = 0, $baseIndex = 0)
 {
     parent::__construct();
     if (gettype($arg1) == 'integer') {
         $this->length = $arg1;
         $this->data = array();
         for ($i = 0; $i < $this->length; ++$i) {
             $this->data[$i] = NULL;
         }
         $this->baseIndex = $baseIndex;
     } elseif (gettype($arg1) == 'array') {
         $this->length = sizeof($arg1);
         $this->data = array();
         for ($i = 0; $i < $this->length; ++$i) {
             $this->data[$i] = $arg1[$i];
         }
         $this->baseIndex = $baseIndex;
     } else {
         throw new TypeError();
     }
 }
Example #28
0
 public function __construct()
 {
     parent::__construct();
     $this->version = uniqid();
 }
 public function __construct($array = null, $success = true)
 {
     parent::__construct($array, $success);
 }
 public function __construct($array = null)
 {
     parent::__construct($array, true);
 }