Permalink
Browse files

Adding Location mapping

  • Loading branch information...
1 parent ca091b7 commit 29e1069b7e6da079fc440fa10c00ffa7ae20d646 @Treydone committed Sep 14, 2011
@@ -0,0 +1,75 @@
+package org.springframework.social.viadeo.api;
+
+public class Location {
+
+ private String city;
+
+ private String zipcode;
+
+ private String country;
+
+ private String area;
+
+ private String timezone;
+
+ private String latitude;
+
+ private String longitude;
+
+ public String getCity() {
+ return city;
+ }
+
+ public void setCity(String city) {
+ this.city = city;
+ }
+
+ public String getZipcode() {
+ return zipcode;
+ }
+
+ public void setZipcode(String zipcode) {
+ this.zipcode = zipcode;
+ }
+
+ public String getCountry() {
+ return country;
+ }
+
+ public void setCountry(String country) {
+ this.country = country;
+ }
+
+ public String getArea() {
+ return area;
+ }
+
+ public void setArea(String area) {
+ this.area = area;
+ }
+
+ public String getTimezone() {
+ return timezone;
+ }
+
+ public void setTimezone(String timezone) {
+ this.timezone = timezone;
+ }
+
+ public String getLatitude() {
+ return latitude;
+ }
+
+ public void setLatitude(String latitude) {
+ this.latitude = latitude;
+ }
+
+ public String getLongitude() {
+ return longitude;
+ }
+
+ public void setLongitude(String longitude) {
+ this.longitude = longitude;
+ }
+
+}
@@ -0,0 +1,37 @@
+package org.springframework.social.viadeo.api.impl.json;
+
+import org.codehaus.jackson.annotate.JsonCreator;
+import org.codehaus.jackson.annotate.JsonIgnoreProperties;
+import org.codehaus.jackson.annotate.JsonProperty;
+
+/**
+ * Annotated mixin to add Jackson annotations to Location.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+abstract class LocationMixin {
+
+ @JsonCreator
+ LocationMixin() {
+ }
+
+ @JsonProperty("city")
+ String city;
+
+ @JsonProperty("zipcode")
+ String zipcode;
+
+ @JsonProperty("country")
+ String country;
+
+ @JsonProperty("area")
+ String area;
+
+ @JsonProperty("timezone")
+ String timezone;
+
+ @JsonProperty("latitude")
+ String latitude;
+
+ @JsonProperty("longitude")
+ String longitude;
+}

0 comments on commit 29e1069

Please sign in to comment.