org.lexevs.registry.service
Class DatabaseRegistry

java.lang.Object
  extended by org.lexevs.registry.event.RegistryEventSupport
      extended by org.lexevs.registry.service.DatabaseRegistry
All Implemented Interfaces:
Registry

public class DatabaseRegistry
extends RegistryEventSupport
implements Registry

The Class DatabaseRegistry.

Author:
Kevin Peterson

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.lexevs.registry.service.Registry
Registry.KnownTags, Registry.ResourceType
 
Constructor Summary
DatabaseRegistry()
           
 
Method Summary
 void activate(AbsoluteCodingSchemeVersionReference codingScheme)
          Activate.
 void addNewItem(RegistryEntry entry)
          Adds the new item.
 boolean containsCodingSchemeEntry(AbsoluteCodingSchemeVersionReference codingScheme)
          Contains coding scheme entry.
 boolean containsNonCodingSchemeEntry(java.lang.String uri)
          Contains non coding scheme entry.
 java.util.List<RegistryEntry> getAllRegistryEntries()
          Gets the all registry entries.
 java.util.List<RegistryEntry> getAllRegistryEntriesOfType(Registry.ResourceType type)
          Gets the all registry entries of type.
 java.util.List<RegistryEntry> getAllRegistryEntriesOfTypeAndURI(Registry.ResourceType type, java.lang.String uri)
          Gets the all registry entries of type and URI.
 java.util.List<RegistryEntry> getAllRegistryEntriesOfTypeURIAndVersion(Registry.ResourceType type, java.lang.String uri, java.lang.String version)
          Gets the all registry entries of type, URI and version.
 RegistryEntry getCodingSchemeEntry(AbsoluteCodingSchemeVersionReference codingScheme)
          Gets the coding scheme entry.
 java.util.List<RegistryEntry> getEntriesForUri(java.lang.String uri)
          Gets the entries for uri.
 java.util.Date getLastUpdateTime()
          Gets the last update time.
 NextDatabasePrefixGenerator getNextDatabasePrefixGenerator()
          Gets the next database prefix generator.
 java.lang.String getNextDBIdentifier()
          Gets the next db identifier.
 java.lang.String getNextHistoryIdentifier()
          Gets the next history identifier.
 RegistryEntry getNonCodingSchemeEntry(java.lang.String uri)
          Gets the non coding scheme entry.
protected  Registry.ResourceType[] getNonCodingSchemeResourceTypes()
           
 RegistryDao getRegistryDao()
          Gets the registry dao.
 void removeEntry(RegistryEntry entry)
          Removes the entry.
 void setNextDatabasePrefixGenerator(NextDatabasePrefixGenerator nextDatabasePrefixGenerator)
          Sets the next database prefix generator.
 void setRegistryDao(RegistryDao registryDao)
          Sets the registry dao.
 void updateEntry(RegistryEntry entry)
          Update entry.
 
Methods inherited from class org.lexevs.registry.event.RegistryEventSupport
addRegistryListener, fireTagUpdateEvent, getRegistryListeners, setRegistryListeners
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseRegistry

public DatabaseRegistry()
Method Detail

activate

@Transactional
public void activate(AbsoluteCodingSchemeVersionReference codingScheme)
              throws LBInvocationException,
                     LBParameterException
Activate.

Parameters:
codingScheme - the coding scheme
Throws:
LBInvocationException - the LB invocation exception
LBParameterException - the LB parameter exception

addNewItem

@Transactional
public void addNewItem(RegistryEntry entry)
                throws java.lang.Exception
Description copied from interface: Registry
Adds the new item.

Specified by:
addNewItem in interface Registry
Parameters:
entry - the entry
Throws:
java.lang.Exception - the exception

getAllRegistryEntries

@Transactional
public java.util.List<RegistryEntry> getAllRegistryEntries()
Description copied from interface: Registry
Gets the all registry entries.

Specified by:
getAllRegistryEntries in interface Registry
Returns:
the all registry entries

getAllRegistryEntriesOfType

@Transactional
public java.util.List<RegistryEntry> getAllRegistryEntriesOfType(Registry.ResourceType type)
Description copied from interface: Registry
Gets the all registry entries of type.

Specified by:
getAllRegistryEntriesOfType in interface Registry
Parameters:
type - the type
Returns:
the all registry entries of type

getAllRegistryEntriesOfTypeAndURI

@Transactional
public java.util.List<RegistryEntry> getAllRegistryEntriesOfTypeAndURI(Registry.ResourceType type,
                                                                                     java.lang.String uri)
Description copied from interface: Registry
Gets the all registry entries of type and URI.

Specified by:
getAllRegistryEntriesOfTypeAndURI in interface Registry
Parameters:
type - the resource type
uri - the resource uri
Returns:
the all registry entries of type and URI

getAllRegistryEntriesOfTypeURIAndVersion

@Transactional
public java.util.List<RegistryEntry> getAllRegistryEntriesOfTypeURIAndVersion(Registry.ResourceType type,
                                                                                            java.lang.String uri,
                                                                                            java.lang.String version)
Description copied from interface: Registry
Gets the all registry entries of type, URI and version.

Specified by:
getAllRegistryEntriesOfTypeURIAndVersion in interface Registry
Parameters:
type - the resource type
uri - the resource uri
version - the verion
Returns:
the all registry entries of type and URI

getEntriesForUri

@Transactional
public java.util.List<RegistryEntry> getEntriesForUri(java.lang.String uri)
                                               throws LBParameterException
Description copied from interface: Registry
Gets the entries for uri.

Specified by:
getEntriesForUri in interface Registry
Parameters:
uri - the uri
Returns:
the entries for uri
Throws:
LBParameterException - the LB parameter exception

getLastUpdateTime

@Transactional
public java.util.Date getLastUpdateTime()
Description copied from interface: Registry
Gets the last update time.

Specified by:
getLastUpdateTime in interface Registry
Returns:
the last update time

getNextDBIdentifier

@Transactional
public java.lang.String getNextDBIdentifier()
                                     throws LBInvocationException
Description copied from interface: Registry
Gets the next db identifier.

Specified by:
getNextDBIdentifier in interface Registry
Returns:
the next db identifier
Throws:
LBInvocationException - the LB invocation exception

getNextHistoryIdentifier

public java.lang.String getNextHistoryIdentifier()
                                          throws LBInvocationException
Description copied from interface: Registry
Gets the next history identifier.

Specified by:
getNextHistoryIdentifier in interface Registry
Returns:
the next history identifier
Throws:
LBInvocationException - the LB invocation exception

containsCodingSchemeEntry

@Transactional
public boolean containsCodingSchemeEntry(AbsoluteCodingSchemeVersionReference codingScheme)
Description copied from interface: Registry
Contains coding scheme entry.

Specified by:
containsCodingSchemeEntry in interface Registry
Parameters:
codingScheme - the coding scheme
Returns:
true, if successful

updateEntry

@Transactional
public void updateEntry(RegistryEntry entry)
Description copied from interface: Registry
Update entry.

Specified by:
updateEntry in interface Registry
Parameters:
entry - the entry

getCodingSchemeEntry

@Transactional
public RegistryEntry getCodingSchemeEntry(AbsoluteCodingSchemeVersionReference codingScheme)
                                   throws LBParameterException
Description copied from interface: Registry
Gets the coding scheme entry.

Specified by:
getCodingSchemeEntry in interface Registry
Parameters:
codingScheme - the coding scheme
Returns:
the coding scheme entry
Throws:
LBParameterException - the LB parameter exception

getNonCodingSchemeEntry

public RegistryEntry getNonCodingSchemeEntry(java.lang.String uri)
                                      throws LBParameterException
Description copied from interface: Registry
Gets the non coding scheme entry.

Specified by:
getNonCodingSchemeEntry in interface Registry
Parameters:
uri - the uri
Returns:
the non coding scheme entry
Throws:
LBParameterException - the LB parameter exception

removeEntry

@Transactional
public void removeEntry(RegistryEntry entry)
                 throws LBParameterException
Description copied from interface: Registry
Removes the entry.

Specified by:
removeEntry in interface Registry
Parameters:
entry - the entry
Throws:
LBParameterException - the LB parameter exception

containsNonCodingSchemeEntry

@Transactional
public boolean containsNonCodingSchemeEntry(java.lang.String uri)
Description copied from interface: Registry
Contains non coding scheme entry.

Specified by:
containsNonCodingSchemeEntry in interface Registry
Parameters:
uri - the uri
Returns:
true, if successful

getNonCodingSchemeResourceTypes

protected Registry.ResourceType[] getNonCodingSchemeResourceTypes()

setRegistryDao

public void setRegistryDao(RegistryDao registryDao)
Sets the registry dao.

Parameters:
registryDao - the new registry dao

getRegistryDao

public RegistryDao getRegistryDao()
Gets the registry dao.

Returns:
the registry dao

getNextDatabasePrefixGenerator

public NextDatabasePrefixGenerator getNextDatabasePrefixGenerator()
Gets the next database prefix generator.

Returns:
the next database prefix generator

setNextDatabasePrefixGenerator

public void setNextDatabasePrefixGenerator(NextDatabasePrefixGenerator nextDatabasePrefixGenerator)
Sets the next database prefix generator.

Parameters:
nextDatabasePrefixGenerator - the new next database prefix generator

Copyright: (c) 2004-2006 Mayo Foundation for Medical Education and Research (MFMER). All rights reserved. MAYO, MAYO CLINIC, and the triple-shield Mayo logo are trademarks and service marks of MFMER.