public class StoreDataManager extends Object
Modifier and Type | Field and Description |
---|---|
protected Map<String,StoreData> |
savedStoreDataByClass
the memory image of schema data before running it
|
protected Map<String,StoreData> |
storeDataByClass
Map of all managed store data, keyed by the class/field name.
|
Constructor and Description |
---|
StoreDataManager() |
Modifier and Type | Method and Description |
---|---|
void |
begin()
Begin a transaction that changes the StoreData cache
|
void |
clear()
Clear the cache
|
void |
commit()
Commit the transaction changes to the StoreData cache
|
void |
deregisterClass(String className) |
StoreData |
get(AbstractMemberMetaData mmd)
Get the StoreData by the given field/property, if it has some specific store data component (join table).
|
StoreData |
get(String className)
Get the StoreData by the given className
|
Collection<StoreData> |
getManagedStoreData()
Accessor for the StoreData currently managed by this store.
|
StoreData[] |
getStoreDataForProperties(String key1,
Object value1,
String key2,
Object value2)
Convenience accessor for all store data where property 1 has value1 and property 2 has value2.
|
boolean |
managesClass(String className)
Accessor for whether the specified class is managed currently
|
protected void |
registerStoreData(StoreData data)
Method to register some data with the store.
|
void |
rollback()
Rollback the transaction changes to the StoreData cache
|
int |
size()
Accessor to the number of StoreData in cache
|
protected Map<String,StoreData> storeDataByClass
public void clear()
public void deregisterClass(String className)
protected void registerStoreData(StoreData data)
data
- The StoreData to addpublic StoreData[] getStoreDataForProperties(String key1, Object value1, String key2, Object value2)
key1
- Property 1 namevalue1
- Property 1 valuekey2
- Property 2 namevalue2
- Property 2 valuepublic boolean managesClass(String className)
className
- The name of the classpublic Collection<StoreData> getManagedStoreData()
public StoreData get(String className)
className
- the fully qualified class namepublic StoreData get(AbstractMemberMetaData mmd)
mmd
- metadata for the the field/propertypublic int size()
public void begin()
public void rollback()
public void commit()
Copyright © 2019. All rights reserved.