@@ -50,61 +50,97 @@ public Payment(Unzer unzer) {
5050 super (unzer );
5151 }
5252
53+ /**
54+ * @deprecated use {@link Unzer#charge(Charge)} instead
55+ */
5356 @ Deprecated
5457 public Charge charge () throws HttpCommunicationException {
5558 return getUnzer ().chargeAuthorization (getId ());
5659 }
5760
61+ /**
62+ * @deprecated use {@link Unzer#charge(Charge)} instead
63+ */
5864 @ Deprecated
5965 public Charge charge (BigDecimal amount ) throws HttpCommunicationException {
6066 return getUnzer ().chargeAuthorization (getId (), amount );
6167 }
6268
69+ /**
70+ * @deprecated use {@link Unzer#charge(Charge)} instead
71+ */
6372 @ Deprecated
6473 public Charge charge (BigDecimal amount , Currency currency , String typeId ) throws HttpCommunicationException {
6574 return getUnzer ().charge (amount , currency , typeId );
6675 }
6776
77+ /**
78+ * @deprecated use {@link Unzer#charge(Charge)} instead
79+ */
6880 @ Deprecated
6981 public Charge charge (BigDecimal amount , Currency currency , String typeId , String customerId ) throws HttpCommunicationException {
7082 return getUnzer ().charge (amount , currency , typeId , customerId );
7183 }
7284
85+ /**
86+ * @deprecated use {@link Unzer#charge(Charge)} instead
87+ */
7388 @ Deprecated
7489 public Charge charge (BigDecimal amount , Currency currency , PaymentType paymentType ) throws HttpCommunicationException {
7590 return getUnzer ().charge (amount , currency , paymentType );
7691 }
7792
93+ /**
94+ * @deprecated use {@link Unzer#charge(Charge)} instead
95+ */
7896 @ Deprecated
7997 public Charge charge (BigDecimal amount , Currency currency , String typeId , URL returnUrl ) throws HttpCommunicationException {
8098 return getUnzer ().charge (amount , currency , typeId , returnUrl );
8199 }
82100
101+ /**
102+ * @deprecated use {@link Unzer#charge(Charge)} instead
103+ */
83104 @ Deprecated
84105 public Charge charge (BigDecimal amount , Currency currency , String typeId , URL returnUrl , String customerId ) throws HttpCommunicationException {
85106 return getUnzer ().charge (amount , currency , typeId , returnUrl , customerId );
86107 }
87108
109+ /**
110+ * @deprecated use {@link Unzer#charge(Charge)} instead
111+ */
88112 @ Deprecated
89113 public Charge charge (BigDecimal amount , Currency currency , PaymentType paymentType , URL returnUrl , Customer customer ) throws HttpCommunicationException {
90114 return getUnzer ().charge (amount , currency , paymentType , returnUrl , customer );
91115 }
92116
117+ /**
118+ * @deprecated use {@link Unzer#authorize(Authorization)} instead
119+ */
93120 @ Deprecated
94121 public Authorization authorize (BigDecimal amount , Currency currency , String typeId , URL returnUrl ) throws HttpCommunicationException {
95122 return getUnzer ().authorize (amount , currency , typeId , returnUrl );
96123 }
97124
125+ /**
126+ * @deprecated use {@link Unzer#authorize(Authorization)} instead
127+ */
98128 @ Deprecated
99129 public Authorization authorize (BigDecimal amount , Currency currency , String typeId , URL returnUrl , String customerId ) throws HttpCommunicationException {
100130 return getUnzer ().authorize (amount , currency , typeId , returnUrl , customerId );
101131 }
102132
133+ /**
134+ * @deprecated use {@link Unzer#authorize(Authorization)} instead
135+ */
103136 @ Deprecated
104137 public Authorization authorize (BigDecimal amount , Currency currency , PaymentType paymentType , URL returnUrl , Customer customer ) throws HttpCommunicationException {
105138 return getUnzer ().authorize (amount , currency , paymentType , returnUrl , customer );
106139 }
107140
141+ /**
142+ * @deprecated use {@link Unzer#cancelAuthorization(String, Cancel)} or {@link Unzer#cancelCharge(String, String)} instead
143+ */
108144 @ Deprecated
109145 public Cancel cancel () throws HttpCommunicationException {
110146 if (getAuthorization () == null ) {
@@ -116,6 +152,9 @@ public Cancel cancel() throws HttpCommunicationException {
116152 return getAuthorization ().cancel ();
117153 }
118154
155+ /**
156+ * @deprecated use {@link Unzer#cancelAuthorization(String, Cancel)} or {@link Unzer#cancelCharge(String, String)} instead
157+ */
119158 @ Deprecated
120159 public Cancel cancel (BigDecimal amount ) throws HttpCommunicationException {
121160 if (getAuthorization () == null ) {
0 commit comments