001/** 002 * Copyright 2018 Tampere University of Technology, Pori Department 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package service.tut.pori.apilta.shock.datatypes; 017 018import java.util.Date; 019 020import javax.xml.bind.annotation.XmlAccessType; 021import javax.xml.bind.annotation.XmlAccessorType; 022import javax.xml.bind.annotation.XmlElement; 023import javax.xml.bind.annotation.XmlRootElement; 024import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; 025 026import core.tut.pori.utils.ISODateAdapter; 027 028/** 029 * Single shock highlight 030 * 031 */ 032@XmlRootElement(name=Definitions.ELEMENT_SHOCK_HIGHLIGHT) 033@XmlAccessorType(XmlAccessType.NONE) 034public class ShockHighlight { 035 @XmlJavaTypeAdapter(ISODateAdapter.class) 036 @XmlElement(name=Definitions.ELEMENT_FROM_TIMESTAMP) 037 private Date _from = null; 038 @XmlElement(name=Definitions.ELEMENT_LATITUDE) 039 private Double _latitude = null; 040 @XmlElement(name=Definitions.ELEMENT_LONGITUDE) 041 private Double _longitude = null; 042 @XmlElement(name=Definitions.ELEMENT_MAX_LEVEL) 043 private Integer _maxLevel = null; 044 @XmlElement(name=Definitions.ELEMENT_MAX_RANGE) 045 private Double _maxRange = null; 046 @XmlElement(name=Definitions.ELEMENT_MIN_LEVEL) 047 private Integer _minLevel = null; 048 @XmlElement(name=Definitions.ELEMENT_MEASUREMENT_COUNT) 049 private int _measurementCount = 0; 050 @XmlJavaTypeAdapter(ISODateAdapter.class) 051 @XmlElement(name=Definitions.ELEMENT_TO_TIMESTAMP) 052 private Date _to = null; 053 @XmlElement(name=Definitions.ELEMENT_USER_COUNT) 054 private int _userCount = 0; 055 056 /** 057 * @return the from 058 */ 059 public Date getFrom() { 060 return _from; 061 } 062 063 /** 064 * @param from the from to set 065 */ 066 public void setFrom(Date from) { 067 _from = from; 068 } 069 070 /** 071 * @return the maxLevel 072 */ 073 public Integer getMaxLevel() { 074 return _maxLevel; 075 } 076 077 /** 078 * @param maxLevel the maxLevel to set 079 */ 080 public void setMaxLevel(Integer maxLevel) { 081 _maxLevel = maxLevel; 082 } 083 084 /** 085 * @return the maxRange 086 */ 087 public Double getMaxRange() { 088 return _maxRange; 089 } 090 091 /** 092 * @param maxRange the maxRange to set 093 */ 094 public void setMaxRange(Double maxRange) { 095 _maxRange = maxRange; 096 } 097 098 /** 099 * @return the minLevel 100 */ 101 public Integer getMinLevel() { 102 return _minLevel; 103 } 104 105 /** 106 * @param minLevel the minLevel to set 107 */ 108 public void setMinLevel(Integer minLevel) { 109 _minLevel = minLevel; 110 } 111 112 /** 113 * @return the measurementCount 114 */ 115 public int getMeasurementCount() { 116 return _measurementCount; 117 } 118 119 /** 120 * @param measurementCount the measurementCount to set 121 */ 122 public void setMeasurementCount(int measurementCount) { 123 _measurementCount = measurementCount; 124 } 125 126 /** 127 * @return the to 128 */ 129 public Date getTo() { 130 return _to; 131 } 132 133 /** 134 * @param to the to to set 135 */ 136 public void setTo(Date to) { 137 _to = to; 138 } 139 140 /** 141 * @return the userCount 142 */ 143 public int getUserCount() { 144 return _userCount; 145 } 146 147 /** 148 * @param userCount the userCount to set 149 */ 150 public void setUserCount(int userCount) { 151 _userCount = userCount; 152 } 153 154 /** 155 * @return the latitude 156 */ 157 public Double getLatitude() { 158 return _latitude; 159 } 160 161 /** 162 * @param latitude the latitude to set 163 */ 164 public void setLatitude(Double latitude) { 165 _latitude = latitude; 166 } 167 168 /** 169 * @return the longitude 170 */ 171 public Double getLongitude() { 172 return _longitude; 173 } 174 175 /** 176 * @param longitude the longitude to set 177 */ 178 public void setLongitude(Double longitude) { 179 _longitude = longitude; 180 } 181}