public class ClientPersistenceHelper extends AbstractClientHelper implements FormTransactionBuilderI, de.ipcon.db.core.TransactionProviderI, de.ipcon.db.core.SaveBOListenerI
| Constructor and Description |
|---|
ClientPersistenceHelper(Client _client) |
| Modifier and Type | Method and Description |
|---|---|
void |
addSaveBOListener(de.ipcon.db.core.SaveBOListenerI l)
Adds the passed SaveBOListenerI to the list of listeners, wrapped in a WeakReference.
|
void |
flushCaches() |
BO |
getBO(java.lang.Long id,
java.lang.Class classTip) |
de.ipcon.db.core.CodebausteinStorageI |
getCodebausteinStorage()
Returns the lazily initialized storage provider for Codebausteine.
|
FulltextSearcherI |
getFulltextSearcher() |
Transaction |
getNewFormTransaction()
Creates an interactive form transaction initialized with the current user.
|
Transaction |
getNewFormTransaction(java.lang.String desc)
Creates an interactive form transaction initialized with the current user
and an identifying description for auditing and debugging.
|
Transaction |
getNewTransaction() |
Transaction |
getNewTransaction(BOLoaderI loader,
SchemaI txSchema,
java.lang.String desc,
TemporaryIdSupplierI tempIdSupplier)
Central internal factory method to create and fully initialize a new database transaction.
|
Transaction |
getNewTransaction(java.lang.String desc) |
Transaction |
getNewTransaction(java.lang.String desc,
TemporaryIdSupplierI tempIdSupplier) |
Transaction |
getNewTransaction(TemporaryIdSupplierI tempIdSupplier) |
Transaction |
getNewTransactionWithInstrumentedSchema() |
Transaction |
getNewTransactionWithInstrumentedSchema(java.lang.String desc) |
Transaction |
getNewTransactionWithInstrumentedSchema(java.lang.String desc,
TemporaryIdSupplierI tempIdSupplier) |
Transaction |
getNewTransactionWithInstrumentedSchema(TemporaryIdSupplierI tempIdSupplier) |
StrukturCache |
getStrukturCache() |
boolean |
isMemoryTightClient()
Checks non-blockingly whether the client's local persistence and caching layer is operating
under memory constraints.
|
boolean |
isNotificationSystemActivated() |
java.util.List |
queryBO(groovy.lang.GString gs)
Executes a database query dynamically constructed via Groovy GString interpolation.
|
java.util.List |
queryBO(java.lang.String query) |
java.util.List |
queryBO(java.lang.String query,
java.lang.Object[] params) |
void |
removeSaveBOListener(de.ipcon.db.core.SaveBOListenerI l)
Removes the passed SaveBOListenerI from the list of listeners.
|
TransactionAnswer |
saveBO(Transaction tx) |
TransactionAnswer |
saveBO(Transaction tx,
boolean ignoreConflicts)
Saves the provided transaction.
|
void |
transactionSaveSuccess(Transaction stubTx,
java.util.Map<java.lang.Long,java.lang.Long> tempIdToDbIdMap,
java.util.function.Predicate<Transaction> isSavedTransactionInstancePredicate)
Notifies all registered SaveBOListenerI-s about a successfully saved Transaction via the transactionSaveSuccess-callback.
|
clientpublic ClientPersistenceHelper(Client _client)
public TransactionAnswer saveBO(Transaction tx)
saveBO in interface de.ipcon.db.core.TransactionProviderIpublic TransactionAnswer saveBO(Transaction tx, boolean ignoreConflicts)
saveBO methods, the default
value of the ignoreConflicts argument is 1/true here that is
ignoreConflicts is activated if this parameter is missing (for
backwards compatibility).
If saving was successful, then the transaction won't be active anymore. If saving wasn't successful, then
the transaction is still active, but might've fixed any conflicts and probably succeeds if saved again.
But there are no guarentees about data integrity in the latter case, e.g. if the same attribute was changed, which is the 'real' value?saveBO in interface de.ipcon.db.core.TransactionProviderIpublic Transaction getNewFormTransaction()
FormTransactionBuilderIgetNewFormTransaction in interface FormTransactionBuilderIpublic Transaction getNewFormTransaction(java.lang.String desc)
FormTransactionBuilderIgetNewFormTransaction in interface FormTransactionBuilderIdesc - transaction description; may be nullpublic Transaction getNewTransaction()
getNewTransaction in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransaction(java.lang.String desc)
getNewTransaction in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransaction(TemporaryIdSupplierI tempIdSupplier)
getNewTransaction in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransaction(java.lang.String desc, TemporaryIdSupplierI tempIdSupplier)
getNewTransaction in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransactionWithInstrumentedSchema()
getNewTransactionWithInstrumentedSchema in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransactionWithInstrumentedSchema(java.lang.String desc)
getNewTransactionWithInstrumentedSchema in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransactionWithInstrumentedSchema(TemporaryIdSupplierI tempIdSupplier)
getNewTransactionWithInstrumentedSchema in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransactionWithInstrumentedSchema(java.lang.String desc, TemporaryIdSupplierI tempIdSupplier)
getNewTransactionWithInstrumentedSchema in interface de.ipcon.db.core.TransactionBuilderIpublic Transaction getNewTransaction(BOLoaderI loader, SchemaI txSchema, java.lang.String desc, TemporaryIdSupplierI tempIdSupplier)
loader - The BO loader to use.txSchema - The schema to use (optional).desc - A description for the transaction (optional).tempIdSupplier - A supplier for temporary IDs (optional).Transaction.java.lang.IllegalStateException - if not connected to a server.public void transactionSaveSuccess(Transaction stubTx, java.util.Map<java.lang.Long,java.lang.Long> tempIdToDbIdMap, java.util.function.Predicate<Transaction> isSavedTransactionInstancePredicate)
transactionSaveSuccess in interface de.ipcon.db.core.SaveBOListenerIpublic void addSaveBOListener(de.ipcon.db.core.SaveBOListenerI l)
public void removeSaveBOListener(de.ipcon.db.core.SaveBOListenerI l)
public java.util.List queryBO(groovy.lang.GString gs)
gs - The GString query template.public java.util.List queryBO(java.lang.String query)
public java.util.List queryBO(java.lang.String query,
java.lang.Object[] params)
public BO getBO(java.lang.Long id, java.lang.Class classTip)
public void flushCaches()
public boolean isMemoryTightClient()
true if memory is tight or restricted; false otherwisepublic boolean isNotificationSystemActivated()
public FulltextSearcherI getFulltextSearcher()
public de.ipcon.db.core.CodebausteinStorageI getCodebausteinStorage()
CodebausteinStorageI instancepublic StrukturCache getStrukturCache()
Copyright © 2000-2026 OAshi S.à r.l. All Rights Reserved.