original_string: public function _setAttributes($attributes)
      {
          if (is_array($attributes)) {
              foreach ($attributes as $attribute => $value) {
                  $this->{$attribute} = $value;
              }
  
              return $this;
          }
  
          //@todo: put real exception here cos exception' gon be thrown either ways, so put one that makes sense
          //or something else that has more meaning
          throw new \InvalidArgumentException('Invalid argument Passed to set attributes on object');
      }
code: public function _setAttributes($attributes)
      {
          if (is_array($attributes)) {
              foreach ($attributes as $attribute => $value) {
                  $this->{$attribute} = $value;
              }
  
              return $this;
          }
  
          //@todo: put real exception here cos exception' gon be thrown either ways, so put one that makes sense
          //or something else that has more meaning
          throw new \InvalidArgumentException('Invalid argument Passed to set attributes on object');
      }
code_tokens: public function _setAttributes ( $ attributes ) { if ( is_array ( $ attributes ) ) { foreach ( $ attributes as $ attribute => $ value ) { $ this -> { $ attribute } = $ value ; } return $ this ; } //@todo: put real exception here cos exception' gon be thrown either ways, so put one that makes sense //or something else that has more meaning throw new \ InvalidArgumentException ( 'Invalid argument Passed to set attributes on object' ) ; }
docstring: Set attributes of the model.
  
  @param $attributes
  
  @throws \Exception
  
  @return $this
docstring_tokens: Set attributes of the model .