AttributeType::__construct PHP Method

__construct() public method

public __construct ( )
        public function __construct()
        {
        }

Usage Example

 /**
  * {@inheritdoc}
  *
  * @throws \UnexpectedValueException
  */
 public function __construct($code, $databaseType, $formType, array $formOptions = [])
 {
     if (!in_array($databaseType, ['stringIdentifier', 'integerIdentifier'], true)) {
         $m = "Identifier attribute {$code} can only be a stringIdentifier or an integerIdentifier, '{$databaseType}' given";
         throw new \UnexpectedValueException($m);
     }
     parent::__construct($code, $databaseType, $formType, $formOptions);
     $this->isRelation = false;
 }
All Usage Examples Of AttributeType::__construct