001package var.web.ws.datasensor; 002 003import java.util.Date; 004 005public class Messung { 006 public enum Unit { 007 degreeCentigrade, degreeFahrenheit, candela; 008 } 009 010 static public class Place { 011 private double lat; // latitude 012 private double lon; // longitude 013 014 public Place() { 015 super(); 016 } 017 018 public Place(double lat, double lon) { 019 this(); 020 this.lat = lat; 021 this.lon = lon; 022 } 023 024 public double getLat() { 025 return lat; 026 } 027 public void setLat(double lat) { 028 this.lat = lat; 029 } 030 public double getLon() { 031 return lon; 032 } 033 public void setLon(double lon) { 034 this.lon = lon; 035 } 036 } 037 038 private Unit unit; 039 private double observation; 040 private Place where; // where observed 041 private String sensor; // description 042 private Date when; // when observed 043 044 public Messung() { 045 super(); 046 } 047 048 public Unit getUnit() { 049 return unit; 050 } 051 052 public void setUnit(Unit unit) { 053 this.unit = unit; 054 } 055 056 public double getObservation() { 057 return observation; 058 } 059 060 public void setObservation(double observation) { 061 this.observation = observation; 062 } 063 064 public Place getWhere() { 065 return where; 066 } 067 068 public void setWhere(Place where) { 069 this.where = where; 070 } 071 072 public String getSensor() { 073 return sensor; 074 } 075 076 public void setSensor(String sensor) { 077 this.sensor = sensor; 078 } 079 080 public Date getWhen() { 081 return when; 082 } 083 084 public void setWhen(Date when) { 085 this.when = when; 086 } 087}