public class MapEntityStoreMixin extends Object implements EntityStore, EntityStoreSPI, StateStore, MapEntityStoreActivation
Implement MapEntityStore and add as mixin to the service using this mixin.
See MemoryMapEntityStoreMixin for reference.
EntityStores based on this mixin gets support for the Migration extension.
MapEntityStore implementations will get their values as JSON.
MapEntityStoreActivation.Activator| Constructor and Description | 
|---|
MapEntityStoreMixin()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
activateMapEntityStore()  | 
StateCommitter | 
applyChanges(EntityStoreUnitOfWork unitofwork,
            Iterable<EntityState> state)  | 
EntityState | 
entityStateOf(EntityStoreUnitOfWork unitofwork,
             ModuleSpi module,
             EntityReference identity)  | 
Input<EntityState,EntityStoreException> | 
entityStates(ModuleSpi module)  | 
JSONObject | 
jsonStateOf(String id)  | 
EntityState | 
newEntityState(EntityStoreUnitOfWork unitOfWork,
              ModuleSpi module,
              EntityReference identity,
              EntityDescriptor entityDescriptor)  | 
EntityStoreUnitOfWork | 
newUnitOfWork(Usecase usecaseMetaInfo,
             ModuleSpi module,
             long currentTime)  | 
protected String | 
newUnitOfWorkId()  | 
protected EntityState | 
readEntityState(ModuleSpi module,
               Reader entityState)  | 
protected void | 
writeEntityState(DefaultEntityState state,
                Writer writer,
                String version,
                long lastModified)  | 
protected String uuid
public void activateMapEntityStore()
                            throws Exception
activateMapEntityStore in interface MapEntityStoreActivationExceptionpublic EntityStoreUnitOfWork newUnitOfWork(Usecase usecaseMetaInfo, ModuleSpi module, long currentTime)
newUnitOfWork in interface EntityStorepublic EntityState newEntityState(EntityStoreUnitOfWork unitOfWork, ModuleSpi module, EntityReference identity, EntityDescriptor entityDescriptor)
newEntityState in interface EntityStoreSPIpublic EntityState entityStateOf(EntityStoreUnitOfWork unitofwork, ModuleSpi module, EntityReference identity)
entityStateOf in interface EntityStoreSPIpublic StateCommitter applyChanges(EntityStoreUnitOfWork unitofwork, Iterable<EntityState> state) throws EntityStoreException
applyChanges in interface EntityStoreSPIEntityStoreExceptionpublic Input<EntityState,EntityStoreException> entityStates(ModuleSpi module)
entityStates in interface EntityStoreprotected String newUnitOfWorkId()
protected void writeEntityState(DefaultEntityState state, Writer writer, String version, long lastModified) throws EntityStoreException
EntityStoreExceptionprotected EntityState readEntityState(ModuleSpi module, Reader entityState) throws EntityStoreException
EntityStoreExceptionpublic JSONObject jsonStateOf(String id) throws IOException
jsonStateOf in interface StateStoreIOException