public function setValidationRulesAttribute($value)
    {
        //If the passed value is a string, we assume the request wants to save a validation
        //string. Otherwise, we parse the array given to build such a string.
        if (is_string($value)) {
            $this->attributes['validation_rules'] = $value;
        }

        else {
            $this->attributes['validation_rules'] = ValidationRulesParser::parse($value)->toString();
        }
    }
public function setValidationRulesAttribute($value)
    {
        //If the passed value is a string, we assume the request wants to save a validation
        //string. Otherwise, we parse the array given to build such a string.
        if (is_string($value)) {
            $this->attributes['validation_rules'] = $value;
        }

        else {
            $this->attributes['validation_rules'] = ValidationRulesParser::parse($value)->toString();
        }
    }
public function setValidationRulesAttribute ( $ value ) { //If the passed value is a string, we assume the request wants to save a validation //string. Otherwise, we parse the array given to build such a string. if ( is_string ( $ value ) ) { $ this -> attributes [ 'validation_rules' ] = $ value ; } else { $ this -> attributes [ 'validation_rules' ] = ValidationRulesParser :: parse ( $ value ) -> toString ( ) ; } }
Set the validation_rules with the given value.

@param  array|string  $value

@return void
Set the validation_rules with the given value .