original_string: public function versions($reset = false)
      {
          if ($reset === false && $this->has('_versions')) {
              return $this->get('_versions');
          }
  
          /*
           * @var \Josegonzalez\Version\Model\Behavior\VersionBehavior $table
           * @var \Cake\Datasource\EntityInterface $this
           */
          $table = TableRegistry::get($this->getSource());
          $versions = $table->getVersions($this);
          $this->set('_versions', $versions);
  
          return $this->get('_versions');
      }
code: public function versions($reset = false)
      {
          if ($reset === false && $this->has('_versions')) {
              return $this->get('_versions');
          }
  
          /*
           * @var \Josegonzalez\Version\Model\Behavior\VersionBehavior $table
           * @var \Cake\Datasource\EntityInterface $this
           */
          $table = TableRegistry::get($this->getSource());
          $versions = $table->getVersions($this);
          $this->set('_versions', $versions);
  
          return $this->get('_versions');
      }
code_tokens: public function versions ( $ reset = false ) { if ( $ reset === false && $ this -> has ( '_versions' ) ) { return $ this -> get ( '_versions' ) ; } /*
           * @var \Josegonzalez\Version\Model\Behavior\VersionBehavior $table
           * @var \Cake\Datasource\EntityInterface $this
           */ $ table = TableRegistry :: get ( $ this -> getSource ( ) ) ; $ versions = $ table -> getVersions ( $ this ) ; $ this -> set ( '_versions' , $ versions ) ; return $ this -> get ( '_versions' ) ; }
docstring: Retrieves the related versions for the current entity
  
  @param bool $reset If true, will re-retrieve the related version collection
  @return \Cake\Collection\CollectionInterface
docstring_tokens: Retrieves the related versions for the current entity