private function setPropertyIfExists($property, $value)
    {
        if (property_exists($this, $property)) {
            if ($value == null) {
                return $this;
            }

            $action = new HpsBuilderAction($property, array($this, 'setProperty'));
            $action->arguments = array($property, $value);
            $this->addAction($action);
        } else {
            throw new HpsUnknownPropertyException($this, $property);
        }
        return $this;
    }
private function setPropertyIfExists($property, $value)
    {
        if (property_exists($this, $property)) {
            if ($value == null) {
                return $this;
            }

            $action = new HpsBuilderAction($property, array($this, 'setProperty'));
            $action->arguments = array($property, $value);
            $this->addAction($action);
        } else {
            throw new HpsUnknownPropertyException($this, $property);
        }
        return $this;
    }
private function setPropertyIfExists ( $ property , $ value ) { if ( property_exists ( $ this , $ property ) ) { if ( $ value == null ) { return $ this ; } $ action = new HpsBuilderAction ( $ property , array ( $ this , 'setProperty' ) ) ; $ action -> arguments = array ( $ property , $ value ) ; $ this -> addAction ( $ action ) ; } else { throw new HpsUnknownPropertyException ( $ this , $ property ) ; } return $ this ; }
Sets a property if it exists on the current object.

@param string $property
@param mixed  $value

@throws HpsUnknownPropertyException

@return null
Sets a property if it exists on the current object .