|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectes.ucm.look.data.local.DBDataHandler
public class DBDataHandler
To have the persistence to a database, implements DataHandler
Constructor Summary | |
---|---|
DBDataHandler()
|
|
DBDataHandler(Context c)
|
Method Summary | |
---|---|
void |
addEntity(EntityData data)
Adds an entity to the world |
java.util.List<EntityData> |
getElementsUpdated(float x,
float y,
float z,
float radius,
java.util.Date date)
Returns all elements near the given point with the given radius that changed since last update |
void |
updatePosition(EntityData data,
float x,
float y,
float z)
Modifies the position for an entity |
void |
updateProperty(EntityData data,
java.lang.String property,
java.lang.String newValue)
Updates the value from a entity data property |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DBDataHandler()
public DBDataHandler(Context c)
Method Detail |
---|
public void addEntity(EntityData data)
DataSetter
addEntity
in interface DataSetter
public java.util.List<EntityData> getElementsUpdated(float x, float y, float z, float radius, java.util.Date date)
DataGetter
getElementsUpdated
in interface DataGetter
x
- x coordinatey
- y coordinatez
- z coordinateradius
- radius to be checked. If radius is -1, is considered as
infinitumdate
- time of the last update. If date is null, all elements will be
returned
public void updatePosition(EntityData data, float x, float y, float z)
DataSetter
updatePosition
in interface DataSetter
data
- data representing the entityx
- x coordinatey
- y coordinatez
- z coordinatepublic void updateProperty(EntityData data, java.lang.String property, java.lang.String newValue)
DataSetter
updateProperty
in interface DataSetter
data
- entity dataproperty
- the property namenewValue
- the nuew value for the property
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |