Package com.helger.phase4.model.mpc
Class MPCManager
- All Implemented Interfaces:
com.helger.commons.lang.IHasSize,com.helger.commons.log.IHasConditionalLogger,com.helger.dao.IAutoSaveAware,com.helger.dao.IDAO,com.helger.dao.wal.IMapBasedDAO<IMPC>,IMPCManager
@ThreadSafe
public class MPCManager
extends com.helger.photon.io.dao.AbstractPhotonMapBasedWALDAO<IMPC,MPC>
implements IMPCManager
Manager for
MPC objects.- Author:
- Philip Helger
-
Nested Class Summary
Nested classes/interfaces inherited from class com.helger.dao.wal.AbstractMapBasedWALDAO
com.helger.dao.wal.AbstractMapBasedWALDAO.InitSettings<IMPLTYPE extends Object>Nested classes/interfaces inherited from interface com.helger.dao.IDAO
com.helger.dao.IDAO.EMode -
Field Summary
Fields inherited from class com.helger.dao.wal.AbstractMapBasedWALDAO
ELEMENT_ITEM, ELEMENT_ROOTFields inherited from class com.helger.dao.wal.AbstractWALDAO
DEFAULT_WAITING_TIME, WAL_XWS, WRITE_XWSFields inherited from class com.helger.dao.AbstractDAO
CONDLOG, DEFAULT_AUTO_SAVE_ENABLED, FILENAME_EXTENSION_NEW, FILENAME_EXTENSION_PREV, m_aRWLock, RW_LOCK -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCreate a new MPC.com.helger.commons.state.EChangeDelete the MPC with the provided ID.getMPCOfID(String sID) Get the MPC with the specified ID.com.helger.commons.state.EChangemarkMPCDeleted(String sMPCID) Mark the MPC with the provided ID as deleted.protected com.helger.commons.state.EChangeonInit()com.helger.commons.state.EChangeUpdate an existing MPCMethods inherited from class com.helger.photon.io.dao.AbstractPhotonMapBasedWALDAO
isReloadable, reloadMethods inherited from class com.helger.dao.wal.AbstractMapBasedWALDAO
callbacks, containsAllIDs, containsAny, containsNone, containsOnly, containsWithID, createWriteData, findAll, findAllMapped, findFirst, findFirstMapped, forEach, forEach, forEachKey, forEachKey, forEachValue, forEachValue, getAll, getAll, getAllIDs, getAllMapped, getAtIndex, getCount, getNone, getOfID, internalContainsWithID, internalCreateItem, internalCreateItem, internalDeleteItem, internalDeleteItem, internalDirectGetAll, internalForEachValue, internalForEachValue, internalGetAll, internalGetAllSortedByKey, internalGetOfID, internalMarkItemDeleted, internalMarkItemDeleted, internalMarkItemUndeleted, internalMarkItemUndeleted, internalRemoveAllItemsNoCallback, internalUpdateItem, internalUpdateItem, isEmpty, isNotEmpty, markAsChanged, onRead, onRecoveryCreate, onRecoveryDelete, onRecoveryUpdate, size, toStringMethods inherited from class com.helger.dao.wal.AbstractWALDAO
convertNativeToWALString, convertWALStringToNative, getDataTypeClass, getFilenameProvider, getInitCount, getIO, getLastFilename, getLastInitDateTime, getLastReadDateTime, getLastWriteDateTime, getReadCount, getSafeFile, getWaitingTime, getWALXMLWriterSettings, getWriteCount, getXMLWriterSettings, initialRead, markAsChanged, modifyWriteData, onBetweenReadAndWAL, onFilenameChange, onRecoveryErrorConvertToNative, setWaitingTime, triggerExceptionHandlersRead, triggerExceptionHandlersWrite, writeToFileOnPendingChangesMethods inherited from class com.helger.dao.AbstractDAO
beginWithoutAutoSave, checkFileAccess, endWithoutAutoSave, exceptionHandlersRead, exceptionHandlersWrite, hasPendingChanges, internalHasPendingChanges, internalIsAutoSaveEnabled, internalSetPendingChanges, isAutoSaveEnabled, isSilentMode, setSilentModeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.helger.dao.IAutoSaveAware
performWithoutAutoSave, performWithoutAutoSave, performWithoutAutoSaveThrowing, performWithoutAutoSaveThrowingMethods inherited from interface com.helger.phase4.model.mpc.IMPCManager
containsWithID, getMPCOrDefaultOfID
-
Constructor Details
-
MPCManager
- Throws:
com.helger.dao.DAOException
-
-
Method Details
-
onInit
- Overrides:
onInitin classcom.helger.dao.wal.AbstractWALDAO<MPC>
-
createMPC
Description copied from interface:IMPCManagerCreate a new MPC.- Specified by:
createMPCin interfaceIMPCManager- Parameters:
aMPC- The MPC to be added. May not benull.
-
updateMPC
Description copied from interface:IMPCManagerUpdate an existing MPC- Specified by:
updateMPCin interfaceIMPCManager- Parameters:
aMPC- The MPC to be updated. May not benull.- Returns:
EChange.CHANGEDif something changed,EChange.UNCHANGEDotherwise.
-
markMPCDeleted
Description copied from interface:IMPCManagerMark the MPC with the provided ID as deleted.- Specified by:
markMPCDeletedin interfaceIMPCManager- Parameters:
sMPCID- The ID of the MPC to be marked as deleted. May benull.- Returns:
EChange.CHANGEDif marking as deleted succeeded,EChange.UNCHANGEDotherwise.
-
deleteMPC
Description copied from interface:IMPCManagerDelete the MPC with the provided ID.- Specified by:
deleteMPCin interfaceIMPCManager- Parameters:
sMPCID- The ID of the MPC to be deleted. May benull.- Returns:
EChange.CHANGEDif deleting succeeded,EChange.UNCHANGEDotherwise.
-
getMPCOfID
Description copied from interface:IMPCManagerGet the MPC with the specified ID.- Specified by:
getMPCOfIDin interfaceIMPCManager- Parameters:
sID- The ID to search. May benull.- Returns:
nullif no such MPC exists, the MPC otherwise.
-