killbill 3.0.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/Jarfile +5 -5
- data/NEWS +4 -0
- data/README.md +45 -8
- data/VERSION +1 -1
- data/generators/active_merchant/active_merchant_generator.rb +38 -0
- data/generators/active_merchant/templates/.gitignore.rb +36 -0
- data/generators/active_merchant/templates/.travis.yml.rb +19 -0
- data/generators/active_merchant/templates/Gemfile.rb +3 -0
- data/generators/active_merchant/templates/Jarfile.rb +6 -0
- data/generators/active_merchant/templates/LICENSE.rb +201 -0
- data/generators/active_merchant/templates/NEWS.rb +2 -0
- data/generators/active_merchant/templates/Rakefile.rb +30 -0
- data/generators/active_merchant/templates/VERSION.rb +1 -0
- data/generators/active_merchant/templates/config.ru.rb +4 -0
- data/generators/active_merchant/templates/config.yml.rb +13 -0
- data/generators/active_merchant/templates/db/ddl.sql.rb +64 -0
- data/generators/active_merchant/templates/db/schema.rb +64 -0
- data/generators/active_merchant/templates/killbill.properties.rb +3 -0
- data/generators/active_merchant/templates/lib/api.rb +119 -0
- data/generators/active_merchant/templates/lib/application.rb +84 -0
- data/generators/active_merchant/templates/lib/models/payment_method.rb +22 -0
- data/generators/active_merchant/templates/lib/models/response.rb +22 -0
- data/generators/active_merchant/templates/lib/models/transaction.rb +11 -0
- data/generators/active_merchant/templates/lib/plugin.rb +23 -0
- data/generators/active_merchant/templates/lib/private_api.rb +6 -0
- data/generators/active_merchant/templates/lib/views/form.erb +8 -0
- data/generators/active_merchant/templates/plugin.gemspec.rb +48 -0
- data/generators/active_merchant/templates/pom.xml.rb +44 -0
- data/generators/active_merchant/templates/release.sh.rb +41 -0
- data/generators/active_merchant/templates/spec/base_plugin_spec.rb +30 -0
- data/generators/active_merchant/templates/spec/integration_spec.rb +31 -0
- data/generators/active_merchant/templates/spec/spec_helper.rb +24 -0
- data/generators/killbill_generator.rb +38 -0
- data/killbill.gemspec +10 -2
- data/lib/killbill/gen/api/block.rb +82 -0
- data/lib/killbill/gen/api/direct_payment.rb +176 -0
- data/lib/killbill/gen/api/direct_payment_api.rb +329 -0
- data/lib/killbill/gen/api/direct_payment_transaction.rb +156 -0
- data/lib/killbill/gen/api/fixed.rb +63 -0
- data/lib/killbill/gen/api/invoice_item.rb +7 -1
- data/lib/killbill/gen/api/invoice_item_formatter.rb +7 -1
- data/lib/killbill/gen/api/invoice_user_api.rb +18 -136
- data/lib/killbill/gen/api/migration_plan.rb +6 -6
- data/lib/killbill/gen/api/payment_api.rb +216 -54
- data/lib/killbill/gen/api/payment_method_plugin.rb +3 -3
- data/lib/killbill/gen/api/plan.rb +6 -6
- data/lib/killbill/gen/api/plan_phase.rb +16 -23
- data/lib/killbill/gen/api/plugin_property.rb +71 -0
- data/lib/killbill/gen/api/recurring.rb +63 -0
- data/lib/killbill/gen/api/require_gen.rb +10 -1
- data/lib/killbill/gen/api/static_catalog.rb +8 -1
- data/lib/killbill/gen/api/tier.rb +77 -0
- data/lib/killbill/gen/api/tiered_block.rb +88 -0
- data/lib/killbill/gen/api/usage.rb +111 -0
- data/lib/killbill/gen/api/usage_user_api.rb +59 -3
- data/lib/killbill/gen/plugin-api/billing_address.rb +85 -0
- data/lib/killbill/gen/plugin-api/customer.rb +73 -0
- data/lib/killbill/gen/plugin-api/hosted_payment_page_descriptor_fields.rb +145 -0
- data/lib/killbill/gen/plugin-api/hosted_payment_page_form_descriptor.rb +80 -0
- data/lib/killbill/gen/plugin-api/hosted_payment_page_notification.rb +129 -0
- data/lib/killbill/gen/plugin-api/payment_info_plugin.rb +20 -1
- data/lib/killbill/gen/plugin-api/payment_plugin_api.rb +358 -39
- data/lib/killbill/gen/plugin-api/refund_info_plugin.rb +20 -1
- data/lib/killbill/gen/plugin-api/require_gen.rb +3 -0
- data/lib/killbill/helpers/active_merchant.rb +21 -0
- data/lib/killbill/helpers/active_merchant/active_record.rb +17 -0
- data/lib/killbill/helpers/active_merchant/active_record/models/helpers.rb +25 -0
- data/lib/killbill/helpers/active_merchant/active_record/models/payment_method.rb +195 -0
- data/lib/killbill/helpers/active_merchant/active_record/models/response.rb +178 -0
- data/lib/killbill/helpers/active_merchant/active_record/models/streamy_result_set.rb +35 -0
- data/lib/killbill/helpers/active_merchant/active_record/models/transaction.rb +63 -0
- data/lib/killbill/helpers/active_merchant/configuration.rb +54 -0
- data/lib/killbill/helpers/active_merchant/core_ext.rb +41 -0
- data/lib/killbill/helpers/active_merchant/gateway.rb +35 -0
- data/lib/killbill/helpers/active_merchant/killbill_spec_helper.rb +117 -0
- data/lib/killbill/helpers/active_merchant/payment_plugin.rb +365 -0
- data/lib/killbill/helpers/active_merchant/private_payment_plugin.rb +119 -0
- data/lib/killbill/helpers/active_merchant/properties.rb +20 -0
- data/lib/killbill/helpers/active_merchant/sinatra.rb +30 -0
- data/lib/killbill/helpers/active_merchant/utils.rb +23 -0
- data/lib/killbill/payment.rb +22 -10
- data/script/generate +15 -0
- data/spec/killbill/helpers/payment_method_spec.rb +101 -0
- data/spec/killbill/helpers/response_spec.rb +74 -0
- data/spec/killbill/helpers/test_schema.rb +57 -0
- data/spec/killbill/helpers/utils_spec.rb +22 -0
- data/spec/killbill/payment_plugin_api_spec.rb +23 -18
- data/spec/killbill/payment_plugin_spec.rb +11 -10
- data/spec/killbill/payment_test.rb +9 -9
- data/spec/spec_helper.rb +8 -3
- metadata +130 -5
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
###################################################################################
|
|
2
|
+
# #
|
|
3
|
+
# Copyright 2010-2013 Ning, Inc. #
|
|
4
|
+
# #
|
|
5
|
+
# Ning licenses this file to you under the Apache License, version 2.0 #
|
|
6
|
+
# (the "License"); you may not use this file except in compliance with the #
|
|
7
|
+
# License. You may obtain a copy of the License at: #
|
|
8
|
+
# #
|
|
9
|
+
# http://www.apache.org/licenses/LICENSE-2.0 #
|
|
10
|
+
# #
|
|
11
|
+
# Unless required by applicable law or agreed to in writing, software #
|
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT #
|
|
13
|
+
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #
|
|
14
|
+
# License for the specific language governing permissions and limitations #
|
|
15
|
+
# under the License. #
|
|
16
|
+
# #
|
|
17
|
+
###################################################################################
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
#
|
|
21
|
+
# DO NOT EDIT!!!
|
|
22
|
+
# File automatically generated by killbill-java-parser (git@github.com:killbill/killbill-java-parser.git)
|
|
23
|
+
#
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
module Killbill
|
|
27
|
+
module Plugin
|
|
28
|
+
module Model
|
|
29
|
+
|
|
30
|
+
java_package 'org.killbill.billing.catalog.api'
|
|
31
|
+
class Fixed
|
|
32
|
+
|
|
33
|
+
include org.killbill.billing.catalog.api.Fixed
|
|
34
|
+
|
|
35
|
+
attr_accessor :type, :price
|
|
36
|
+
|
|
37
|
+
def initialize()
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
def to_java()
|
|
41
|
+
# conversion for type [type = org.killbill.billing.catalog.api.FixedType]
|
|
42
|
+
@type = Java::org.killbill.billing.catalog.api.FixedType.value_of("#{@type.to_s}") unless @type.nil?
|
|
43
|
+
|
|
44
|
+
# conversion for price [type = org.killbill.billing.catalog.api.InternationalPrice]
|
|
45
|
+
@price = @price.to_java unless @price.nil?
|
|
46
|
+
self
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
def to_ruby(j_obj)
|
|
50
|
+
# conversion for type [type = org.killbill.billing.catalog.api.FixedType]
|
|
51
|
+
@type = j_obj.type
|
|
52
|
+
@type = @type.to_s.to_sym unless @type.nil?
|
|
53
|
+
|
|
54
|
+
# conversion for price [type = org.killbill.billing.catalog.api.InternationalPrice]
|
|
55
|
+
@price = j_obj.price
|
|
56
|
+
@price = Killbill::Plugin::Model::InternationalPrice.new.to_ruby(@price) unless @price.nil?
|
|
57
|
+
self
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
end
|
|
63
|
+
end
|
|
@@ -32,7 +32,7 @@ module Killbill
|
|
|
32
32
|
|
|
33
33
|
include org.killbill.billing.invoice.api.InvoiceItem
|
|
34
34
|
|
|
35
|
-
attr_accessor :id, :created_date, :updated_date, :invoice_item_type, :invoice_id, :account_id, :start_date, :end_date, :amount, :currency, :description, :bundle_id, :subscription_id, :plan_name, :phase_name, :rate, :linked_item_id
|
|
35
|
+
attr_accessor :id, :created_date, :updated_date, :invoice_item_type, :invoice_id, :account_id, :start_date, :end_date, :amount, :currency, :description, :bundle_id, :subscription_id, :plan_name, :phase_name, :usage_name, :rate, :linked_item_id
|
|
36
36
|
|
|
37
37
|
def initialize()
|
|
38
38
|
end
|
|
@@ -97,6 +97,9 @@ module Killbill
|
|
|
97
97
|
# conversion for phase_name [type = java.lang.String]
|
|
98
98
|
@phase_name = @phase_name.to_s unless @phase_name.nil?
|
|
99
99
|
|
|
100
|
+
# conversion for usage_name [type = java.lang.String]
|
|
101
|
+
@usage_name = @usage_name.to_s unless @usage_name.nil?
|
|
102
|
+
|
|
100
103
|
# conversion for rate [type = java.math.BigDecimal]
|
|
101
104
|
if @rate.nil?
|
|
102
105
|
@rate = java.math.BigDecimal::ZERO
|
|
@@ -179,6 +182,9 @@ module Killbill
|
|
|
179
182
|
# conversion for phase_name [type = java.lang.String]
|
|
180
183
|
@phase_name = j_obj.phase_name
|
|
181
184
|
|
|
185
|
+
# conversion for usage_name [type = java.lang.String]
|
|
186
|
+
@usage_name = j_obj.usage_name
|
|
187
|
+
|
|
182
188
|
# conversion for rate [type = java.math.BigDecimal]
|
|
183
189
|
@rate = j_obj.rate
|
|
184
190
|
@rate = @rate.nil? ? 0 : BigDecimal.new(@rate.to_s)
|
|
@@ -32,7 +32,7 @@ module Killbill
|
|
|
32
32
|
|
|
33
33
|
include org.killbill.billing.invoice.api.formatters.InvoiceItemFormatter
|
|
34
34
|
|
|
35
|
-
attr_accessor :invoice_item_type, :invoice_id, :account_id, :start_date, :end_date, :amount, :currency, :description, :bundle_id, :subscription_id, :plan_name, :phase_name, :rate, :linked_item_id, :id, :created_date, :updated_date, :formatted_start_date, :formatted_end_date, :formatted_amount
|
|
35
|
+
attr_accessor :invoice_item_type, :invoice_id, :account_id, :start_date, :end_date, :amount, :currency, :description, :bundle_id, :subscription_id, :plan_name, :phase_name, :usage_name, :rate, :linked_item_id, :id, :created_date, :updated_date, :formatted_start_date, :formatted_end_date, :formatted_amount
|
|
36
36
|
|
|
37
37
|
def initialize()
|
|
38
38
|
end
|
|
@@ -82,6 +82,9 @@ module Killbill
|
|
|
82
82
|
# conversion for phase_name [type = java.lang.String]
|
|
83
83
|
@phase_name = @phase_name.to_s unless @phase_name.nil?
|
|
84
84
|
|
|
85
|
+
# conversion for usage_name [type = java.lang.String]
|
|
86
|
+
@usage_name = @usage_name.to_s unless @usage_name.nil?
|
|
87
|
+
|
|
85
88
|
# conversion for rate [type = java.math.BigDecimal]
|
|
86
89
|
if @rate.nil?
|
|
87
90
|
@rate = java.math.BigDecimal::ZERO
|
|
@@ -168,6 +171,9 @@ module Killbill
|
|
|
168
171
|
# conversion for phase_name [type = java.lang.String]
|
|
169
172
|
@phase_name = j_obj.phase_name
|
|
170
173
|
|
|
174
|
+
# conversion for usage_name [type = java.lang.String]
|
|
175
|
+
@usage_name = j_obj.usage_name
|
|
176
|
+
|
|
171
177
|
# conversion for rate [type = java.math.BigDecimal]
|
|
172
178
|
@rate = j_obj.rate
|
|
173
179
|
@rate = @rate.nil? ? 0 : BigDecimal.new(@rate.to_s)
|
|
@@ -249,156 +249,38 @@ module Killbill
|
|
|
249
249
|
end
|
|
250
250
|
end
|
|
251
251
|
|
|
252
|
-
java_signature 'Java::
|
|
253
|
-
def
|
|
252
|
+
java_signature 'Java::java.util.List insertExternalCharges(Java::java.util.UUID, Java::org.joda.time.LocalDate, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
253
|
+
def insert_external_charges(accountId, effectiveDate, charges, context)
|
|
254
254
|
|
|
255
255
|
# conversion for accountId [type = java.util.UUID]
|
|
256
256
|
accountId = java.util.UUID.fromString(accountId.to_s) unless accountId.nil?
|
|
257
257
|
|
|
258
|
-
# conversion for amount [type = java.math.BigDecimal]
|
|
259
|
-
if amount.nil?
|
|
260
|
-
amount = java.math.BigDecimal::ZERO
|
|
261
|
-
else
|
|
262
|
-
amount = java.math.BigDecimal.new(amount.to_s)
|
|
263
|
-
end
|
|
264
|
-
|
|
265
|
-
# conversion for description [type = java.lang.String]
|
|
266
|
-
description = description.to_s unless description.nil?
|
|
267
|
-
|
|
268
|
-
# conversion for effectiveDate [type = org.joda.time.LocalDate]
|
|
269
|
-
if !effectiveDate.nil?
|
|
270
|
-
effectiveDate = Java::org.joda.time.LocalDate.parse(effectiveDate.to_s)
|
|
271
|
-
end
|
|
272
|
-
|
|
273
|
-
# conversion for currency [type = org.killbill.billing.catalog.api.Currency]
|
|
274
|
-
currency = Java::org.killbill.billing.catalog.api.Currency.value_of("#{currency.to_s}") unless currency.nil?
|
|
275
|
-
|
|
276
|
-
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
277
|
-
context = context.to_java unless context.nil?
|
|
278
|
-
begin
|
|
279
|
-
res = @real_java_api.insert_external_charge(accountId, amount, description, effectiveDate, currency, context)
|
|
280
|
-
# conversion for res [type = org.killbill.billing.invoice.api.InvoiceItem]
|
|
281
|
-
res = Killbill::Plugin::Model::InvoiceItem.new.to_ruby(res) unless res.nil?
|
|
282
|
-
return res
|
|
283
|
-
rescue Java::org.killbill.billing.invoice.api.InvoiceApiException => e
|
|
284
|
-
raise Killbill::Plugin::Model::InvoiceApiException.new.to_ruby(e)
|
|
285
|
-
end
|
|
286
|
-
end
|
|
287
|
-
|
|
288
|
-
java_signature 'Java::org.killbill.billing.invoice.api.InvoiceItem insertExternalChargeForBundle(Java::java.util.UUID, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.String, Java::org.joda.time.LocalDate, Java::org.killbill.billing.catalog.api.Currency, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
289
|
-
def insert_external_charge_for_bundle(accountId, bundleId, amount, description, effectiveDate, currency, context)
|
|
290
|
-
|
|
291
|
-
# conversion for accountId [type = java.util.UUID]
|
|
292
|
-
accountId = java.util.UUID.fromString(accountId.to_s) unless accountId.nil?
|
|
293
|
-
|
|
294
|
-
# conversion for bundleId [type = java.util.UUID]
|
|
295
|
-
bundleId = java.util.UUID.fromString(bundleId.to_s) unless bundleId.nil?
|
|
296
|
-
|
|
297
|
-
# conversion for amount [type = java.math.BigDecimal]
|
|
298
|
-
if amount.nil?
|
|
299
|
-
amount = java.math.BigDecimal::ZERO
|
|
300
|
-
else
|
|
301
|
-
amount = java.math.BigDecimal.new(amount.to_s)
|
|
302
|
-
end
|
|
303
|
-
|
|
304
|
-
# conversion for description [type = java.lang.String]
|
|
305
|
-
description = description.to_s unless description.nil?
|
|
306
|
-
|
|
307
|
-
# conversion for effectiveDate [type = org.joda.time.LocalDate]
|
|
308
|
-
if !effectiveDate.nil?
|
|
309
|
-
effectiveDate = Java::org.joda.time.LocalDate.parse(effectiveDate.to_s)
|
|
310
|
-
end
|
|
311
|
-
|
|
312
|
-
# conversion for currency [type = org.killbill.billing.catalog.api.Currency]
|
|
313
|
-
currency = Java::org.killbill.billing.catalog.api.Currency.value_of("#{currency.to_s}") unless currency.nil?
|
|
314
|
-
|
|
315
|
-
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
316
|
-
context = context.to_java unless context.nil?
|
|
317
|
-
begin
|
|
318
|
-
res = @real_java_api.insert_external_charge_for_bundle(accountId, bundleId, amount, description, effectiveDate, currency, context)
|
|
319
|
-
# conversion for res [type = org.killbill.billing.invoice.api.InvoiceItem]
|
|
320
|
-
res = Killbill::Plugin::Model::InvoiceItem.new.to_ruby(res) unless res.nil?
|
|
321
|
-
return res
|
|
322
|
-
rescue Java::org.killbill.billing.invoice.api.InvoiceApiException => e
|
|
323
|
-
raise Killbill::Plugin::Model::InvoiceApiException.new.to_ruby(e)
|
|
324
|
-
end
|
|
325
|
-
end
|
|
326
|
-
|
|
327
|
-
java_signature 'Java::org.killbill.billing.invoice.api.InvoiceItem insertExternalChargeForInvoice(Java::java.util.UUID, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.String, Java::org.joda.time.LocalDate, Java::org.killbill.billing.catalog.api.Currency, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
328
|
-
def insert_external_charge_for_invoice(accountId, invoiceId, amount, description, effectiveDate, currency, context)
|
|
329
|
-
|
|
330
|
-
# conversion for accountId [type = java.util.UUID]
|
|
331
|
-
accountId = java.util.UUID.fromString(accountId.to_s) unless accountId.nil?
|
|
332
|
-
|
|
333
|
-
# conversion for invoiceId [type = java.util.UUID]
|
|
334
|
-
invoiceId = java.util.UUID.fromString(invoiceId.to_s) unless invoiceId.nil?
|
|
335
|
-
|
|
336
|
-
# conversion for amount [type = java.math.BigDecimal]
|
|
337
|
-
if amount.nil?
|
|
338
|
-
amount = java.math.BigDecimal::ZERO
|
|
339
|
-
else
|
|
340
|
-
amount = java.math.BigDecimal.new(amount.to_s)
|
|
341
|
-
end
|
|
342
|
-
|
|
343
|
-
# conversion for description [type = java.lang.String]
|
|
344
|
-
description = description.to_s unless description.nil?
|
|
345
|
-
|
|
346
258
|
# conversion for effectiveDate [type = org.joda.time.LocalDate]
|
|
347
259
|
if !effectiveDate.nil?
|
|
348
260
|
effectiveDate = Java::org.joda.time.LocalDate.parse(effectiveDate.to_s)
|
|
349
261
|
end
|
|
350
262
|
|
|
351
|
-
# conversion for
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
res = @real_java_api.insert_external_charge_for_invoice(accountId, invoiceId, amount, description, effectiveDate, currency, context)
|
|
358
|
-
# conversion for res [type = org.killbill.billing.invoice.api.InvoiceItem]
|
|
359
|
-
res = Killbill::Plugin::Model::InvoiceItem.new.to_ruby(res) unless res.nil?
|
|
360
|
-
return res
|
|
361
|
-
rescue Java::org.killbill.billing.invoice.api.InvoiceApiException => e
|
|
362
|
-
raise Killbill::Plugin::Model::InvoiceApiException.new.to_ruby(e)
|
|
363
|
-
end
|
|
364
|
-
end
|
|
365
|
-
|
|
366
|
-
java_signature 'Java::org.killbill.billing.invoice.api.InvoiceItem insertExternalChargeForInvoiceAndBundle(Java::java.util.UUID, Java::java.util.UUID, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.String, Java::org.joda.time.LocalDate, Java::org.killbill.billing.catalog.api.Currency, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
367
|
-
def insert_external_charge_for_invoice_and_bundle(accountId, invoiceId, bundleId, amount, description, effectiveDate, currency, context)
|
|
368
|
-
|
|
369
|
-
# conversion for accountId [type = java.util.UUID]
|
|
370
|
-
accountId = java.util.UUID.fromString(accountId.to_s) unless accountId.nil?
|
|
371
|
-
|
|
372
|
-
# conversion for invoiceId [type = java.util.UUID]
|
|
373
|
-
invoiceId = java.util.UUID.fromString(invoiceId.to_s) unless invoiceId.nil?
|
|
374
|
-
|
|
375
|
-
# conversion for bundleId [type = java.util.UUID]
|
|
376
|
-
bundleId = java.util.UUID.fromString(bundleId.to_s) unless bundleId.nil?
|
|
377
|
-
|
|
378
|
-
# conversion for amount [type = java.math.BigDecimal]
|
|
379
|
-
if amount.nil?
|
|
380
|
-
amount = java.math.BigDecimal::ZERO
|
|
381
|
-
else
|
|
382
|
-
amount = java.math.BigDecimal.new(amount.to_s)
|
|
383
|
-
end
|
|
384
|
-
|
|
385
|
-
# conversion for description [type = java.lang.String]
|
|
386
|
-
description = description.to_s unless description.nil?
|
|
387
|
-
|
|
388
|
-
# conversion for effectiveDate [type = org.joda.time.LocalDate]
|
|
389
|
-
if !effectiveDate.nil?
|
|
390
|
-
effectiveDate = Java::org.joda.time.LocalDate.parse(effectiveDate.to_s)
|
|
263
|
+
# conversion for charges [type = java.lang.Iterable]
|
|
264
|
+
tmp = java.util.ArrayList.new
|
|
265
|
+
(charges || []).each do |m|
|
|
266
|
+
# conversion for m [type = org.killbill.billing.invoice.api.InvoiceItem]
|
|
267
|
+
m = m.to_java unless m.nil?
|
|
268
|
+
tmp.add(m)
|
|
391
269
|
end
|
|
392
|
-
|
|
393
|
-
# conversion for currency [type = org.killbill.billing.catalog.api.Currency]
|
|
394
|
-
currency = Java::org.killbill.billing.catalog.api.Currency.value_of("#{currency.to_s}") unless currency.nil?
|
|
270
|
+
charges = tmp
|
|
395
271
|
|
|
396
272
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
397
273
|
context = context.to_java unless context.nil?
|
|
398
274
|
begin
|
|
399
|
-
res = @real_java_api.
|
|
400
|
-
# conversion for res [type =
|
|
401
|
-
|
|
275
|
+
res = @real_java_api.insert_external_charges(accountId, effectiveDate, charges, context)
|
|
276
|
+
# conversion for res [type = java.util.List]
|
|
277
|
+
tmp = []
|
|
278
|
+
(res || []).each do |m|
|
|
279
|
+
# conversion for m [type = org.killbill.billing.invoice.api.InvoiceItem]
|
|
280
|
+
m = Killbill::Plugin::Model::InvoiceItem.new.to_ruby(m) unless m.nil?
|
|
281
|
+
tmp << m
|
|
282
|
+
end
|
|
283
|
+
res = tmp
|
|
402
284
|
return res
|
|
403
285
|
rescue Java::org.killbill.billing.invoice.api.InvoiceApiException => e
|
|
404
286
|
raise Killbill::Plugin::Model::InvoiceApiException.new.to_ruby(e)
|
|
@@ -32,7 +32,7 @@ module Killbill
|
|
|
32
32
|
|
|
33
33
|
include org.killbill.billing.catalog.api.MigrationPlan
|
|
34
34
|
|
|
35
|
-
attr_accessor :initial_phases, :product, :name, :is_retired, :initial_phase_iterator, :final_phase, :
|
|
35
|
+
attr_accessor :initial_phases, :product, :name, :is_retired, :initial_phase_iterator, :final_phase, :recurring_billing_period, :plans_allowed_in_bundle, :all_phases, :effective_date_for_existing_subscriptons
|
|
36
36
|
|
|
37
37
|
def initialize()
|
|
38
38
|
end
|
|
@@ -56,8 +56,8 @@ module Killbill
|
|
|
56
56
|
# conversion for final_phase [type = org.killbill.billing.catalog.api.PlanPhase]
|
|
57
57
|
@final_phase = @final_phase.to_java unless @final_phase.nil?
|
|
58
58
|
|
|
59
|
-
# conversion for
|
|
60
|
-
@
|
|
59
|
+
# conversion for recurring_billing_period [type = org.killbill.billing.catalog.api.BillingPeriod]
|
|
60
|
+
@recurring_billing_period = Java::org.killbill.billing.catalog.api.BillingPeriod.value_of("#{@recurring_billing_period.to_s}") unless @recurring_billing_period.nil?
|
|
61
61
|
|
|
62
62
|
# conversion for plans_allowed_in_bundle [type = int]
|
|
63
63
|
@plans_allowed_in_bundle = @plans_allowed_in_bundle
|
|
@@ -102,9 +102,9 @@ module Killbill
|
|
|
102
102
|
@final_phase = j_obj.final_phase
|
|
103
103
|
@final_phase = Killbill::Plugin::Model::PlanPhase.new.to_ruby(@final_phase) unless @final_phase.nil?
|
|
104
104
|
|
|
105
|
-
# conversion for
|
|
106
|
-
@
|
|
107
|
-
@
|
|
105
|
+
# conversion for recurring_billing_period [type = org.killbill.billing.catalog.api.BillingPeriod]
|
|
106
|
+
@recurring_billing_period = j_obj.recurring_billing_period
|
|
107
|
+
@recurring_billing_period = @recurring_billing_period.to_s.to_sym unless @recurring_billing_period.nil?
|
|
108
108
|
|
|
109
109
|
# conversion for plans_allowed_in_bundle [type = int]
|
|
110
110
|
@plans_allowed_in_bundle = j_obj.plans_allowed_in_bundle
|
|
@@ -37,8 +37,8 @@ module Killbill
|
|
|
37
37
|
end
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
java_signature 'Java::org.killbill.billing.payment.api.Payment createPayment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
41
|
-
def create_payment(account, invoiceId, amount, context)
|
|
40
|
+
java_signature 'Java::org.killbill.billing.payment.api.Payment createPayment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
41
|
+
def create_payment(account, invoiceId, amount, properties, context)
|
|
42
42
|
|
|
43
43
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
44
44
|
account = account.to_java unless account.nil?
|
|
@@ -53,10 +53,19 @@ module Killbill
|
|
|
53
53
|
amount = java.math.BigDecimal.new(amount.to_s)
|
|
54
54
|
end
|
|
55
55
|
|
|
56
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
57
|
+
tmp = java.util.ArrayList.new
|
|
58
|
+
(properties || []).each do |m|
|
|
59
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
60
|
+
m = m.to_java unless m.nil?
|
|
61
|
+
tmp.add(m)
|
|
62
|
+
end
|
|
63
|
+
properties = tmp
|
|
64
|
+
|
|
56
65
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
57
66
|
context = context.to_java unless context.nil?
|
|
58
67
|
begin
|
|
59
|
-
res = @real_java_api.create_payment(account, invoiceId, amount, context)
|
|
68
|
+
res = @real_java_api.create_payment(account, invoiceId, amount, properties, context)
|
|
60
69
|
# conversion for res [type = org.killbill.billing.payment.api.Payment]
|
|
61
70
|
res = Killbill::Plugin::Model::Payment.new.to_ruby(res) unless res.nil?
|
|
62
71
|
return res
|
|
@@ -110,8 +119,8 @@ module Killbill
|
|
|
110
119
|
@real_java_api.notify_pending_payment_of_state_changed(account, paymentId, isSuccess, context)
|
|
111
120
|
end
|
|
112
121
|
|
|
113
|
-
java_signature 'Java::org.killbill.billing.payment.api.Payment retryPayment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
114
|
-
def retry_payment(account, paymentId, context)
|
|
122
|
+
java_signature 'Java::org.killbill.billing.payment.api.Payment retryPayment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
123
|
+
def retry_payment(account, paymentId, properties, context)
|
|
115
124
|
|
|
116
125
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
117
126
|
account = account.to_java unless account.nil?
|
|
@@ -119,10 +128,19 @@ module Killbill
|
|
|
119
128
|
# conversion for paymentId [type = java.util.UUID]
|
|
120
129
|
paymentId = java.util.UUID.fromString(paymentId.to_s) unless paymentId.nil?
|
|
121
130
|
|
|
131
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
132
|
+
tmp = java.util.ArrayList.new
|
|
133
|
+
(properties || []).each do |m|
|
|
134
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
135
|
+
m = m.to_java unless m.nil?
|
|
136
|
+
tmp.add(m)
|
|
137
|
+
end
|
|
138
|
+
properties = tmp
|
|
139
|
+
|
|
122
140
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
123
141
|
context = context.to_java unless context.nil?
|
|
124
142
|
begin
|
|
125
|
-
res = @real_java_api.retry_payment(account, paymentId, context)
|
|
143
|
+
res = @real_java_api.retry_payment(account, paymentId, properties, context)
|
|
126
144
|
# conversion for res [type = org.killbill.billing.payment.api.Payment]
|
|
127
145
|
res = Killbill::Plugin::Model::Payment.new.to_ruby(res) unless res.nil?
|
|
128
146
|
return res
|
|
@@ -131,8 +149,8 @@ module Killbill
|
|
|
131
149
|
end
|
|
132
150
|
end
|
|
133
151
|
|
|
134
|
-
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefund(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
135
|
-
def create_refund(account, paymentId, refundAmount, context)
|
|
152
|
+
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefund(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
153
|
+
def create_refund(account, paymentId, refundAmount, properties, context)
|
|
136
154
|
|
|
137
155
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
138
156
|
account = account.to_java unless account.nil?
|
|
@@ -147,10 +165,19 @@ module Killbill
|
|
|
147
165
|
refundAmount = java.math.BigDecimal.new(refundAmount.to_s)
|
|
148
166
|
end
|
|
149
167
|
|
|
168
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
169
|
+
tmp = java.util.ArrayList.new
|
|
170
|
+
(properties || []).each do |m|
|
|
171
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
172
|
+
m = m.to_java unless m.nil?
|
|
173
|
+
tmp.add(m)
|
|
174
|
+
end
|
|
175
|
+
properties = tmp
|
|
176
|
+
|
|
150
177
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
151
178
|
context = context.to_java unless context.nil?
|
|
152
179
|
begin
|
|
153
|
-
res = @real_java_api.create_refund(account, paymentId, refundAmount, context)
|
|
180
|
+
res = @real_java_api.create_refund(account, paymentId, refundAmount, properties, context)
|
|
154
181
|
# conversion for res [type = org.killbill.billing.payment.api.Refund]
|
|
155
182
|
res = Killbill::Plugin::Model::Refund.new.to_ruby(res) unless res.nil?
|
|
156
183
|
return res
|
|
@@ -176,8 +203,8 @@ module Killbill
|
|
|
176
203
|
@real_java_api.notify_pending_refund_of_state_changed(account, paymentId, isSuccess, context)
|
|
177
204
|
end
|
|
178
205
|
|
|
179
|
-
java_signature 'Java::org.killbill.billing.payment.api.Refund getRefund(Java::java.util.UUID, Java::boolean, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
180
|
-
def get_refund(refundId, withPluginInfo, context)
|
|
206
|
+
java_signature 'Java::org.killbill.billing.payment.api.Refund getRefund(Java::java.util.UUID, Java::boolean, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
207
|
+
def get_refund(refundId, withPluginInfo, properties, context)
|
|
181
208
|
|
|
182
209
|
# conversion for refundId [type = java.util.UUID]
|
|
183
210
|
refundId = java.util.UUID.fromString(refundId.to_s) unless refundId.nil?
|
|
@@ -185,10 +212,19 @@ module Killbill
|
|
|
185
212
|
# conversion for withPluginInfo [type = boolean]
|
|
186
213
|
withPluginInfo = withPluginInfo.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(withPluginInfo)
|
|
187
214
|
|
|
215
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
216
|
+
tmp = java.util.ArrayList.new
|
|
217
|
+
(properties || []).each do |m|
|
|
218
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
219
|
+
m = m.to_java unless m.nil?
|
|
220
|
+
tmp.add(m)
|
|
221
|
+
end
|
|
222
|
+
properties = tmp
|
|
223
|
+
|
|
188
224
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
189
225
|
context = context.to_java unless context.nil?
|
|
190
226
|
begin
|
|
191
|
-
res = @real_java_api.get_refund(refundId, withPluginInfo, context)
|
|
227
|
+
res = @real_java_api.get_refund(refundId, withPluginInfo, properties, context)
|
|
192
228
|
# conversion for res [type = org.killbill.billing.payment.api.Refund]
|
|
193
229
|
res = Killbill::Plugin::Model::Refund.new.to_ruby(res) unless res.nil?
|
|
194
230
|
return res
|
|
@@ -197,8 +233,8 @@ module Killbill
|
|
|
197
233
|
end
|
|
198
234
|
end
|
|
199
235
|
|
|
200
|
-
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefundWithAdjustment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
201
|
-
def create_refund_with_adjustment(account, paymentId, refundAmount, context)
|
|
236
|
+
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefundWithAdjustment(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.math.BigDecimal, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
237
|
+
def create_refund_with_adjustment(account, paymentId, refundAmount, properties, context)
|
|
202
238
|
|
|
203
239
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
204
240
|
account = account.to_java unless account.nil?
|
|
@@ -213,10 +249,19 @@ module Killbill
|
|
|
213
249
|
refundAmount = java.math.BigDecimal.new(refundAmount.to_s)
|
|
214
250
|
end
|
|
215
251
|
|
|
252
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
253
|
+
tmp = java.util.ArrayList.new
|
|
254
|
+
(properties || []).each do |m|
|
|
255
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
256
|
+
m = m.to_java unless m.nil?
|
|
257
|
+
tmp.add(m)
|
|
258
|
+
end
|
|
259
|
+
properties = tmp
|
|
260
|
+
|
|
216
261
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
217
262
|
context = context.to_java unless context.nil?
|
|
218
263
|
begin
|
|
219
|
-
res = @real_java_api.create_refund_with_adjustment(account, paymentId, refundAmount, context)
|
|
264
|
+
res = @real_java_api.create_refund_with_adjustment(account, paymentId, refundAmount, properties, context)
|
|
220
265
|
# conversion for res [type = org.killbill.billing.payment.api.Refund]
|
|
221
266
|
res = Killbill::Plugin::Model::Refund.new.to_ruby(res) unless res.nil?
|
|
222
267
|
return res
|
|
@@ -225,8 +270,8 @@ module Killbill
|
|
|
225
270
|
end
|
|
226
271
|
end
|
|
227
272
|
|
|
228
|
-
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefundWithItemsAdjustments(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.util.Set, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
229
|
-
def create_refund_with_items_adjustments(account, paymentId, invoiceItemIds, context)
|
|
273
|
+
java_signature 'Java::org.killbill.billing.payment.api.Refund createRefundWithItemsAdjustments(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.util.Set, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
274
|
+
def create_refund_with_items_adjustments(account, paymentId, invoiceItemIds, properties, context)
|
|
230
275
|
|
|
231
276
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
232
277
|
account = account.to_java unless account.nil?
|
|
@@ -243,10 +288,19 @@ module Killbill
|
|
|
243
288
|
end
|
|
244
289
|
invoiceItemIds = tmp
|
|
245
290
|
|
|
291
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
292
|
+
tmp = java.util.ArrayList.new
|
|
293
|
+
(properties || []).each do |m|
|
|
294
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
295
|
+
m = m.to_java unless m.nil?
|
|
296
|
+
tmp.add(m)
|
|
297
|
+
end
|
|
298
|
+
properties = tmp
|
|
299
|
+
|
|
246
300
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
247
301
|
context = context.to_java unless context.nil?
|
|
248
302
|
begin
|
|
249
|
-
res = @real_java_api.create_refund_with_items_adjustments(account, paymentId, invoiceItemIds, context)
|
|
303
|
+
res = @real_java_api.create_refund_with_items_adjustments(account, paymentId, invoiceItemIds, properties, context)
|
|
250
304
|
# conversion for res [type = org.killbill.billing.payment.api.Refund]
|
|
251
305
|
res = Killbill::Plugin::Model::Refund.new.to_ruby(res) unless res.nil?
|
|
252
306
|
return res
|
|
@@ -351,8 +405,8 @@ module Killbill
|
|
|
351
405
|
end
|
|
352
406
|
end
|
|
353
407
|
|
|
354
|
-
java_signature 'Java::org.killbill.billing.payment.api.Payment getPayment(Java::java.util.UUID, Java::boolean, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
355
|
-
def get_payment(paymentId, withPluginInfo, context)
|
|
408
|
+
java_signature 'Java::org.killbill.billing.payment.api.Payment getPayment(Java::java.util.UUID, Java::boolean, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
409
|
+
def get_payment(paymentId, withPluginInfo, properties, context)
|
|
356
410
|
|
|
357
411
|
# conversion for paymentId [type = java.util.UUID]
|
|
358
412
|
paymentId = java.util.UUID.fromString(paymentId.to_s) unless paymentId.nil?
|
|
@@ -360,10 +414,19 @@ module Killbill
|
|
|
360
414
|
# conversion for withPluginInfo [type = boolean]
|
|
361
415
|
withPluginInfo = withPluginInfo.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(withPluginInfo)
|
|
362
416
|
|
|
417
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
418
|
+
tmp = java.util.ArrayList.new
|
|
419
|
+
(properties || []).each do |m|
|
|
420
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
421
|
+
m = m.to_java unless m.nil?
|
|
422
|
+
tmp.add(m)
|
|
423
|
+
end
|
|
424
|
+
properties = tmp
|
|
425
|
+
|
|
363
426
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
364
427
|
context = context.to_java unless context.nil?
|
|
365
428
|
begin
|
|
366
|
-
res = @real_java_api.get_payment(paymentId, withPluginInfo, context)
|
|
429
|
+
res = @real_java_api.get_payment(paymentId, withPluginInfo, properties, context)
|
|
367
430
|
# conversion for res [type = org.killbill.billing.payment.api.Payment]
|
|
368
431
|
res = Killbill::Plugin::Model::Payment.new.to_ruby(res) unless res.nil?
|
|
369
432
|
return res
|
|
@@ -372,8 +435,8 @@ module Killbill
|
|
|
372
435
|
end
|
|
373
436
|
end
|
|
374
437
|
|
|
375
|
-
java_signature 'Java::org.killbill.billing.util.entity.Pagination getPayments(Java::java.lang.Long, Java::java.lang.Long, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
376
|
-
def get_payments(offset, limit, context)
|
|
438
|
+
java_signature 'Java::org.killbill.billing.util.entity.Pagination getPayments(Java::java.lang.Long, Java::java.lang.Long, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
439
|
+
def get_payments(offset, limit, properties, context)
|
|
377
440
|
|
|
378
441
|
# conversion for offset [type = java.lang.Long]
|
|
379
442
|
offset = offset
|
|
@@ -381,16 +444,25 @@ module Killbill
|
|
|
381
444
|
# conversion for limit [type = java.lang.Long]
|
|
382
445
|
limit = limit
|
|
383
446
|
|
|
447
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
448
|
+
tmp = java.util.ArrayList.new
|
|
449
|
+
(properties || []).each do |m|
|
|
450
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
451
|
+
m = m.to_java unless m.nil?
|
|
452
|
+
tmp.add(m)
|
|
453
|
+
end
|
|
454
|
+
properties = tmp
|
|
455
|
+
|
|
384
456
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
385
457
|
context = context.to_java unless context.nil?
|
|
386
|
-
res = @real_java_api.get_payments(offset, limit, context)
|
|
458
|
+
res = @real_java_api.get_payments(offset, limit, properties, context)
|
|
387
459
|
# conversion for res [type = org.killbill.billing.util.entity.Pagination]
|
|
388
460
|
res = Killbill::Plugin::Model::Pagination.new.to_ruby(res) unless res.nil?
|
|
389
461
|
return res
|
|
390
462
|
end
|
|
391
463
|
|
|
392
|
-
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchPayments(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
393
|
-
def search_payments(searchKey, offset, limit, context)
|
|
464
|
+
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchPayments(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
465
|
+
def search_payments(searchKey, offset, limit, properties, context)
|
|
394
466
|
|
|
395
467
|
# conversion for searchKey [type = java.lang.String]
|
|
396
468
|
searchKey = searchKey.to_s unless searchKey.nil?
|
|
@@ -401,16 +473,25 @@ module Killbill
|
|
|
401
473
|
# conversion for limit [type = java.lang.Long]
|
|
402
474
|
limit = limit
|
|
403
475
|
|
|
476
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
477
|
+
tmp = java.util.ArrayList.new
|
|
478
|
+
(properties || []).each do |m|
|
|
479
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
480
|
+
m = m.to_java unless m.nil?
|
|
481
|
+
tmp.add(m)
|
|
482
|
+
end
|
|
483
|
+
properties = tmp
|
|
484
|
+
|
|
404
485
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
405
486
|
context = context.to_java unless context.nil?
|
|
406
|
-
res = @real_java_api.search_payments(searchKey, offset, limit, context)
|
|
487
|
+
res = @real_java_api.search_payments(searchKey, offset, limit, properties, context)
|
|
407
488
|
# conversion for res [type = org.killbill.billing.util.entity.Pagination]
|
|
408
489
|
res = Killbill::Plugin::Model::Pagination.new.to_ruby(res) unless res.nil?
|
|
409
490
|
return res
|
|
410
491
|
end
|
|
411
492
|
|
|
412
|
-
java_signature 'Java::org.killbill.billing.util.entity.Pagination getRefunds(Java::java.lang.Long, Java::java.lang.Long, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
413
|
-
def get_refunds(offset, limit, context)
|
|
493
|
+
java_signature 'Java::org.killbill.billing.util.entity.Pagination getRefunds(Java::java.lang.Long, Java::java.lang.Long, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
494
|
+
def get_refunds(offset, limit, properties, context)
|
|
414
495
|
|
|
415
496
|
# conversion for offset [type = java.lang.Long]
|
|
416
497
|
offset = offset
|
|
@@ -418,16 +499,25 @@ module Killbill
|
|
|
418
499
|
# conversion for limit [type = java.lang.Long]
|
|
419
500
|
limit = limit
|
|
420
501
|
|
|
502
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
503
|
+
tmp = java.util.ArrayList.new
|
|
504
|
+
(properties || []).each do |m|
|
|
505
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
506
|
+
m = m.to_java unless m.nil?
|
|
507
|
+
tmp.add(m)
|
|
508
|
+
end
|
|
509
|
+
properties = tmp
|
|
510
|
+
|
|
421
511
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
422
512
|
context = context.to_java unless context.nil?
|
|
423
|
-
res = @real_java_api.get_refunds(offset, limit, context)
|
|
513
|
+
res = @real_java_api.get_refunds(offset, limit, properties, context)
|
|
424
514
|
# conversion for res [type = org.killbill.billing.util.entity.Pagination]
|
|
425
515
|
res = Killbill::Plugin::Model::Pagination.new.to_ruby(res) unless res.nil?
|
|
426
516
|
return res
|
|
427
517
|
end
|
|
428
518
|
|
|
429
|
-
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchRefunds(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
430
|
-
def search_refunds(searchKey, offset, limit, context)
|
|
519
|
+
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchRefunds(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
520
|
+
def search_refunds(searchKey, offset, limit, properties, context)
|
|
431
521
|
|
|
432
522
|
# conversion for searchKey [type = java.lang.String]
|
|
433
523
|
searchKey = searchKey.to_s unless searchKey.nil?
|
|
@@ -438,9 +528,18 @@ module Killbill
|
|
|
438
528
|
# conversion for limit [type = java.lang.Long]
|
|
439
529
|
limit = limit
|
|
440
530
|
|
|
531
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
532
|
+
tmp = java.util.ArrayList.new
|
|
533
|
+
(properties || []).each do |m|
|
|
534
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
535
|
+
m = m.to_java unless m.nil?
|
|
536
|
+
tmp.add(m)
|
|
537
|
+
end
|
|
538
|
+
properties = tmp
|
|
539
|
+
|
|
441
540
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
442
541
|
context = context.to_java unless context.nil?
|
|
443
|
-
res = @real_java_api.search_refunds(searchKey, offset, limit, context)
|
|
542
|
+
res = @real_java_api.search_refunds(searchKey, offset, limit, properties, context)
|
|
444
543
|
# conversion for res [type = org.killbill.billing.util.entity.Pagination]
|
|
445
544
|
res = Killbill::Plugin::Model::Pagination.new.to_ruby(res) unless res.nil?
|
|
446
545
|
return res
|
|
@@ -459,8 +558,8 @@ module Killbill
|
|
|
459
558
|
return res
|
|
460
559
|
end
|
|
461
560
|
|
|
462
|
-
java_signature 'Java::java.util.UUID addPaymentMethod(Java::java.lang.String, Java::org.killbill.billing.account.api.Account, Java::boolean, Java::org.killbill.billing.payment.api.PaymentMethodPlugin, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
463
|
-
def add_payment_method(pluginName, account, setDefault, paymentMethodInfo, context)
|
|
561
|
+
java_signature 'Java::java.util.UUID addPaymentMethod(Java::java.lang.String, Java::org.killbill.billing.account.api.Account, Java::boolean, Java::org.killbill.billing.payment.api.PaymentMethodPlugin, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
562
|
+
def add_payment_method(pluginName, account, setDefault, paymentMethodInfo, properties, context)
|
|
464
563
|
|
|
465
564
|
# conversion for pluginName [type = java.lang.String]
|
|
466
565
|
pluginName = pluginName.to_s unless pluginName.nil?
|
|
@@ -474,10 +573,19 @@ module Killbill
|
|
|
474
573
|
# conversion for paymentMethodInfo [type = org.killbill.billing.payment.api.PaymentMethodPlugin]
|
|
475
574
|
paymentMethodInfo = paymentMethodInfo.to_java unless paymentMethodInfo.nil?
|
|
476
575
|
|
|
576
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
577
|
+
tmp = java.util.ArrayList.new
|
|
578
|
+
(properties || []).each do |m|
|
|
579
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
580
|
+
m = m.to_java unless m.nil?
|
|
581
|
+
tmp.add(m)
|
|
582
|
+
end
|
|
583
|
+
properties = tmp
|
|
584
|
+
|
|
477
585
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
478
586
|
context = context.to_java unless context.nil?
|
|
479
587
|
begin
|
|
480
|
-
res = @real_java_api.add_payment_method(pluginName, account, setDefault, paymentMethodInfo, context)
|
|
588
|
+
res = @real_java_api.add_payment_method(pluginName, account, setDefault, paymentMethodInfo, properties, context)
|
|
481
589
|
# conversion for res [type = java.util.UUID]
|
|
482
590
|
res = res.nil? ? nil : res.to_s
|
|
483
591
|
return res
|
|
@@ -486,8 +594,8 @@ module Killbill
|
|
|
486
594
|
end
|
|
487
595
|
end
|
|
488
596
|
|
|
489
|
-
java_signature 'Java::java.util.List getPaymentMethods(Java::org.killbill.billing.account.api.Account, Java::boolean, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
490
|
-
def get_payment_methods(account, withPluginInfo, context)
|
|
597
|
+
java_signature 'Java::java.util.List getPaymentMethods(Java::org.killbill.billing.account.api.Account, Java::boolean, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
598
|
+
def get_payment_methods(account, withPluginInfo, properties, context)
|
|
491
599
|
|
|
492
600
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
493
601
|
account = account.to_java unless account.nil?
|
|
@@ -495,10 +603,19 @@ module Killbill
|
|
|
495
603
|
# conversion for withPluginInfo [type = boolean]
|
|
496
604
|
withPluginInfo = withPluginInfo.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(withPluginInfo)
|
|
497
605
|
|
|
606
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
607
|
+
tmp = java.util.ArrayList.new
|
|
608
|
+
(properties || []).each do |m|
|
|
609
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
610
|
+
m = m.to_java unless m.nil?
|
|
611
|
+
tmp.add(m)
|
|
612
|
+
end
|
|
613
|
+
properties = tmp
|
|
614
|
+
|
|
498
615
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
499
616
|
context = context.to_java unless context.nil?
|
|
500
617
|
begin
|
|
501
|
-
res = @real_java_api.get_payment_methods(account, withPluginInfo, context)
|
|
618
|
+
res = @real_java_api.get_payment_methods(account, withPluginInfo, properties, context)
|
|
502
619
|
# conversion for res [type = java.util.List]
|
|
503
620
|
tmp = []
|
|
504
621
|
(res || []).each do |m|
|
|
@@ -513,8 +630,8 @@ module Killbill
|
|
|
513
630
|
end
|
|
514
631
|
end
|
|
515
632
|
|
|
516
|
-
java_signature 'Java::org.killbill.billing.payment.api.PaymentMethod getPaymentMethodById(Java::java.util.UUID, Java::boolean, Java::boolean, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
517
|
-
def get_payment_method_by_id(paymentMethodId, includedInactive, withPluginInfo, context)
|
|
633
|
+
java_signature 'Java::org.killbill.billing.payment.api.PaymentMethod getPaymentMethodById(Java::java.util.UUID, Java::boolean, Java::boolean, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
634
|
+
def get_payment_method_by_id(paymentMethodId, includedInactive, withPluginInfo, properties, context)
|
|
518
635
|
|
|
519
636
|
# conversion for paymentMethodId [type = java.util.UUID]
|
|
520
637
|
paymentMethodId = java.util.UUID.fromString(paymentMethodId.to_s) unless paymentMethodId.nil?
|
|
@@ -525,10 +642,19 @@ module Killbill
|
|
|
525
642
|
# conversion for withPluginInfo [type = boolean]
|
|
526
643
|
withPluginInfo = withPluginInfo.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(withPluginInfo)
|
|
527
644
|
|
|
645
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
646
|
+
tmp = java.util.ArrayList.new
|
|
647
|
+
(properties || []).each do |m|
|
|
648
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
649
|
+
m = m.to_java unless m.nil?
|
|
650
|
+
tmp.add(m)
|
|
651
|
+
end
|
|
652
|
+
properties = tmp
|
|
653
|
+
|
|
528
654
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
529
655
|
context = context.to_java unless context.nil?
|
|
530
656
|
begin
|
|
531
|
-
res = @real_java_api.get_payment_method_by_id(paymentMethodId, includedInactive, withPluginInfo, context)
|
|
657
|
+
res = @real_java_api.get_payment_method_by_id(paymentMethodId, includedInactive, withPluginInfo, properties, context)
|
|
532
658
|
# conversion for res [type = org.killbill.billing.payment.api.PaymentMethod]
|
|
533
659
|
res = Killbill::Plugin::Model::PaymentMethod.new.to_ruby(res) unless res.nil?
|
|
534
660
|
return res
|
|
@@ -537,8 +663,8 @@ module Killbill
|
|
|
537
663
|
end
|
|
538
664
|
end
|
|
539
665
|
|
|
540
|
-
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchPaymentMethods(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
541
|
-
def search_payment_methods(searchKey, offset, limit, context)
|
|
666
|
+
java_signature 'Java::org.killbill.billing.util.entity.Pagination searchPaymentMethods(Java::java.lang.String, Java::java.lang.Long, Java::java.lang.Long, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.TenantContext)'
|
|
667
|
+
def search_payment_methods(searchKey, offset, limit, properties, context)
|
|
542
668
|
|
|
543
669
|
# conversion for searchKey [type = java.lang.String]
|
|
544
670
|
searchKey = searchKey.to_s unless searchKey.nil?
|
|
@@ -549,16 +675,25 @@ module Killbill
|
|
|
549
675
|
# conversion for limit [type = java.lang.Long]
|
|
550
676
|
limit = limit
|
|
551
677
|
|
|
678
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
679
|
+
tmp = java.util.ArrayList.new
|
|
680
|
+
(properties || []).each do |m|
|
|
681
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
682
|
+
m = m.to_java unless m.nil?
|
|
683
|
+
tmp.add(m)
|
|
684
|
+
end
|
|
685
|
+
properties = tmp
|
|
686
|
+
|
|
552
687
|
# conversion for context [type = org.killbill.billing.util.callcontext.TenantContext]
|
|
553
688
|
context = context.to_java unless context.nil?
|
|
554
|
-
res = @real_java_api.search_payment_methods(searchKey, offset, limit, context)
|
|
689
|
+
res = @real_java_api.search_payment_methods(searchKey, offset, limit, properties, context)
|
|
555
690
|
# conversion for res [type = org.killbill.billing.util.entity.Pagination]
|
|
556
691
|
res = Killbill::Plugin::Model::Pagination.new.to_ruby(res) unless res.nil?
|
|
557
692
|
return res
|
|
558
693
|
end
|
|
559
694
|
|
|
560
|
-
java_signature 'Java::void deletedPaymentMethod(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::boolean, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
561
|
-
def deleted_payment_method(account, paymentMethodId, deleteDefaultPaymentMethodWithAutoPayOff, context)
|
|
695
|
+
java_signature 'Java::void deletedPaymentMethod(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::boolean, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
696
|
+
def deleted_payment_method(account, paymentMethodId, deleteDefaultPaymentMethodWithAutoPayOff, properties, context)
|
|
562
697
|
|
|
563
698
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
564
699
|
account = account.to_java unless account.nil?
|
|
@@ -569,13 +704,22 @@ module Killbill
|
|
|
569
704
|
# conversion for deleteDefaultPaymentMethodWithAutoPayOff [type = boolean]
|
|
570
705
|
deleteDefaultPaymentMethodWithAutoPayOff = deleteDefaultPaymentMethodWithAutoPayOff.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(deleteDefaultPaymentMethodWithAutoPayOff)
|
|
571
706
|
|
|
707
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
708
|
+
tmp = java.util.ArrayList.new
|
|
709
|
+
(properties || []).each do |m|
|
|
710
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
711
|
+
m = m.to_java unless m.nil?
|
|
712
|
+
tmp.add(m)
|
|
713
|
+
end
|
|
714
|
+
properties = tmp
|
|
715
|
+
|
|
572
716
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
573
717
|
context = context.to_java unless context.nil?
|
|
574
|
-
@real_java_api.deleted_payment_method(account, paymentMethodId, deleteDefaultPaymentMethodWithAutoPayOff, context)
|
|
718
|
+
@real_java_api.deleted_payment_method(account, paymentMethodId, deleteDefaultPaymentMethodWithAutoPayOff, properties, context)
|
|
575
719
|
end
|
|
576
720
|
|
|
577
|
-
java_signature 'Java::void setDefaultPaymentMethod(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
578
|
-
def set_default_payment_method(account, paymentMethodId, context)
|
|
721
|
+
java_signature 'Java::void setDefaultPaymentMethod(Java::org.killbill.billing.account.api.Account, Java::java.util.UUID, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
722
|
+
def set_default_payment_method(account, paymentMethodId, properties, context)
|
|
579
723
|
|
|
580
724
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
581
725
|
account = account.to_java unless account.nil?
|
|
@@ -583,13 +727,22 @@ module Killbill
|
|
|
583
727
|
# conversion for paymentMethodId [type = java.util.UUID]
|
|
584
728
|
paymentMethodId = java.util.UUID.fromString(paymentMethodId.to_s) unless paymentMethodId.nil?
|
|
585
729
|
|
|
730
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
731
|
+
tmp = java.util.ArrayList.new
|
|
732
|
+
(properties || []).each do |m|
|
|
733
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
734
|
+
m = m.to_java unless m.nil?
|
|
735
|
+
tmp.add(m)
|
|
736
|
+
end
|
|
737
|
+
properties = tmp
|
|
738
|
+
|
|
586
739
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
587
740
|
context = context.to_java unless context.nil?
|
|
588
|
-
@real_java_api.set_default_payment_method(account, paymentMethodId, context)
|
|
741
|
+
@real_java_api.set_default_payment_method(account, paymentMethodId, properties, context)
|
|
589
742
|
end
|
|
590
743
|
|
|
591
|
-
java_signature 'Java::java.util.List refreshPaymentMethods(Java::java.lang.String, Java::org.killbill.billing.account.api.Account, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
592
|
-
def refresh_payment_methods(pluginName, account, context)
|
|
744
|
+
java_signature 'Java::java.util.List refreshPaymentMethods(Java::java.lang.String, Java::org.killbill.billing.account.api.Account, Java::java.lang.Iterable, Java::org.killbill.billing.util.callcontext.CallContext)'
|
|
745
|
+
def refresh_payment_methods(pluginName, account, properties, context)
|
|
593
746
|
|
|
594
747
|
# conversion for pluginName [type = java.lang.String]
|
|
595
748
|
pluginName = pluginName.to_s unless pluginName.nil?
|
|
@@ -597,10 +750,19 @@ module Killbill
|
|
|
597
750
|
# conversion for account [type = org.killbill.billing.account.api.Account]
|
|
598
751
|
account = account.to_java unless account.nil?
|
|
599
752
|
|
|
753
|
+
# conversion for properties [type = java.lang.Iterable]
|
|
754
|
+
tmp = java.util.ArrayList.new
|
|
755
|
+
(properties || []).each do |m|
|
|
756
|
+
# conversion for m [type = org.killbill.billing.payment.api.PluginProperty]
|
|
757
|
+
m = m.to_java unless m.nil?
|
|
758
|
+
tmp.add(m)
|
|
759
|
+
end
|
|
760
|
+
properties = tmp
|
|
761
|
+
|
|
600
762
|
# conversion for context [type = org.killbill.billing.util.callcontext.CallContext]
|
|
601
763
|
context = context.to_java unless context.nil?
|
|
602
764
|
begin
|
|
603
|
-
res = @real_java_api.refresh_payment_methods(pluginName, account, context)
|
|
765
|
+
res = @real_java_api.refresh_payment_methods(pluginName, account, properties, context)
|
|
604
766
|
# conversion for res [type = java.util.List]
|
|
605
767
|
tmp = []
|
|
606
768
|
(res || []).each do |m|
|