Skip to content

Commit ea98464

Browse files
authored
Merge pull request #174 from mwarzybok-sumoheavy/feature/SP-26
SP-26 Add JavaDoc to Invoice model classes
2 parents 742fe5b + acb312e commit ea98464

18 files changed

+2092
-51
lines changed

src/main/java/com/bitpay/sdk/model/Invoice/Buyer.java

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
1+
/*
2+
* Copyright (c) 2019 BitPay
3+
*/
4+
15
package com.bitpay.sdk.model.Invoice;
26

37
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
48
import com.fasterxml.jackson.annotation.JsonInclude;
59
import com.fasterxml.jackson.annotation.JsonProperty;
610

11+
/**
12+
* Allows merchant to pass buyer related information in the invoice object.
13+
*
14+
* @see <a href="https://bitpay.com/api/#rest-api-resources-invoices-resource">REST API Invoices</a>
15+
*/
716
@JsonIgnoreProperties(ignoreUnknown = true)
817
public class Buyer {
918

@@ -18,114 +27,221 @@ public class Buyer {
1827
private String _phone;
1928
private boolean _notify;
2029

30+
/**
31+
* Instantiates a new Buyer.
32+
*/
2133
public Buyer() {
2234
}
2335

36+
/**
37+
* Gets Buyer's name.
38+
*
39+
* @return the name
40+
*/
2441
@JsonProperty("name")
2542
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
2643
public String getName() {
2744
return _name;
2845
}
2946

47+
/**
48+
* Sets Buyer's name.
49+
*
50+
* @param name the name
51+
*/
3052
@JsonProperty("name")
3153
public void setName(String name) {
3254
this._name = name;
3355
}
3456

57+
/**
58+
* Gets Buyer's address.
59+
*
60+
* @return the address 1
61+
*/
3562
@JsonProperty("address1")
3663
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
3764
public String getAddress1() {
3865
return _address1;
3966
}
4067

68+
/**
69+
* Sets Buyer's address.
70+
*
71+
* @param address1 the address 1
72+
*/
4173
@JsonProperty("address1")
4274
public void setAddress1(String address1) {
4375
this._address1 = address1;
4476
}
4577

78+
/**
79+
* Gets Buyer's appartment or suite number.
80+
*
81+
* @return the address 2
82+
*/
4683
@JsonProperty("address2")
4784
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
4885
public String getAddress2() {
4986
return _address2;
5087
}
5188

89+
/**
90+
* Sets Buyer's appartment or suite number.
91+
*
92+
* @param address2 the address 2
93+
*/
5294
@JsonProperty("address2")
5395
public void setAddress2(String address2) {
5496
this._address2 = address2;
5597
}
5698

99+
/**
100+
* Gets Buyer's city or locality.
101+
*
102+
* @return the locality
103+
*/
57104
@JsonProperty("locality")
58105
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
59106
public String getLocality() {
60107
return _locality;
61108
}
62109

110+
/**
111+
* Sets Buyer's city or locality.
112+
*
113+
* @param locality the locality
114+
*/
63115
@JsonProperty("locality")
64116
public void setLocality(String locality) {
65117
this._locality = locality;
66118
}
67119

120+
/**
121+
* Gets Buyer's state or province.
122+
*
123+
* @return the region
124+
*/
68125
@JsonProperty("region")
69126
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
70127
public String getRegion() {
71128
return _region;
72129
}
73130

131+
/**
132+
* Sets Buyer's state or province.
133+
*
134+
* @param region the region
135+
*/
74136
@JsonProperty("region")
75137
public void setRegion(String region) {
76138
this._region = region;
77139
}
78140

141+
/**
142+
* Gets Buyer's Zip or Postal Code.
143+
*
144+
* @return the postal code
145+
*/
79146
@JsonProperty("postalCode")
80147
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
81148
public String getPostalCode() {
82149
return _postalCode;
83150
}
84151

152+
/**
153+
* Sets Buyer's Zip or Postal Code.
154+
*
155+
* @param postalCode the postal code
156+
*/
85157
@JsonProperty("postalCode")
86158
public void setPostalCode(String postalCode) {
87159
this._postalCode = postalCode;
88160
}
89161

162+
/**
163+
* Gets Buyer's Country code. Format ISO 3166-1 alpha-2.
164+
*
165+
* @return the country
166+
*/
90167
@JsonProperty("country")
91168
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
92169
public String getCountry() {
93170
return _country;
94171
}
95172

173+
/**
174+
* Sets Buyer's Country code. Format ISO 3166-1 alpha-2.
175+
*
176+
* @param country the country
177+
*/
96178
@JsonProperty("country")
97179
public void setCountry(String country) {
98180
this._country = country;
99181
}
100182

183+
/**
184+
* Gets Buyer's email address. If provided during invoice creation,
185+
* this will bypass the email prompt for the consumer when opening the invoice..
186+
*
187+
* @return the email
188+
*/
101189
@JsonProperty("email")
102190
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
103191
public String getEmail() {
104192
return _email;
105193
}
106194

195+
/**
196+
* Sets Buyer's email address. If provided during invoice creation,
197+
* this will bypass the email prompt for the consumer when opening the invoice..
198+
*
199+
* @param email the email
200+
*/
107201
@JsonProperty("email")
108202
public void setEmail(String email) {
109203
this._email = email;
110204
}
111205

206+
/**
207+
* Gets Buyer's phone number.
208+
*
209+
* @return the phone
210+
*/
112211
@JsonProperty("phone")
113212
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
114213
public String getPhone() {
115214
return _phone;
116215
}
117216

217+
/**
218+
* Sets Buyer's phone number.
219+
*
220+
* @param phone the phone
221+
*/
118222
@JsonProperty("phone")
119223
public void setPhone(String phone) {
120224
this._phone = phone;
121225
}
122226

227+
/**
228+
* Gets notify. Indicates whether a BitPay email confirmation should be sent to the buyer once
229+
* he has paid the invoice.
230+
*
231+
* @return the notify
232+
*/
123233
@JsonProperty("notify")
124234
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
125235
public boolean getNotify() {
126236
return _notify;
127237
}
128238

239+
/**
240+
* Sets notify. Indicates whether a BitPay email confirmation should be sent to the buyer once
241+
* he has paid the invoice.
242+
*
243+
* @param notify the notify
244+
*/
129245
@JsonProperty("notify")
130246
public void setNotify(boolean notify) {
131247
this._notify = notify;

0 commit comments

Comments
 (0)