cz.cuni.amis.pogamut.defcon.communication.messages.infos
Class DefConUnitObject<T extends IState>

Package class diagram package DefConUnitObject
java.lang.Object
  extended by cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConObject
      extended by cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConViewableObject
          extended by cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConUnitObject<T>
Type Parameters:
T - DOCUMENT ME!
All Implemented Interfaces:
IWorldObject, ILocated, IViewable, ICompositeWorldObject
Direct Known Subclasses:
AirBase, Battleship, Bomber, Carrier, Fighter, Nuke, Radar, Silo, Sub

public class DefConUnitObject<T extends IState>
extends DefConViewableObject

DOCUMENT ME!

Version:
$Revision$
Author:
$author$

Field Summary
 
Fields inherited from class cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConViewableObject
location, teamId, visible
 
Constructor Summary
DefConUnitObject(DefConUnitObject<T> original)
          Creates a new DefConUnitObject object.
DefConUnitObject(int id, UnitType type, int teamId, DefConLocation location, boolean visible, T state, int stateCount, int target, double time)
          Construtor of DefConUnitObject.
 
Method Summary
 T getState()
          Gets current state of the object.
 int getStateCount()
          Gets number of activations of this object's state.
 String getStringizedFields()
          DOCUMENT ME!
 int getTarget()
          Gets current target of this object.
protected  void setState(T state)
          Sets current state of the object.
protected  void setStateCount(int stateCount)
          Sets number of activations of this object's state.
protected  void setTarget(int target)
          Sets current target of this object.
 
Methods inherited from class cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConViewableObject
getLocal, getLocation, getShared, getStatic, getTeamId, isVisible, setVisibility
 
Methods inherited from class cz.cuni.amis.pogamut.defcon.communication.messages.infos.DefConObject
createDestroyedEvent, createUpdateEvent, getDestroyed, getId, getLastSeenTime, getSimTime, getType, setLastSeenTime
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface cz.cuni.amis.pogamut.base.communication.worldview.object.IWorldObject
getId, getSimTime
 

Constructor Detail

DefConUnitObject

public DefConUnitObject(int id,
                        UnitType type,
                        int teamId,
                        DefConLocation location,
                        boolean visible,
                        T state,
                        int stateCount,
                        int target,
                        double time)
Construtor of DefConUnitObject.

Parameters:
id -
type - DOCUMENT ME!
teamId - DOCUMENT ME!
location - DOCUMENT ME!
visible - visibility of this object
state - observed state of UnitObject
stateCount - DOCUMENT ME!
target - DOCUMENT ME!
time -

DefConUnitObject

public DefConUnitObject(DefConUnitObject<T> original)
Creates a new DefConUnitObject object.

Parameters:
original - DOCUMENT ME!
Method Detail

getState

public T getState()
Gets current state of the object.

Returns:
state

setState

protected void setState(T state)
Sets current state of the object.

Parameters:
state -

getStateCount

public int getStateCount()
Gets number of activations of this object's state.

Returns:
activations

setStateCount

protected void setStateCount(int stateCount)
Sets number of activations of this object's state.

Parameters:
stateCount - activation

getTarget

public int getTarget()
Gets current target of this object.

Returns:

setTarget

protected void setTarget(int target)
Sets current target of this object.

Parameters:
target -

getStringizedFields

public String getStringizedFields()
DOCUMENT ME!

Overrides:
getStringizedFields in class DefConViewableObject
Returns:
DOCUMENT ME!


Copyright © 2013 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.