Modifier and Type | Field and Description |
---|---|
static Set<String> |
known_properties |
protected Map<IdentityIF,Map<String,EvictableIF>> |
qcmap |
Constructor and Description |
---|
RDBMSStorage()
INTERNAL: Creates a storage definition which gets its settings
from system variables.
|
RDBMSStorage(Map<String,String> properties)
INTERNAL: Creates a storage definition that reads its settings
from the specified properties.
|
RDBMSStorage(String propfile)
INTERNAL: Creates a storage definition that reads its settings
from the specified property file.
|
Modifier and Type | Method and Description |
---|---|
void |
clearCache() |
void |
clearCache(IdentityIF namespace) |
void |
close()
INTERNAL: Closes the storage definition, which allows it to free
its resources.
|
StorageAccessIF |
createAccess(boolean readonly) |
QueryIF |
createQuery(JDOQuery jdoquery,
RDBMSAccess access,
ObjectAccessIF oaccess,
AccessRegistrarIF registrar,
boolean lookup_identities) |
QueryIF |
createQuery(String name,
RDBMSAccess access,
ObjectAccessIF oaccess,
AccessRegistrarIF registrar) |
TransactionIF |
createTransaction(boolean readonly)
INTERNAL: Creates a new storage access instance.
|
IdentityIF |
generateIdentity(Class<?> type) |
int |
getActiveTransactionCount() |
ConnectionFactoryIF |
getConnectionFactory(boolean readonly) |
String |
getDatabase()
INTERNAL: Returns the database type.
|
EvictableIF |
getHelperObject(int identifier,
IdentityIF namespace)
INTERNAL: Returns the shared caches.
|
protected InputStream |
getInputStream(String property,
String filename) |
RDBMSMapping |
getMapping()
INTERNAL: Returns the optimized object relational mapping
declaration.
|
protected Connection |
getNonTransactionalReadConnection() |
String[] |
getPlatforms()
INTERNAL: Returns the database platforms.
|
Map<String,String> |
getProperties()
INTERNAL: Gets the properties held by the storage.
|
String |
getProperty(String property)
INTERNAL: Gets the value of the specified storage property.
|
String |
getProperty(String property,
String default_value) |
QueryDeclarations |
getQueryDeclarations() |
protected QueryDescriptor |
getQueryDescriptor(String name) |
String |
getQueryString(String name) |
SQLGeneratorIF |
getSQLGenerator() |
StorageCacheIF |
getStorageCache()
INTERNAL: Returns the shared storage cache, if any.
|
Set<AbstractTransaction> |
getTransactions()
INTERNAL: exposes the set of active transactions.
|
protected void |
init(Map<String,String> properties)
INTERNAL: Method shared by constructors to properly initialize members.
|
boolean |
isSharedCache()
INTERNAL: Returns true if shared cache is enabled.
|
void |
notifyCluster()
INTERNAL: Notify cluster that transaction has been committed, so
that batched cluster events can be broadcasted.
|
void |
objectMerged(IdentityIF source,
IdentityIF target,
AbstractTransaction cause)
INTERNAL: Propagates committed merges to other active transactions.
|
protected void |
touch(Connection connection) |
protected void |
transactionClosed(AbstractTransaction transaction) |
void |
writeReport(Writer out,
TopicMapReferenceIF reference,
IdentityIF namespace,
boolean dumpCaches) |
protected Map<IdentityIF,Map<String,EvictableIF>> qcmap
public RDBMSStorage() throws IOException
IOException
public RDBMSStorage(String propfile) throws IOException
IOException
public RDBMSStorage(Map<String,String> properties) throws IOException
IOException
protected InputStream getInputStream(String property, String filename) throws IOException
IOException
protected void init(Map<String,String> properties) throws IOException
IOException
public RDBMSMapping getMapping()
StorageIF
getMapping
in interface StorageIF
public QueryDeclarations getQueryDeclarations()
public IdentityIF generateIdentity(Class<?> type)
public Map<String,String> getProperties()
StorageIF
getProperties
in interface StorageIF
public String getProperty(String property)
StorageIF
getProperty
in interface StorageIF
public StorageAccessIF createAccess(boolean readonly)
public TransactionIF createTransaction(boolean readonly)
StorageIF
createTransaction
in interface StorageIF
public boolean isSharedCache()
StorageIF
isSharedCache
in interface StorageIF
public StorageCacheIF getStorageCache()
StorageIF
getStorageCache
in interface StorageIF
public String getDatabase()
public String[] getPlatforms()
public void close()
StorageIF
public void notifyCluster()
StorageIF
notifyCluster
in interface StorageIF
public EvictableIF getHelperObject(int identifier, IdentityIF namespace)
StorageIF
getHelperObject
in interface StorageIF
protected QueryDescriptor getQueryDescriptor(String name)
public QueryIF createQuery(String name, RDBMSAccess access, ObjectAccessIF oaccess, AccessRegistrarIF registrar)
public QueryIF createQuery(JDOQuery jdoquery, RDBMSAccess access, ObjectAccessIF oaccess, AccessRegistrarIF registrar, boolean lookup_identities)
public SQLGeneratorIF getSQLGenerator()
public ConnectionFactoryIF getConnectionFactory(boolean readonly)
public void clearCache()
public void clearCache(IdentityIF namespace)
public void writeReport(Writer out, TopicMapReferenceIF reference, IdentityIF namespace, boolean dumpCaches) throws IOException
IOException
public void objectMerged(IdentityIF source, IdentityIF target, AbstractTransaction cause)
source
- Identity of the merge source objecttarget
- Identity of the merge target objectcause
- The transaction that committed the mergepublic int getActiveTransactionCount()
protected void transactionClosed(AbstractTransaction transaction)
public Set<AbstractTransaction> getTransactions()
protected Connection getNonTransactionalReadConnection()
protected void touch(Connection connection)