original_string: public function composer($full = false)
      {
          $cacheKey = "composer({$this->_packageName}, {$full})";
          if ($cache = static::cache($cacheKey)) {
              return $cache;
          }
  
          $jsonPath = normalizePath($this->path() . '/composer.json');
          if (!is_readable($jsonPath)) {
              return [];
          }
  
          $json = json_decode(file_get_contents($jsonPath), true);
          if (empty($json)) {
              return [];
          }
  
          if ($full) {
              $json = Hash::merge(JsonSchema::$schema, $json);
          }
  
          return static::cache($cacheKey, $json);
      }
code: public function composer($full = false)
      {
          $cacheKey = "composer({$this->_packageName}, {$full})";
          if ($cache = static::cache($cacheKey)) {
              return $cache;
          }
  
          $jsonPath = normalizePath($this->path() . '/composer.json');
          if (!is_readable($jsonPath)) {
              return [];
          }
  
          $json = json_decode(file_get_contents($jsonPath), true);
          if (empty($json)) {
              return [];
          }
  
          if ($full) {
              $json = Hash::merge(JsonSchema::$schema, $json);
          }
  
          return static::cache($cacheKey, $json);
      }
code_tokens: public function composer ( $ full = false ) { $ cacheKey = "composer({$this->_packageName}, {$full})" ; if ( $ cache = static :: cache ( $ cacheKey ) ) { return $ cache ; } $ jsonPath = normalizePath ( $ this -> path ( ) . '/composer.json' ) ; if ( ! is_readable ( $ jsonPath ) ) { return [ ] ; } $ json = json_decode ( file_get_contents ( $ jsonPath ) , true ) ; if ( empty ( $ json ) ) { return [ ] ; } if ( $ full ) { $ json = Hash :: merge ( JsonSchema :: $ schema , $ json ) ; } return static :: cache ( $ cacheKey , $ json ) ; }
docstring: Gets composer json information for this package.
  
  @param bool $full Whether to get full composer schema or not. Defaults to
  false, only defined keys in JSON file will be fetched
  @return array Package's "composer.json" file as an array, an empty array if
  corrupt or not found
docstring_tokens: Gets composer json information for this package .