1 package com.zone.weixin4j.message.event;
2
3 import com.zone.weixin4j.type.EventType;
4
5 import javax.xml.bind.annotation.XmlElement;
6 import java.io.Serializable;
7
8
9
10
11
12
13
14
15
16
17
18
19
20 public class MenuLocationEventMessage extends MenuEventMessage {
21
22 private static final long serialVersionUID = 145223888272819563L;
23
24 public MenuLocationEventMessage() {
25 super(EventType.location_select);
26 }
27
28
29
30
31 @XmlElement(name = "SendLocationInfo")
32 private LocationInfo locationInfo;
33
34 public LocationInfo getLocationInfo() {
35 return locationInfo;
36 }
37
38
39
40
41
42
43
44
45
46
47 public static class LocationInfo implements Serializable {
48
49 private static final long serialVersionUID = 4904181780216819965L;
50
51
52
53
54 @XmlElement(name = "Location_X")
55 private double x;
56
57
58
59 @XmlElement(name = "Location_Y")
60 private double y;
61
62
63
64 @XmlElement(name = "Scale")
65 private double scale;
66
67
68
69 @XmlElement(name = "Label")
70 private String label;
71
72
73
74 @XmlElement(name = "Poiname")
75 private String poiname;
76
77 public double getX() {
78 return x;
79 }
80
81 public double getY() {
82 return y;
83 }
84
85 public double getScale() {
86 return scale;
87 }
88
89 public String getLabel() {
90 return label;
91 }
92
93 public String getPoiname() {
94 return poiname;
95 }
96
97 @Override
98 public String toString() {
99 return "LocationInfo [x=" + x + ", y=" + y + ", scale=" + scale
100 + ", label=" + label + ", poiname=" + poiname + "]";
101 }
102 }
103
104 @Override
105 public String toString() {
106 return "MenuLocationEventMessage [locationInfo=" + locationInfo + ", "
107 + super.toString() + "]";
108 }
109 }