original_string: public function sortBy(string $property, string $order = 'asc'): self
      {
          if ($order !== 'asc' && $order !== 'desc') {
              throw new \InvalidArgumentException('The order argument \'asc\' or \'desc\'');
          }
          $this->internalDataListActions[] = ['sortBy', $property, $order];
          return $this;
      }
code: public function sortBy(string $property, string $order = 'asc'): self
      {
          if ($order !== 'asc' && $order !== 'desc') {
              throw new \InvalidArgumentException('The order argument \'asc\' or \'desc\'');
          }
          $this->internalDataListActions[] = ['sortBy', $property, $order];
          return $this;
      }
code_tokens: public function sortBy ( string $ property , string $ order = 'asc' ) : self { if ( $ order !== 'asc' && $ order !== 'desc' ) { throw new \ InvalidArgumentException ( 'The order argument \'asc\' or \'desc\'' ) ; } $ this -> internalDataListActions [ ] = [ 'sortBy' , $ property , $ order ] ; return $ this ; }
docstring: Sorts the elements of the list by specific property.
  
  @param string $property The property name.
  @param string $order The sort order.
  @return self A reference to the list.
  @throws \InvalidArgumentException
docstring_tokens: Sorts the elements of the list by specific property .