original_string: public function resource($path = null)
      {
          if (!empty($path)) {
              $this->resourcePath = $path;
  
              return $this;
          }
  
          if (!empty($this->resourcePath)) {
              return $this->resourcePath;
          }
  
          return app('request')->getPathInfo();
      }
code: public function resource($path = null)
      {
          if (!empty($path)) {
              $this->resourcePath = $path;
  
              return $this;
          }
  
          if (!empty($this->resourcePath)) {
              return $this->resourcePath;
          }
  
          return app('request')->getPathInfo();
      }
code_tokens: public function resource ( $ path = null ) { if ( ! empty ( $ path ) ) { $ this -> resourcePath = $ path ; return $ this ; } if ( ! empty ( $ this -> resourcePath ) ) { return $ this -> resourcePath ; } return app ( 'request' ) -> getPathInfo ( ) ; }
docstring: Get current resource uri.
  
  @param string $path
  
  @return string
docstring_tokens: Get current resource uri .