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