====== Entity ====== public class Entity { protected ObjectId _id; protected long version; public Entity(); public ObjectId getId(); protected void setId(ObjectId id); public void setNewId(); public void setVersion(long v); public long getVersion(); } ====== Configuration ====== public class ConfigurationEntity extends Entity { private String brokerIP; private String brokerPort; private String brokerUsername; private String brokerPassword; public ConfigurationEntity(); public String getBrokerIP(); public void setBrokerIP(String brokerIP); public String getBrokerPort(); public void setBrokerPort(String brokerPort); public String getBrokerUsername(); public void setBrokerUsername(String brokerUsername); public String getBrokerPassword(); public void setBrokerPassword(String brokerPassword); } ====== Giraff ====== public class GiraffEntity extends Entity { private String name; private String note; private ObjectId docking_location; private List sensors; private ObjectId mapping; public GiraffEntity(); public GiraffEntity(String _name); public ObjectId getMapping(); public void setMapping(ObjectId mapping); public void setName(String _name); public String getName(); public void setNote(String _note); public String getNote(); public void setDockingLocation(ObjectId _location); public ObjectId getDockingLocation(); public void pushSensor(SensorEntity _sensor); public void pullSensor(SensorEntity _sensor); private void setSensors(ArrayList s); public List getSensors(); } ====== Giraff Mapping ====== public class GiraffMapping extends Entity { private String name; private ObjectId engineer_map; private ObjectId user_map; private ObjectId map_info; private ObjectId configuration; public GiraffMapping(); public String getName(); public void setName(String name); public ObjectId getEngineer_map(); public void setEngineer_map(ObjectId engineer_map); public ObjectId getUser_map(); public void setUser_map(ObjectId user_map); public ObjectId getMap_info(); public void setMap_info(ObjectId map_info); public ObjectId getConfiguration(); public void setConfiguration(ObjectId configuration); } public class GPMessageEntity extends Entity { private String subject; private String message; private ObjectId sender; private List recipients; private List cc; private List bcc; private List attachments; public GPMessageEntity(); public void setSender( ObjectId _sender ); public ObjectId getSender(); public List getRecipients(); public List getCc(); public List getBcc(); public List getAttachments(); public void setSubject(String _subject); public String getSubject(); public void setMessage(String _message); public String getMessage(); private void setRecipients(List ids); public void pushRecipient(UserEntity _user); public void pullRecipient(UserEntity _user); private void setCCs(List ids); public void pushCC(UserEntity _user); public void pullCC(UserEntity _user); private void setBCCs(List ids); public void pushBCC(UserEntity _user); public void pullBCC(UserEntity _user); private void setAttachments(List _attachments); public void pushAttachment(ObjectId attachment); public void pullAttachment(ObjectId attachment); }