code: public function rules($extraRules = [])
      {
          $rules = $this->getRules();
          
          /* Adiciona as regras extras as regras padrão do objeto */
          foreach ($extraRules as $field => $rule) {
              
              if (! key_exists($this->getOnlyField($field), $rules)) {
                  continue;
              }
              
              /* Ajuste para validação de array */
              if (strpos($field, '.') > -1) {
                  
                  $rules[$field] = $rules[$this->getOnlyField($field)] . '|' . $rule;
                  unset($rules[$this->getOnlyField($field)]);
                  continue;
              }
              
              $rules[$field] .= '|' . $rule;
          }
          
          return $this->transformToFrontName($rules);
      }
docs: Get the validation rules that apply to the request.
  
  @return array