Skip to content

Commit d4673d2

Browse files
committed
add several models
1 parent b2e3b82 commit d4673d2

File tree

6 files changed

+34
-35
lines changed

6 files changed

+34
-35
lines changed

src/main/java/com/amadeus/resources/ItineraryPriceMetric.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
*/
1010
@ToString
1111
public class ItineraryPriceMetric extends Resource {
12-
protected ItineraryPriceMetric() {}
13-
1412
private @Getter String type;
1513
private @Getter Location origin;
1614
private @Getter Location destination;
@@ -20,19 +18,21 @@ protected ItineraryPriceMetric() {}
2018
private @Getter Boolean oneWay;
2119
private @Getter PriceMetrics[] priceMetrics;
2220

21+
protected ItineraryPriceMetric() {}
22+
2323
@ToString
2424
public class Location {
25-
protected Location() {}
26-
2725
private @Getter String iataCode;
26+
27+
protected Location() {}
2828
}
2929

3030
@ToString
3131
public class PriceMetrics {
32-
protected PriceMetrics() {}
33-
3432
private @Getter String amount;
3533
private @Getter String quartileRanking;
34+
35+
protected PriceMetrics() {}
3636
}
3737

3838
}

src/main/java/com/amadeus/resources/Location.java

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
*/
1010
@ToString
1111
public class Location extends Resource {
12-
protected Location() {}
13-
1412
private @Getter String type;
1513
private @Getter String subType;
1614
private @Getter String name;
@@ -23,16 +21,18 @@ protected Location() {}
2321
private @Getter Analytics analytics;
2422
private @Getter Double relevance;
2523

24+
protected Location() {}
25+
2626
/**
2727
* An Location-related object as returned by the Location API.
2828
* @see com.amadeus.referenceData.Location#get()
2929
*/
3030
@ToString
3131
public class GeoCode {
32-
protected GeoCode() {}
33-
3432
private @Getter double latitude;
3533
private @Getter double longitude;
34+
35+
protected GeoCode() {}
3636
}
3737

3838
/**
@@ -41,13 +41,13 @@ protected GeoCode() {}
4141
*/
4242
@ToString
4343
public class Address {
44-
protected Address() {}
45-
4644
private @Getter String cityName;
4745
private @Getter String cityCode;
4846
private @Getter String countryName;
4947
private @Getter String countryCode;
5048
private @Getter String regionCode;
49+
50+
protected Address() {}
5151
}
5252

5353
/**
@@ -56,10 +56,10 @@ protected Address() {}
5656
*/
5757
@ToString
5858
public class Distance {
59-
protected Distance() {}
60-
6159
private @Getter Double value;
6260
private @Getter String unit;
61+
62+
protected Distance() {}
6363
}
6464

6565
/**
@@ -68,20 +68,20 @@ protected Distance() {}
6868
*/
6969
@ToString
7070
public class Analytics {
71-
protected Analytics() {}
72-
7371
private @Getter Flights flights;
7472
private @Getter Travelers travelers;
7573

74+
protected Analytics() {}
75+
7676
/**
7777
* An Location-related object as returned by the Location API.
7878
* @see com.amadeus.referenceData.Location#get()
7979
*/
8080
@ToString
8181
public class Flights {
82-
protected Flights() {}
83-
8482
private @Getter Double score;
83+
84+
protected Flights() {}
8585
}
8686

8787
/**
@@ -90,9 +90,9 @@ protected Flights() {}
9090
*/
9191
@ToString
9292
public class Travelers {
93-
protected Travelers() {}
94-
9593
private @Getter Double score;
94+
95+
protected Travelers() {}
9696
}
9797
}
9898
}

src/main/java/com/amadeus/resources/Period.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,31 +9,31 @@
99
*/
1010
@ToString
1111
public class Period extends Resource {
12-
protected Period() {}
13-
1412
private @Getter String type;
1513
private @Getter String period;
1614
private @Getter Analytics analytics;
1715

16+
protected Period() {}
17+
1818
/**
1919
* An Period-related object as returned by the Busiest Period API.
2020
* @see Traveled#get()
2121
*/
2222
@ToString
2323
public class Analytics {
24-
protected Analytics() {}
25-
2624
private @Getter Travelers travelers;
2725

26+
protected Analytics() {}
27+
2828
/**
2929
* An Period-related object as returned by the BusiestPeriod API.
3030
* @see Traveled#get()
3131
*/
3232
@ToString
3333
public class Travelers {
34-
protected Travelers() {}
35-
3634
private @Getter Double score;
35+
36+
protected Travelers() {}
3737
}
3838
}
3939
}

src/main/java/com/amadeus/resources/PointOfInterest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,25 +9,25 @@
99
*/
1010
@ToString
1111
public class PointOfInterest extends Resource {
12-
protected PointOfInterest() {}
13-
1412
private @Getter String type;
1513
private @Getter String subType;
1614
private @Getter String name;
1715
private @Getter GeoCode geoCode;
1816
private @Getter String category;
1917
private @Getter String[] tags;
2018

19+
protected PointOfInterest() {}
20+
2121
/**
2222
* An PointOfInterest-related object as returned by the PointOfInterest API.
2323
* @see com.amadeus.referenceData.locations.PointOfInterest#get()
2424
*/
2525
@ToString
2626
public class GeoCode {
27-
protected GeoCode() {}
28-
2927
private @Getter double latitude;
3028
private @Getter double longitude;
29+
30+
protected GeoCode() {}
3131
}
3232

3333
}

src/main/java/com/amadeus/resources/Prediction.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,11 @@
1010
*/
1111
@ToString
1212
public class Prediction extends Resource {
13-
protected Prediction() {
14-
}
15-
1613
private @Getter String type;
1714
private @Getter String subType;
1815
private @Getter String id;
1916
private @Getter String result;
2017
private @Getter String probability;
18+
19+
protected Prediction() {}
2120
}

src/main/java/com/amadeus/resources/Resource.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
* A generic resource as returned by all namespaced APIs.
1010
*/
1111
public class Resource {
12-
protected Resource() {}
13-
1412
/**
1513
* The original response that this object is populated from.
1614
*/
@@ -21,6 +19,8 @@ protected Resource() {}
2119
*/
2220
private transient @Getter Class deSerializationClass;
2321

22+
protected Resource() {}
23+
2424
/**
2525
* Turns a response into a Gson deserialized array of resources,
2626
* attaching the response to each resource.

0 commit comments

Comments
 (0)