public function getModelVersions($id)
    {
        $modelResult = $this->getRequest()->request(
            'GET',
            $this->getRequestUrl(sprintf('models/%s/versions', $id))
        );

        if (!isset($modelResult['model_versions'])) {
            throw new \Exception('Model Versions Not Found');
        }

        $modelVersions = [];

        foreach ($modelResult['model_versions'] as $version) {
            $modelVersion = new ModelVersion($version);
            $modelVersions[] = $modelVersion;
        }

        return $modelVersions;
    }
public function getModelVersions($id)
    {
        $modelResult = $this->getRequest()->request(
            'GET',
            $this->getRequestUrl(sprintf('models/%s/versions', $id))
        );

        if (!isset($modelResult['model_versions'])) {
            throw new \Exception('Model Versions Not Found');
        }

        $modelVersions = [];

        foreach ($modelResult['model_versions'] as $version) {
            $modelVersion = new ModelVersion($version);
            $modelVersions[] = $modelVersion;
        }

        return $modelVersions;
    }
public function getModelVersions ( $ id ) { $ modelResult = $ this -> getRequest ( ) -> request ( 'GET' , $ this -> getRequestUrl ( sprintf ( 'models/%s/versions' , $ id ) ) ) ; if ( ! isset ( $ modelResult [ 'model_versions' ] ) ) { throw new \ Exception ( 'Model Versions Not Found' ) ; } $ modelVersions = [ ] ; foreach ( $ modelResult [ 'model_versions' ] as $ version ) { $ modelVersion = new ModelVersion ( $ version ) ; $ modelVersions [ ] = $ modelVersion ; } return $ modelVersions ; }
Gets Model Versions

@param $id

@return array

@throws \Exception
Gets Model Versions