public interface ORecordHook
ORecordHookAbstract
Modifier and Type | Interface and Description |
---|---|
static class |
ORecordHook.DISTRIBUTED_EXECUTION_MODE |
static class |
ORecordHook.HOOK_POSITION |
static class |
ORecordHook.RESULT |
static class |
ORecordHook.SCOPE
Defines available scopes for scoped hooks.
|
static class |
ORecordHook.TYPE |
Modifier and Type | Method and Description |
---|---|
ORecordHook.DISTRIBUTED_EXECUTION_MODE |
getDistributedExecutionMode() |
default ORecordHook.SCOPE[] |
getScopes()
Returns the array of scopes this hook interested in.
|
ORecordHook.RESULT |
onTrigger(ORecordHook.TYPE iType,
ORecord iRecord) |
void |
onUnregister() |
void onUnregister()
ORecordHook.RESULT onTrigger(ORecordHook.TYPE iType, ORecord iRecord)
ORecordHook.DISTRIBUTED_EXECUTION_MODE getDistributedExecutionMode()
default ORecordHook.SCOPE[] getScopes()
Returns the array of scopes this hook interested in. By default, all available scopes are returned, implement/override this method to limit the scopes this hook may participate to lower the number of useless invocations of this hook.
Limiting the hook to proper scopes may give huge performance boost, especially if the hook's onTrigger(TYPE,
ORecord)
dispatcher implementation is heavy. In extreme cases, you may override the onTrigger(TYPE, ORecord)
to act
directly on event's ORecordHook.TYPE
and exit early, scopes are just a more handy alternative to this.
ORecordHook.SCOPE
Copyright © 2009–2019 OrientDB. All rights reserved.