source: osm/applications/editors/josm/plugins/imagery_offset_db/src/iodb/ImageryOffsetBase.java@ 28008

Last change on this file since 28008 was 28008, checked in by zverik, 12 years ago

Something works :)

File size: 1.5 KB
Line 
1package iodb;
2
3import java.util.Date;
4import java.util.Map;
5import org.openstreetmap.josm.data.coor.CoordinateFormat;
6import org.openstreetmap.josm.data.coor.LatLon;
7
8/**
9 * Stores one imagery offset record.
10 *
11 * @author zverik
12 */
13public class ImageryOffsetBase {
14 private LatLon position;
15 private Date date;
16 private String author;
17 private String description;
18 private Date abandonDate;
19
20 public void setBasicInfo( LatLon position, String author, String description, Date date ) {
21 this.position = position;
22 this.author = author;
23 this.description = description;
24 this.date = date;
25 this.abandonDate = null;
26 }
27
28 public void setAbandonDate(Date abandonDate) {
29 this.abandonDate = abandonDate;
30 }
31
32 public Date getAbandonDate() {
33 return abandonDate;
34 }
35
36 public boolean isAbandoned() {
37 return abandonDate != null;
38 }
39
40 public String getAuthor() {
41 return author;
42 }
43
44 public Date getDate() {
45 return date;
46 }
47
48 public String getDescription() {
49 return description;
50 }
51
52 public LatLon getPosition() {
53 return position;
54 }
55
56 public void putServerParams( Map<String, String> map ) {
57 map.put("lat", position.latToString(CoordinateFormat.DECIMAL_DEGREES));
58 map.put("lon", position.lonToString(CoordinateFormat.DECIMAL_DEGREES));
59 map.put("author", author);
60 map.put("description", description);
61 }
62}
Note: See TracBrowser for help on using the repository browser.