Set Type

@var string $Type
@return MoneyOut
554722
public function setType($Type)
    {
        $validTypes = [self::TYPE_ONESHOT, self::TYPE_RECURRING];
        if (!in_array($Type, $validTypes)) {
            throw new \InvalidArgumentException(sprintf('Money out type "%s" not supported. Must be one of: "%s"', $Type, implode(',', $validTypes)));
        }
        $this->Type = $Type;

        return $this;
    }
71482
public function setType($type = null)
    {
        $type = $this->calculateTypeValue($type);

        if (!is_int($type) || ($type < 0) || ($type > self::ALL)) {
            throw new Exception\InvalidArgumentException('Unknown type');
        }

        $this->options['type'] = $type;

        return $this;
    }
98001
protected function setValue($value, string $type)
    {
        $this->value = $type !== self::TYPE_CALL
            ? $this->validateValue($value)
            : array_map(function ($value) {
                return $this->validateValue($value);
            }, $value);
    }
292399
public function setType(?string $type): Workflow
    {
        if ($type !== null) {
            Assert::oneOf($type, self::VALID_TYPES);
        }
        $this->type = $type;

        return $this;
    }
449640
public function setType(string $type = "F") : CNabuDataObject
    {
        if ($type === null) {
            throw new ENabuCoreException(
                    ENabuCoreException::ERROR_NULL_VALUE_NOT_ALLOWED_IN,
                    array("\$type")
            );
        }
        $this->setValue('nb_site_alias_type', $type);
        
        return $this;
    }
983723
public function setType($type)
    {
        if (is_string($type) === true) {
            $this->type = $type;
        } else {
            $msg = "The 'type' argument must be a non-empty string representing a mime-type, '" . gettype($type) . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
280956
public function setType($type, $options = null)
    {
        $this->type = $type;
        $this->_setCertConfigure();

        return $this;
    }
97187
public function setType($type)
    {
      if(!is_string($type) || strlen(trim($type)) == 0)
        throw new InvalidArgumentException(__METHOD__ . '; Invalid type, must be a non empty string');

      $this->type = $type;
    }
471503
final public function setType(string $type = null) : ColumnInterface
    {
        if ($type) {
            $available = [
                self::TYPE_ARRAY,
                self::TYPE_BIGINT,
                self::TYPE_BINARY,
                self::TYPE_BLOB,
                self::TYPE_BOOLEAN,
                self::TYPE_BOOLEAN_EMU,
                self::TYPE_BU_DATE,
                self::TYPE_BU_TIMESTAMP,
                self::TYPE_CHAR,
                self::TYPE_CLOB,
                self::TYPE_BINARY,
                self::TYPE_BLOB,
                self::TYPE_DATE,
                self::TYPE_DECIMAL,
                self::TYPE_DOUBLE,
                self::TYPE_ENUM,
                self::TYPE_FLOAT,
                self::TYPE_GEOMETRY,
                self::TYPE_INTEGER,
                self::TYPE_LONGVARBINARY,
                self::TYPE_NUMERIC,
                self::TYPE_OBJECT,
                self::TYPE_REAL,
                self::TYPE_SET,
                self::TYPE_SMALLINT,
                self::TYPE_TIME,
                self::TYPE_TIMESTAMP,
                self::TYPE_TINYINT,
                self::TYPE_VARCHAR,
                self::TYPE_VARBINARY,
            ];

            if (!in_array($type, $available)) {
                throw new \InvalidArgumentException('Invalid Propel type.');
            }
        }

        $this->type = $type;

        return $this;
    }
433227
private function setType(string $type): self
    {
        switch ($type) {
            case 'navigator.id.getAssertion': // fall through
            case 'navigator.id.finishEnrollment':
                break;
            default:
                throw new IDE(IDE::MALFORMED_DATA, 'typ');
        }
        $this->typ = $type;
        return $this;
    }
945160
public function setType($type)
    {
        if (gettype($type) === 'string') {
            $this->type = $type;
        } else {
            $msg = "Type must be a string, '" . gettype($type) . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
59971
public function setType($type)
    {
        if (!in_array($type, self::$TYPES)) {
            throw new \InvalidArgumentException(sprintf(
                "Unknown GalleryItem type (given: '%s', available: '%s')",
                $type,
                implode(', ', self::$TYPES)
            ));
        }
        $this->type = $type;

        return $this;
    }
1374452
public function setType($type)
    {
        $const = sprintf('%s::TYPE_%s', __CLASS__, strtoupper($type));
        
        if(defined($const))
        {
            $type = constant($const);
        }
        
        $this->setAttributeDirectly('type', $type);
        
        $this->enumerationStrategy = null;
    }
62155
public function withType($type)
    {
        $choices = [
            PriceInterface::TYPE_OWN,
            PriceInterface::TYPE_RENT,
        ];

        Assertion::choice($type, $choices);

        $instance = clone $this;

        $instance->type = $type;

        return $instance;
    }
297663
public function setType($type)
    {
        if ($type === null) {
            $type = self::TYPE_UNDEFINED;
        }

        $this->type = $type;

        return $this;
    }
1313969
public function setType(string $type): self
    {
        if (!\in_array($type, self::COLUMN_TYPES, true)) {
            throw new \InvalidArgumentException('Not supported column type '. $type);
        }

        $this->type = $type;

        return $this;
    }
473363
public function setType($type)
    {
        if ($type instanceof Type) {
            $this->setIndex($type->getIndex());
            $type = $type->getName();
        }

        return $this->setParam('_type', $type);
    }