original_string: public function validated()
      {
          if ($this->invalid()) {
              throw new ValidationException($this);
          }
  
          $results = [];
  
          $missingValue = Str::random(10);
  
          foreach (array_keys($this->getRules()) as $key) {
              $value = data_get($this->getData(), $key, $missingValue);
  
              if ($value !== $missingValue) {
                  Arr::set($results, $key, $value);
              }
          }
  
          return $results;
      }
code: public function validated()
      {
          if ($this->invalid()) {
              throw new ValidationException($this);
          }
  
          $results = [];
  
          $missingValue = Str::random(10);
  
          foreach (array_keys($this->getRules()) as $key) {
              $value = data_get($this->getData(), $key, $missingValue);
  
              if ($value !== $missingValue) {
                  Arr::set($results, $key, $value);
              }
          }
  
          return $results;
      }
code_tokens: public function validated ( ) { if ( $ this -> invalid ( ) ) { throw new ValidationException ( $ this ) ; } $ results = [ ] ; $ missingValue = Str :: random ( 10 ) ; foreach ( array_keys ( $ this -> getRules ( ) ) as $ key ) { $ value = data_get ( $ this -> getData ( ) , $ key , $ missingValue ) ; if ( $ value !== $ missingValue ) { Arr :: set ( $ results , $ key , $ value ) ; } } return $ results ; }
docstring: Get the attributes and values that were validated.
  
  @return array
  
  @throws \Illuminate\Validation\ValidationException
docstring_tokens: Get the attributes and values that were validated .