public function setDefaultValue($value)
    {
        if (($value instanceof ValueGenerator) === false) {
            $value = new ValueGenerator($value);
            $value->setOutputMode(ValueGenerator::OUTPUT_SINGLE_LINE);
        }

        if ($this->isValidPropertyDefaultValue($value) !== true) {
            throw new InvalidArgumentException('Parameter default value is not valid.');
        }

        $this->defaultValue = $value;

        return $this;
    }
public function setDefaultValue($value)
    {
        if (($value instanceof ValueGenerator) === false) {
            $value = new ValueGenerator($value);
            $value->setOutputMode(ValueGenerator::OUTPUT_SINGLE_LINE);
        }

        if ($this->isValidPropertyDefaultValue($value) !== true) {
            throw new InvalidArgumentException('Parameter default value is not valid.');
        }

        $this->defaultValue = $value;

        return $this;
    }
public function setDefaultValue ( $ value ) { if ( ( $ value instanceof ValueGenerator ) === false ) { $ value = new ValueGenerator ( $ value ) ; $ value -> setOutputMode ( ValueGenerator :: OUTPUT_SINGLE_LINE ) ; } if ( $ this -> isValidPropertyDefaultValue ( $ value ) !== true ) { throw new InvalidArgumentException ( 'Parameter default value is not valid.' ) ; } $ this -> defaultValue = $ value ; return $ this ; }
Set the default value for the property.

@param mixed $value The value for the property.
@return \Wingu\OctopusCore\CodeGenerator\PHP\OOP\PropertyGenerator
@throws \Wingu\OctopusCore\CodeGenerator\Exceptions\InvalidArgumentException If the value is not valid.
Set the default value for the property .