|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||

java.lang.Objectcz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConObjectUpdate
public class DefConObjectUpdate
Generic updater for arbitrary objects. All that you need is to annotate some fields with
Updatable annotation.
Follows the philosophy of IWorldObjectUpdateEvent.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface cz.cuni.amis.pogamut.base.communication.translator.event.IWorldObjectUpdatedEvent |
|---|
IWorldObjectUpdatedEvent.DestroyWorldObject |
| Constructor Summary | |
|---|---|
DefConObjectUpdate(DefConObject source)
Creates new object update with 'source' as object that contains updates. |
|
| Method Summary | |
|---|---|
WorldObjectId |
getId()
Returns ID of the object that should be updated. |
double |
getLastSeenTime()
Returns the time of the last update of the object. |
long |
getSimTime()
DOCUMENT ME! |
DefConObject |
getSource()
Returns source of the updates. |
static cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConObjectUpdate.Updater |
getUpdater(Class<?> cls)
Returns updater for class 'cls' from cache or creates new one. |
protected void |
setLastSeenTime(double time)
Sets the last-seen-time of the object. |
IWorldObjectUpdateResult |
update(IWorldObject obj)
Updates object 'obj' with the source event. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefConObjectUpdate(DefConObject source)
source - | Method Detail |
|---|
public static cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConObjectUpdate.Updater getUpdater(Class<?> cls)
cls -
public DefConObject getSource()
public WorldObjectId getId()
getId in interface IWorldObjectUpdatedEventpublic IWorldObjectUpdateResult update(IWorldObject obj)
update in interface IWorldObjectUpdatedEventobj - object that should be updated
public double getLastSeenTime()
protected void setLastSeenTime(double time)
time - public long getSimTime()
getSimTime in interface IWorldChangeEvent
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||