public class SyncAccessPolicy
extends java.lang.Object
Constructor and Description |
---|
SyncAccessPolicy() |
Modifier and Type | Method and Description |
---|---|
boolean |
isEqual(org.dataone.service.types.v1.AccessPolicy ap1,
org.dataone.service.types.v1.AccessPolicy ap2)
Compare two d1 system metadata access policies for equivalence.
|
static void |
main(java.lang.String[] args)
Run pid synch script on the given pids Each argument is an individual pid
because pids cannot contain whitespace.
|
java.util.List<org.dataone.service.types.v1.Identifier> |
sync(java.util.List<java.lang.String> guidsToSync)
Convenience function that accepts a list of guids to sync
|
void |
syncAll()
For all guids for which current MN is authoritative, check that access
policy is synced with CN.
|
public java.util.List<org.dataone.service.types.v1.Identifier> sync(java.util.List<java.lang.String> guidsToSync) throws java.lang.NumberFormatException, org.dataone.service.exceptions.ServiceFailure, org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotFound, org.dataone.service.exceptions.NotImplemented, McdbDocNotFoundException, org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.VersionMismatch, AccessionNumberException, java.sql.SQLException, java.lang.Exception
guidsToSync
- list of guids to have access policy synced forjava.lang.NumberFormatException
org.dataone.service.exceptions.ServiceFailure
org.dataone.service.exceptions.InvalidToken
org.dataone.service.exceptions.NotAuthorized
org.dataone.service.exceptions.NotFound
org.dataone.service.exceptions.NotImplemented
McdbDocNotFoundException
org.dataone.service.exceptions.InvalidRequest
org.dataone.service.exceptions.VersionMismatch
AccessionNumberException
java.sql.SQLException
java.lang.Exception
public void syncAll() throws org.dataone.service.exceptions.ServiceFailure, org.dataone.service.exceptions.InvalidToken, org.dataone.service.exceptions.NotAuthorized, org.dataone.service.exceptions.NotFound, org.dataone.service.exceptions.NotImplemented, McdbDocNotFoundException, org.dataone.service.exceptions.InvalidRequest, org.dataone.service.exceptions.VersionMismatch, java.lang.NumberFormatException, AccessionNumberException, java.sql.SQLException, edu.ucsb.nceas.utilities.PropertyNotFoundException, ServiceException, java.lang.Exception
org.dataone.service.exceptions.ServiceFailure
org.dataone.service.exceptions.InvalidToken
org.dataone.service.exceptions.NotAuthorized
org.dataone.service.exceptions.NotFound
org.dataone.service.exceptions.NotImplemented
McdbDocNotFoundException
org.dataone.service.exceptions.InvalidRequest
org.dataone.service.exceptions.VersionMismatch
java.lang.NumberFormatException
AccessionNumberException
java.sql.SQLException
edu.ucsb.nceas.utilities.PropertyNotFoundException
ServiceException
java.lang.Exception
public boolean isEqual(org.dataone.service.types.v1.AccessPolicy ap1, org.dataone.service.types.v1.AccessPolicy ap2)
ap1
- - first access policy in the comparisonap2
- - second access policy in the comparisonpublic static void main(java.lang.String[] args) throws java.lang.Exception
args
- java.lang.Exception
Copyright © 2020 Regents of the University of California. All Rights Reserved.