Package io.higson.runtime.sync
Class FunctionRuntimeWatcher
java.lang.Object
io.higson.runtime.sync.BaseWatcher
io.higson.runtime.sync.RuntimeWatcher
io.higson.runtime.sync.FunctionRuntimeWatcher
- All Implemented Interfaces:
Runnable
- Author:
- przemek hertel
-
Constructor Summary
ConstructorsConstructorDescriptionFunctionRuntimeWatcher(MpFunctionProvider provider, FunctionCache cache, GroovyFunctionInvoker groovyFunctionInvoker) -
Method Summary
Modifier and TypeMethodDescriptionget all cached elementsgets all synchronized components from specific tablereturns type that watcher is monitoringgets largest last update sync datevoidinvalidate(int id) removes element in cachevoidinvalidateOrReload(int id) the implementation makes the decision whether the supplied element (id) should be: - only invalidated - invalidated and eagery reloaded - reloaded and hot-swappedMethods inherited from class io.higson.runtime.sync.RuntimeWatcher
checkPossibleModification, doWatch, setEventListenerMethods inherited from class io.higson.runtime.sync.BaseWatcher
getConfig, isRunning, run, setConfig, start, stop
-
Constructor Details
-
FunctionRuntimeWatcher
public FunctionRuntimeWatcher(MpFunctionProvider provider, FunctionCache cache, GroovyFunctionInvoker groovyFunctionInvoker)
-
-
Method Details
-
getAllCached
Description copied from class:RuntimeWatcherget all cached elements- Specified by:
getAllCachedin classRuntimeWatcher- Returns:
- all cached objects
-
invalidate
public void invalidate(int id) Description copied from class:RuntimeWatcherremoves element in cache- Specified by:
invalidatein classRuntimeWatcher- Parameters:
id- of element to remove
-
invalidateOrReload
public void invalidateOrReload(int id) Description copied from class:RuntimeWatcherthe implementation makes the decision whether the supplied element (id) should be: - only invalidated - invalidated and eagery reloaded - reloaded and hot-swapped- Specified by:
invalidateOrReloadin classRuntimeWatcher
-
getLastUpdate
Description copied from class:RuntimeWatchergets largest last update sync date- Specified by:
getLastUpdatein classRuntimeWatcher- Returns:
- largest lastUpdate Date
-
getAllLastUpdates
Description copied from class:RuntimeWatchergets all synchronized components from specific table- Specified by:
getAllLastUpdatesin classRuntimeWatcher- Returns:
- list of
Trackablecomponents - See Also:
-
getElementType
Description copied from class:RuntimeWatcherreturns type that watcher is monitoring- Specified by:
getElementTypein classRuntimeWatcher- Returns:
- ElementType object
- See Also:
-