public class HGAtomReplaceRequestEvent extends HGAtomEvent
A HGAtomReplaceRequestEvent is triggered when an attempt is made to replace
the value of an existing atom within the HyperGraph, but before the replacement process proceeds.
This event gives a chance to
an application to cancel the replacement of the atom. A listener to this event may return
the HGListener.Result.cancel code which will prevent the change from happening.
On the other hand, if an application needs to perform some action as a result to an already
completed replacement, the application should then listen to the HGAtomReplacedEvent.
A listener may also throw a HGReplaceRefusedException which will fail the current
transaction and must be caught at the application level.
| Constructor and Description |
|---|
HGAtomReplaceRequestEvent(HGHandle handle,
HGHandle type,
Object newValue)
Construct a new
HGAtomReplaceRequestEvent for the
given atom. |
| Modifier and Type | Method and Description |
|---|---|
Object |
getNewValue() |
HGHandle |
getType() |
void |
setNewValue(Object newValue) |
void |
setType(HGHandle type) |
getAtomHandle, getSource, setSourceCopyright © 2015. All rights reserved.