public function setValue($rawValue)
    {
        if ($rawValue === null) {
            $this->value = null;
            return $this;
        }
        if (is_object($rawValue) && $rawValue instanceof $this->dataType) {
            $this->value = $rawValue;
            return $this;
        }
        $this->value = $this->propertyMapper->convert($rawValue, $this->dataType, $this->getPropertyMappingConfiguration());
        $this->validationResults = $this->propertyMapper->getMessages();
        if ($this->validator !== null) {
            $validationMessages = $this->validator->validate($this->value);
            $this->validationResults->merge($validationMessages);
        }

        return $this;
    }
public function setValue($rawValue)
    {
        if ($rawValue === null) {
            $this->value = null;
            return $this;
        }
        if (is_object($rawValue) && $rawValue instanceof $this->dataType) {
            $this->value = $rawValue;
            return $this;
        }
        $this->value = $this->propertyMapper->convert($rawValue, $this->dataType, $this->getPropertyMappingConfiguration());
        $this->validationResults = $this->propertyMapper->getMessages();
        if ($this->validator !== null) {
            $validationMessages = $this->validator->validate($this->value);
            $this->validationResults->merge($validationMessages);
        }

        return $this;
    }
public function setValue ( $ rawValue ) { if ( $ rawValue === null ) { $ this -> value = null ; return $ this ; } if ( is_object ( $ rawValue ) && $ rawValue instanceof $ this -> dataType ) { $ this -> value = $ rawValue ; return $ this ; } $ this -> value = $ this -> propertyMapper -> convert ( $ rawValue , $ this -> dataType , $ this -> getPropertyMappingConfiguration ( ) ) ; $ this -> validationResults = $ this -> propertyMapper -> getMessages ( ) ; if ( $ this -> validator !== null ) { $ validationMessages = $ this -> validator -> validate ( $ this -> value ) ; $ this -> validationResults -> merge ( $ validationMessages ) ; } return $ this ; }
Sets the value of this argument.

@param mixed $rawValue The value of this argument
@return Argument $this
Sets the value of this argument .