Package org.eclipse.lyo.trs.client.util
Class TrackedResourceClient
- java.lang.Object
-
- org.eclipse.lyo.trs.client.util.TrackedResourceClient
-
- All Implemented Interfaces:
ITrackedResourceClient
public class TrackedResourceClient extends Object implements ITrackedResourceClient
-
-
Constructor Summary
Constructors Constructor Description TrackedResourceClient(IOslcClient oslcClient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TrackedResourceSet
extractRemoteTrs(URI trsUri)
retieve the trs from the trs provider using the trs uri attribute and return a trs pojo accordinglyBase
fetchRemoteBase(URI baseUrl)
Retrieve the base from the trs provider using the baseURI argument return a base pojo accordinglyChangeLog
fetchRemoteChangeLog(URI changeLogURl)
Retrieve the change log from the trs provider using the changeLogURI argument return a change log pojo accordinglyModel
fetchTRSRemoteResource(URI uri)
List<Base>
updateBases(TrackedResourceSet updatedTrs)
Return a list of base objects corresponding to the pages of the base after requesting them from the base url.
-
-
-
Constructor Detail
-
TrackedResourceClient
public TrackedResourceClient(IOslcClient oslcClient)
-
-
Method Detail
-
fetchTRSRemoteResource
public Model fetchTRSRemoteResource(URI uri) throws RepresentationRetrievalException
- Specified by:
fetchTRSRemoteResource
in interfaceITrackedResourceClient
- Throws:
RepresentationRetrievalException
-
updateBases
public List<Base> updateBases(TrackedResourceSet updatedTrs) throws LyoModelException, RepresentationRetrievalException
Return a list of base objects corresponding to the pages of the base after requesting them from the base url. The base url is retrieved from the trs object passes as a parameter.- Specified by:
updateBases
in interfaceITrackedResourceClient
- Parameters:
updatedTrs
- the trs object retrieved after retrieving it using the trs uri- Returns:
- the pages of the base of this trs provider
- Throws:
LyoModelException
RepresentationRetrievalException
-
extractRemoteTrs
public TrackedResourceSet extractRemoteTrs(URI trsUri) throws LyoModelException, RepresentationRetrievalException
Description copied from interface:ITrackedResourceClient
retieve the trs from the trs provider using the trs uri attribute and return a trs pojo accordingly- Specified by:
extractRemoteTrs
in interfaceITrackedResourceClient
- Returns:
- trs pojo
- Throws:
LyoModelException
RepresentationRetrievalException
-
fetchRemoteChangeLog
public ChangeLog fetchRemoteChangeLog(URI changeLogURl) throws IllegalArgumentException, SecurityException, LyoModelException, RepresentationRetrievalException
Description copied from interface:ITrackedResourceClient
Retrieve the change log from the trs provider using the changeLogURI argument return a change log pojo accordingly- Specified by:
fetchRemoteChangeLog
in interfaceITrackedResourceClient
- Parameters:
changeLogURl
- url of the change log- Returns:
- change log pojo
- Throws:
IllegalArgumentException
SecurityException
LyoModelException
RepresentationRetrievalException
-
fetchRemoteBase
public Base fetchRemoteBase(URI baseUrl) throws LyoModelException, RepresentationRetrievalException
Description copied from interface:ITrackedResourceClient
Retrieve the base from the trs provider using the baseURI argument return a base pojo accordingly- Specified by:
fetchRemoteBase
in interfaceITrackedResourceClient
- Parameters:
baseUrl
- url of the base- Returns:
- base pojo
- Throws:
LyoModelException
RepresentationRetrievalException
-
-