Skip to content

Commit be86415

Browse files
authored
Merge pull request #183 from XeroAPI/sid-development
bump version of OAS to 2.0.0
2 parents 03bf73c + 26a08d3 commit be86415

47 files changed

Lines changed: 478 additions & 187 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<artifactId>xero-java</artifactId>
66
<packaging>jar</packaging>
77
<name>xero-java</name>
8-
<version>3.2.3</version>
8+
<version>3.3.0</version>
99
<url>https://github.com/XeroAPI/Xero-Java</url>
1010
<description>This is the official Java SDK for Xero API</description>
1111
<licenses>

src/main/java/com/xero/api/client/AccountingApi.java

Lines changed: 292 additions & 61 deletions
Large diffs are not rendered by default.

src/main/java/com/xero/api/client/AssetApi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ public class AssetApi {
4444
private ApiClient apiClient;
4545
private static AssetApi instance = null;
4646
private String userAgent = "Default";
47-
private String version = "3.2.3";
47+
private String version = "3.3.0";
4848

4949
public AssetApi() {
5050
this(new ApiClient());

src/main/java/com/xero/api/client/BankFeedsApi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public class BankFeedsApi {
4545
private ApiClient apiClient;
4646
private static BankFeedsApi instance = null;
4747
private String userAgent = "Default";
48-
private String version = "3.2.3";
48+
private String version = "3.3.0";
4949

5050
public BankFeedsApi() {
5151
this(new ApiClient());

src/main/java/com/xero/api/client/IdentityApi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public class IdentityApi {
4141
private ApiClient apiClient;
4242
private static IdentityApi instance = null;
4343
private String userAgent = "Default";
44-
private String version = "3.2.3";
44+
private String version = "3.3.0";
4545

4646
public IdentityApi() {
4747
this(new ApiClient());

src/main/java/com/xero/models/accounting/BatchPayment.java

Lines changed: 37 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,10 +119,45 @@ public static TypeEnum fromValue(String value) {
119119

120120
@JsonProperty("Type")
121121
private TypeEnum type;
122+
/**
123+
* AUTHORISED or DELETED (read-only). New batch payments will have a status of AUTHORISED. It is not possible to delete batch payments via the API.
124+
*/
125+
public enum StatusEnum {
126+
AUTHORISED("AUTHORISED"),
127+
128+
DELETED("DELETED");
129+
130+
private String value;
131+
132+
StatusEnum(String value) {
133+
this.value = value;
134+
}
135+
136+
@JsonValue
137+
public String getValue() {
138+
return value;
139+
}
140+
141+
@Override
142+
public String toString() {
143+
return String.valueOf(value);
144+
}
145+
146+
@JsonCreator
147+
public static StatusEnum fromValue(String value) {
148+
for (StatusEnum b : StatusEnum.values()) {
149+
if (b.value.equals(value)) {
150+
return b;
151+
}
152+
}
153+
throw new IllegalArgumentException("Unexpected value '" + value + "'");
154+
}
155+
}
156+
122157

123158

124159
@JsonProperty("Status")
125-
private String status;
160+
private StatusEnum status;
126161

127162

128163
@JsonProperty("TotalAmount")
@@ -346,7 +381,7 @@ public TypeEnum getType() {
346381
* @return status
347382
**/
348383
@ApiModelProperty(value = "AUTHORISED or DELETED (read-only). New batch payments will have a status of AUTHORISED. It is not possible to delete batch payments via the API.")
349-
public String getStatus() {
384+
public StatusEnum getStatus() {
350385
return status;
351386
}
352387

src/main/java/com/xero/models/accounting/Item.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public class Item {
8282

8383

8484
@JsonProperty("QuantityOnHand")
85-
private Double quantityOnHand;
85+
private Float quantityOnHand;
8686

8787
@JsonDeserialize(using = com.xero.api.CustomOffsetDateTimeDeserializer.class)
8888
@JsonProperty("UpdatedDateUTC")
@@ -297,7 +297,7 @@ public void setTotalCostPool(Double totalCostPool) {
297297
this.totalCostPool = totalCostPool;
298298
}
299299

300-
public Item quantityOnHand(Double quantityOnHand) {
300+
public Item quantityOnHand(Float quantityOnHand) {
301301
this.quantityOnHand = quantityOnHand;
302302
return this;
303303
}
@@ -307,11 +307,11 @@ public Item quantityOnHand(Double quantityOnHand) {
307307
* @return quantityOnHand
308308
**/
309309
@ApiModelProperty(value = "The quantity of the item on hand")
310-
public Double getQuantityOnHand() {
310+
public Float getQuantityOnHand() {
311311
return quantityOnHand;
312312
}
313313

314-
public void setQuantityOnHand(Double quantityOnHand) {
314+
public void setQuantityOnHand(Float quantityOnHand) {
315315
this.quantityOnHand = quantityOnHand;
316316
}
317317

src/main/java/com/xero/models/accounting/LineItem.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ public class LineItem {
4444

4545

4646
@JsonProperty("Quantity")
47-
private Double quantity;
47+
private Float quantity;
4848

4949

5050
@JsonProperty("UnitAmount")
51-
private Double unitAmount;
51+
private Float unitAmount;
5252

5353

5454
@JsonProperty("ItemCode")
@@ -121,7 +121,7 @@ public void setDescription(String description) {
121121
this.description = description;
122122
}
123123

124-
public LineItem quantity(Double quantity) {
124+
public LineItem quantity(Float quantity) {
125125
this.quantity = quantity;
126126
return this;
127127
}
@@ -131,15 +131,15 @@ public LineItem quantity(Double quantity) {
131131
* @return quantity
132132
**/
133133
@ApiModelProperty(value = "LineItem Quantity")
134-
public Double getQuantity() {
134+
public Float getQuantity() {
135135
return quantity;
136136
}
137137

138-
public void setQuantity(Double quantity) {
138+
public void setQuantity(Float quantity) {
139139
this.quantity = quantity;
140140
}
141141

142-
public LineItem unitAmount(Double unitAmount) {
142+
public LineItem unitAmount(Float unitAmount) {
143143
this.unitAmount = unitAmount;
144144
return this;
145145
}
@@ -149,11 +149,11 @@ public LineItem unitAmount(Double unitAmount) {
149149
* @return unitAmount
150150
**/
151151
@ApiModelProperty(value = "LineItem Unit Amount")
152-
public Double getUnitAmount() {
152+
public Float getUnitAmount() {
153153
return unitAmount;
154154
}
155155

156-
public void setUnitAmount(Double unitAmount) {
156+
public void setUnitAmount(Float unitAmount) {
157157
this.unitAmount = unitAmount;
158158
}
159159

src/main/java/com/xero/models/accounting/ManualJournal.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,9 @@ public enum StatusEnum {
6464

6565
DELETED("DELETED"),
6666

67-
VOIDED("VOIDED");
67+
VOIDED("VOIDED"),
68+
69+
ARCHIVED("ARCHIVED");
6870

6971
private String value;
7072

src/main/java/com/xero/models/accounting/Organisation.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,9 @@ public enum SalesTaxPeriodEnum {
288288

289289
QUARTERLY("QUARTERLY"),
290290

291-
YEARLY("YEARLY");
291+
YEARLY("YEARLY"),
292+
293+
NONE("NONE");
292294

293295
private String value;
294296

0 commit comments

Comments
 (0)