@Component
public class UniversallyUniqueIdentifierProvider
extends org.dspace.identifier.IdentifierProvider
| Modifier and Type | Field and Description |
|---|---|
protected static String |
EXAMPLE_PREFIX
Prefix registered to no one
|
protected String[] |
supportedPrefixes |
| Constructor and Description |
|---|
UniversallyUniqueIdentifierProvider() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
createNewIdentifier(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String uuidId) |
void |
delete(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso) |
void |
delete(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier) |
protected static org.dspace.storage.rdbms.TableRow |
findUuidInternal(org.dspace.core.Context context,
String uuid)
Find the database row corresponding to uuid.
|
protected static org.dspace.storage.rdbms.TableRow |
getUuidInternal(org.dspace.core.Context context,
int type,
int id)
Return the uuid for an Object, or null if the Object has no uuid.
|
String |
lookup(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso) |
String |
mint(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso)
Mint a Identifier for this object if it does not already exist in the Database.
|
protected String |
modifyUuidRecord(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
org.dspace.storage.rdbms.TableRow uuid,
String uuidId) |
String |
register(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso) |
void |
register(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier) |
void |
reserve(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier) |
org.dspace.content.DSpaceObject |
resolve(org.dspace.core.Context context,
String identifier,
String... attributes) |
static String |
retrieveUuidOutOfUrl(String url) |
boolean |
supports(Class<? extends org.dspace.identifier.Identifier> identifier) |
boolean |
supports(String identifier) |
protected static final String EXAMPLE_PREFIX
protected String[] supportedPrefixes
public boolean supports(Class<? extends org.dspace.identifier.Identifier> identifier)
supports in class org.dspace.identifier.IdentifierProviderpublic boolean supports(String identifier)
supports in class org.dspace.identifier.IdentifierProviderpublic String register(org.dspace.core.Context context, org.dspace.content.DSpaceObject dso)
register in class org.dspace.identifier.IdentifierProviderpublic void register(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier)
register in class org.dspace.identifier.IdentifierProviderpublic void reserve(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier)
reserve in class org.dspace.identifier.IdentifierProviderpublic String mint(org.dspace.core.Context context, org.dspace.content.DSpaceObject dso)
mint in class org.dspace.identifier.IdentifierProvidercontext - DSpace contextdso - The DSpaceObject to create a uuid forSQLException - If a database error occurspublic org.dspace.content.DSpaceObject resolve(org.dspace.core.Context context,
String identifier,
String... attributes)
resolve in class org.dspace.identifier.IdentifierProviderpublic String lookup(org.dspace.core.Context context, org.dspace.content.DSpaceObject dso) throws org.dspace.identifier.IdentifierNotFoundException, org.dspace.identifier.IdentifierNotResolvableException
lookup in class org.dspace.identifier.IdentifierProviderorg.dspace.identifier.IdentifierNotFoundExceptionorg.dspace.identifier.IdentifierNotResolvableExceptionpublic void delete(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso,
String identifier)
throws org.dspace.identifier.IdentifierException
delete in class org.dspace.identifier.IdentifierProviderorg.dspace.identifier.IdentifierExceptionpublic void delete(org.dspace.core.Context context,
org.dspace.content.DSpaceObject dso)
throws org.dspace.identifier.IdentifierException
delete in class org.dspace.identifier.IdentifierProviderorg.dspace.identifier.IdentifierExceptionpublic static String retrieveUuidOutOfUrl(String url) throws SQLException
SQLExceptionprotected String createNewIdentifier(org.dspace.core.Context context, org.dspace.content.DSpaceObject dso, String uuidId) throws SQLException
SQLExceptionprotected String modifyUuidRecord(org.dspace.core.Context context, org.dspace.content.DSpaceObject dso, org.dspace.storage.rdbms.TableRow uuid, String uuidId) throws SQLException
SQLExceptionprotected static org.dspace.storage.rdbms.TableRow getUuidInternal(org.dspace.core.Context context,
int type,
int id)
throws SQLException
context - DSpace contexttype - The type of objectid - The id of objectSQLException - If a database error occursprotected static org.dspace.storage.rdbms.TableRow findUuidInternal(org.dspace.core.Context context,
String uuid)
throws SQLException
context - DSpace contextuuid - The uuid to resolveSQLException - If a database error occursCopyright © 2014 DuraSpace. All rights reserved.