public class RegistryClient extends Object
Constructor and Description |
---|
RegistryClient(String baseUrl) |
RegistryClient(String baseUrl,
SecurityContext securityContext,
String username,
String password) |
Modifier and Type | Method and Description |
---|---|
void |
changeStatusOfPackage(String packageGuid,
ObjectAction action)
Approve, deprecate, or undeprecate of a package
|
void |
changeStatusOfPackageMembers(String packageGuid,
ObjectAction action)
Approve, deprecate, or undeprecate all members of a package
|
<T extends RegistryObject> |
deleteObject(String guid,
Class<T> objectClass)
Removes an object from the registry of the given type
|
void |
deletePackageMembers(String packageGuid)
Deletes all members that are associated with the given package guid.
|
PagedResponse<Association> |
getAssociations(RegistryQuery<AssociationFilter> query,
Integer start,
Integer rows)
Retrieves a set of association objects that match the query.
|
PagedResponse<AuditableEvent> |
getAuditableEvents(RegistryQuery<EventFilter> query,
Integer start,
Integer rows)
Retrieves a paged set of registry objects from the collection of objects of
the specified type.
|
PagedResponse<ExtrinsicObject> |
getExtrinsics(RegistryQuery<ExtrinsicFilter> query,
Integer start,
Integer rows)
Retrieves a set of extrinsic objects that match the query.
|
<T extends RegistryObject> |
getLatestObject(String lid,
Class<T> objectClass)
Retrieve the latest version of a registry object
|
<T extends RegistryObject> |
getObject(String guid,
Class<T> objectClass)
Retrieves an object from the registry of the given type
|
<T extends RegistryObject> |
getObjects(Integer start,
Integer rows,
Class<T> objectClass)
Retrieves a paged set of registry objects from the collection of objects of
the specified type.
|
PagedResponse<RegistryPackage> |
getPackages(RegistryQuery<PackageFilter> query,
Integer start,
Integer rows)
Retrieves a set of package objects that match the query.
|
String |
getRegistrationPackageGuid() |
Report |
getReport() |
static void |
main(String[] args) |
String |
publishObject(RegistryObject object)
Publish a registry object to the service
|
void |
publishObjects(RegistryObjectList objects)
Publishes list of registry objects to the service
|
void |
setMediaType(String mediaType)
Used to override the type of messages the client will exchange.
|
void |
setRegistrationPackageId(String registrationPackageGuid) |
void |
updateObject(RegistryObject object)
Updates the given registry object by using its guid to indicate the object
to update.
|
String |
versionObject(RegistryObject object)
Publishes a version of the given object that is considered a major version
update.
|
String |
versionObject(RegistryObject object,
Boolean major)
Publishes a version of the given object
|
void |
versionObject(RegistryObjectList objects)
Publishes list of versioned given object that is considered a major version
update.
|
void |
versionObjects(RegistryObjectList objects,
Boolean major)
Publishes list of versined objects to the service
|
public RegistryClient(String baseUrl) throws RegistryClientException
RegistryClientException
public RegistryClient(String baseUrl, SecurityContext securityContext, String username, String password) throws RegistryClientException
RegistryClientException
public void setMediaType(String mediaType)
mediaType
- to use for exchanging messagespublic <T extends RegistryObject> T getObject(String guid, Class<T> objectClass) throws RegistryServiceException
guid
- identifier for the objectobjectClass
- of object interested in retrievingRegistryServiceException
public <T extends RegistryObject> void deleteObject(String guid, Class<T> objectClass) throws RegistryServiceException
T
- guid
- identifier for the objectobjectClass
- of object interested in deletingRegistryServiceException
public void deletePackageMembers(String packageGuid) throws RegistryServiceException
packageGuid
- to delete fromRegistryServiceException
public void changeStatusOfPackageMembers(String packageGuid, ObjectAction action) throws RegistryServiceException
packageGuid
- to update members fromaction
- to take which will end up affecting members statusesRegistryServiceException
public void changeStatusOfPackage(String packageGuid, ObjectAction action) throws RegistryServiceException
packageGuid
- to updateaction
- to take which will end up affecting package statusesRegistryServiceException
public String publishObject(RegistryObject object) throws RegistryServiceException
object
- to publishRegistryServiceException
public void publishObjects(RegistryObjectList objects) throws RegistryServiceException
object
- to publishRegistryServiceException
public String versionObject(RegistryObject object) throws RegistryServiceException
object
- to publishRegistryServiceException
public String versionObject(RegistryObject object, Boolean major) throws RegistryServiceException
object
- to publishmajor
- flag to indicate major or minor versionRegistryServiceException
public void versionObjects(RegistryObjectList objects, Boolean major) throws RegistryServiceException
object
- to publishmajor
- flag to indicate major or minor versionRegistryServiceException
public void versionObject(RegistryObjectList objects) throws RegistryServiceException
object
- to publishRegistryServiceException
public void updateObject(RegistryObject object) throws RegistryServiceException
object
- to update toRegistryServiceException
public <T extends RegistryObject> T getLatestObject(String lid, Class<T> objectClass) throws RegistryServiceException
lid
- logical identifier which is associated with a collection of
objectsobjectClass
- of object interested in retrievingRegistryServiceException
public <T extends RegistryObject> PagedResponse<T> getObjects(Integer start, Integer rows, Class<T> objectClass) throws RegistryServiceException
start
- indicates where in the set of objects to beginrows
- indicates how many objects to returnobjectClass
- the type of object to retrieveRegistryServiceException
public PagedResponse<ExtrinsicObject> getExtrinsics(RegistryQuery<ExtrinsicFilter> query, Integer start, Integer rows) throws RegistryServiceException
query
- filters for the extrinsicstart
- indicates where in the set of objects to beginrows
- indicates how many objects to returnRegistryServiceException
public PagedResponse<RegistryPackage> getPackages(RegistryQuery<PackageFilter> query, Integer start, Integer rows) throws RegistryServiceException
query
- filters for the packagestart
- indicates where in the set of objects to beginrows
- indicates how many objects to returnRegistryServiceException
public PagedResponse<Association> getAssociations(RegistryQuery<AssociationFilter> query, Integer start, Integer rows) throws RegistryServiceException
query
- filters for the associationstart
- indicates where in the set of objects to beginrows
- indicates how many objects to returnRegistryServiceException
public PagedResponse<AuditableEvent> getAuditableEvents(RegistryQuery<EventFilter> query, Integer start, Integer rows) throws RegistryServiceException
start
- indicates where in the set of objects to beginrows
- indicates how many objects to returnobjectClass
- the type of object to retrieveRegistryServiceException
public Report getReport() throws RegistryServiceException
RegistryServiceException
public String getRegistrationPackageGuid()
public void setRegistrationPackageId(String registrationPackageGuid)
Copyright © 2010–2015 Planetary Data System. All rights reserved.