v3.0.0 Pre-release
Pre-release
Pre-release
This release enables the ability to change sets of Updater
and Effects
facilitated by the interface HandlerVersion
. HandlerVersion
s have a versionName
string, and also Updater
and Effect
arrays. When you instantiate an implementation of AbstractActionHandler
, you give it an array of HandlerVersion
s. By default, it will load either the one named v1
or the first one, if one by that name does not exist. To change versions, simply return a string from your Updater
's apply function. If a HandlerVersion
exists with a versionName
as the returned string, it will switch to that HandlerVersion
.
Breaking changes
- Interfaces have been updated/restructured
- There is now a parent interface
ActionListener
thatUpdater
andEffect
interfaces inherit from Updater
'srun
attribute has been renamed toapply
; new optionalrevert
attribute- New optional
onRollback
parameter onEffect
- New
HandlerVersion
interface - IndexState now requires an additional
handlerVersionName
attribute - IndexState now keeps track of
isReplay
state
- There is now a parent interface
AbstractActionHandler
- Constructor now takes an array of
HandlerVersion
s instead ofUpdater
andEffect
arrays updateIndexState
now takes ahandlerVersionName
parameterrunUpdaters
has been renamed toapplyUpdaters
- When the
apply
method onUpdater
s return a value, this signalsrunUpdaters
to update theHandlerVersion
to the returnedversionName
- To accommodate changing
HandlerVersion
s in the middle of a block,runEffects
now takes aversionedActions
argument to decide which effects to run
- Constructor now takes an array of
Bugfixes
- Example now successfully recovers from micro-forks