public function getPackageJsonFile($package)
    {
        // We get the project vendor path
        $vendorPath = $this->getVendorPath();
        // We get the target dir of the iterated package
        $targetDir = $package->getTarget();
        $jsonPath = $vendorPath . $targetDir . "/composer.json";
        if (method_exists($package, 'getJsonFile')) {
            $jsonFile = $package->getJsonFile($jsonPath);
        } else {
            // @codeCoverageIgnoreStart
            $jsonFile = new JsonFile($jsonPath);
            // @codeCoverageIgnoreEnd
        }

        return $this->fs->exists($jsonPath) ? $jsonFile->read() : null;
    }
public function getPackageJsonFile($package)
    {
        // We get the project vendor path
        $vendorPath = $this->getVendorPath();
        // We get the target dir of the iterated package
        $targetDir = $package->getTarget();
        $jsonPath = $vendorPath . $targetDir . "/composer.json";
        if (method_exists($package, 'getJsonFile')) {
            $jsonFile = $package->getJsonFile($jsonPath);
        } else {
            // @codeCoverageIgnoreStart
            $jsonFile = new JsonFile($jsonPath);
            // @codeCoverageIgnoreEnd
        }

        return $this->fs->exists($jsonPath) ? $jsonFile->read() : null;
    }
public function getPackageJsonFile ( $ package ) { // We get the project vendor path $ vendorPath = $ this -> getVendorPath ( ) ; // We get the target dir of the iterated package $ targetDir = $ package -> getTarget ( ) ; $ jsonPath = $ vendorPath . $ targetDir . "/composer.json" ; if ( method_exists ( $ package , 'getJsonFile' ) ) { $ jsonFile = $ package -> getJsonFile ( $ jsonPath ) ; } else { // @codeCoverageIgnoreStart $ jsonFile = new JsonFile ( $ jsonPath ) ; // @codeCoverageIgnoreEnd } return $ this -> fs -> exists ( $ jsonPath ) ? $ jsonFile -> read ( ) : null ; }
Returns the Json file of the given Package
@param Package\Link $package
@return mixed
Returns the Json file of the given Package