001    /*
002     * Copyright 2008 Marc Wick, geonames.org
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     *
016     */
017    package org.geonames;
018    
019    /**
020     * a postal code
021     * 
022     * @author marc@geonames
023     * 
024     */
025    public class PostalCode {
026    
027            private String postalCode;
028    
029            private String placeName;
030    
031            private String countryCode;
032    
033            private double latitude;
034    
035            private double longitude;
036    
037            private String adminName1;
038    
039            private String adminCode1;
040    
041            private String adminName2;
042    
043            private String adminCode2;
044    
045            private double distance;
046    
047            /**
048             * @return Returns the distance.
049             */
050            public double getDistance() {
051                    return distance;
052            }
053    
054            /**
055             * @param distance
056             *            The distance to set.
057             */
058            public void setDistance(double distance) {
059                    this.distance = distance;
060            }
061    
062            /**
063             * @return Returns the adminCode1.
064             */
065            public String getAdminCode1() {
066                    return adminCode1;
067            }
068    
069            /**
070             * @param adminCode1
071             *            The adminCode1 to set.
072             */
073            public void setAdminCode1(String adminCode1) {
074                    this.adminCode1 = adminCode1;
075            }
076    
077            /**
078             * @return Returns the adminCode2.
079             */
080            public String getAdminCode2() {
081                    return adminCode2;
082            }
083    
084            /**
085             * @param adminCode2
086             *            The adminCode2 to set.
087             */
088            public void setAdminCode2(String adminCode2) {
089                    this.adminCode2 = adminCode2;
090            }
091    
092            /**
093             * @return Returns the adminName1.
094             */
095            public String getAdminName1() {
096                    return adminName1;
097            }
098    
099            /**
100             * @param adminName1
101             *            The adminName1 to set.
102             */
103            public void setAdminName1(String adminName1) {
104                    this.adminName1 = adminName1;
105            }
106    
107            /**
108             * @return Returns the adminName2.
109             */
110            public String getAdminName2() {
111                    return adminName2;
112            }
113    
114            /**
115             * @param adminName2
116             *            The adminName2 to set.
117             */
118            public void setAdminName2(String adminName2) {
119                    this.adminName2 = adminName2;
120            }
121    
122            /**
123             * @return Returns the ISO 3166-1-alpha-2 countryCode.
124             */
125            public String getCountryCode() {
126                    return countryCode;
127            }
128    
129            /**
130             * @param countryCode
131             *            The ISO 3166-1-alpha-2 countryCode to set.
132             */
133            public void setCountryCode(String countryCode) {
134                    this.countryCode = countryCode;
135            }
136    
137            /**
138             * latitude in WGS84
139             * 
140             * @return Returns the latitude.
141             */
142            public double getLatitude() {
143                    return latitude;
144            }
145    
146            /**
147             * @param latitude
148             *            The latitude to set.
149             */
150            public void setLatitude(double latitude) {
151                    this.latitude = latitude;
152            }
153    
154            /**
155             * longitude in WGS84
156             * 
157             * @return Returns the longitude.
158             */
159            public double getLongitude() {
160                    return longitude;
161            }
162    
163            /**
164             * @param longitude
165             *            The longitude to set.
166             */
167            public void setLongitude(double longitude) {
168                    this.longitude = longitude;
169            }
170    
171            /**
172             * @return Returns the placeName.
173             */
174            public String getPlaceName() {
175                    return placeName;
176            }
177    
178            /**
179             * @param placeName
180             *            The placeName to set.
181             */
182            public void setPlaceName(String placeName) {
183                    this.placeName = placeName;
184            }
185    
186            /**
187             * @return Returns the postalCode.
188             */
189            public String getPostalCode() {
190                    return postalCode;
191            }
192    
193            /**
194             * @param postalCode
195             *            The postalCode to set.
196             */
197            public void setPostalCode(String postalCode) {
198                    this.postalCode = postalCode;
199            }
200    
201    }