original_string: protected function getResourceName($name, $format = true)
      {
          // we assume its already formatted to resource name
          if ($name && $format === false) {
              return $name;
          }
  
          $name = isset($name) ? $name : $this->resource;
  
          $this->resource = lcfirst(str_singular(class_basename($name)));
          $this->resourceLowerCase = strtolower($name);
  
          return $this->resource;
      }
code: protected function getResourceName($name, $format = true)
      {
          // we assume its already formatted to resource name
          if ($name && $format === false) {
              return $name;
          }
  
          $name = isset($name) ? $name : $this->resource;
  
          $this->resource = lcfirst(str_singular(class_basename($name)));
          $this->resourceLowerCase = strtolower($name);
  
          return $this->resource;
      }
code_tokens: protected function getResourceName ( $ name , $ format = true ) { // we assume its already formatted to resource name if ( $ name && $ format === false ) { return $ name ; } $ name = isset ( $ name ) ? $ name : $ this -> resource ; $ this -> resource = lcfirst ( str_singular ( class_basename ( $ name ) ) ) ; $ this -> resourceLowerCase = strtolower ( $ name ) ; return $ this -> resource ; }
docstring: Get the resource name
  
  @param      $name
  @param bool $format
  @return string
docstring_tokens: Get the resource name