killbill 1.8.2 → 1.8.3

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.
data/Jarfile CHANGED
@@ -1,6 +1,6 @@
1
- jar 'com.ning.billing:killbill-api', '0.7.3'
2
- jar 'com.ning.billing.plugin:killbill-plugin-api-notification', '0.6.0'
3
- jar 'com.ning.billing.plugin:killbill-plugin-api-payment', '0.6.0'
4
- jar 'com.ning.billing.plugin:killbill-plugin-api-currency', '0.6.0'
1
+ jar 'com.ning.billing:killbill-api', '0.7.4'
2
+ jar 'com.ning.billing.plugin:killbill-plugin-api-notification', '0.6.1'
3
+ jar 'com.ning.billing.plugin:killbill-plugin-api-payment', '0.6.1'
4
+ jar 'com.ning.billing.plugin:killbill-plugin-api-currency', '0.6.1'
5
5
  jar 'com.ning.billing:killbill-util:tests', '0.7.0'
6
6
  jar 'javax.servlet:javax.servlet-api', '3.0.1'
data/NEWS CHANGED
@@ -1,3 +1,6 @@
1
+ 1.8.3
2
+ Regenerate models for currency conversion api changes
3
+
1
4
  1.8.2
2
5
  Add missing regenerated RefundInfoPlugin and PaymentInfoPlugin for new currency
3
6
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.8.2
1
+ 1.8.3
@@ -32,42 +32,40 @@ module Killbill
32
32
 
33
33
  include com.ning.billing.currency.api.CurrencyConversion
34
34
 
35
- attr_accessor :conversion_date, :base_currency, :rates
35
+ attr_accessor :base_currency, :rates
36
36
 
37
37
  def initialize()
38
38
  end
39
39
 
40
40
  def to_java()
41
- # conversion for conversion_date [type = org.joda.time.DateTime]
42
- if !@conversion_date.nil?
43
- @conversion_date = (@conversion_date.kind_of? Time) ? DateTime.parse(@conversion_date.to_s) : @conversion_date
44
- @conversion_date = Java::org.joda.time.DateTime.new(@conversion_date.to_s, Java::org.joda.time.DateTimeZone::UTC)
45
- end
46
-
47
41
  # conversion for base_currency [type = com.ning.billing.catalog.api.Currency]
48
42
  @base_currency = Java::com.ning.billing.catalog.api.Currency.value_of("#{@base_currency.to_s}") unless @base_currency.nil?
49
43
 
50
- # conversion for rates [type = com.ning.billing.currency.api.Rates]
51
- @rates = @rates.to_java unless @rates.nil?
44
+ # conversion for rates [type = java.util.Set]
45
+ tmp = java.util.TreeSet.new
46
+ (@rates || []).each do |m|
47
+ # conversion for m [type = com.ning.billing.currency.api.Rate]
48
+ m = m.to_java unless m.nil?
49
+ tmp.add(m)
50
+ end
51
+ @rates = tmp
52
52
  self
53
53
  end
54
54
 
55
55
  def to_ruby(j_obj)
56
- # conversion for conversion_date [type = org.joda.time.DateTime]
57
- @conversion_date = j_obj.conversion_date
58
- if !@conversion_date.nil?
59
- fmt = Java::org.joda.time.format.ISODateTimeFormat.date_time
60
- str = fmt.print(@conversion_date)
61
- @conversion_date = DateTime.iso8601(str)
62
- end
63
-
64
56
  # conversion for base_currency [type = com.ning.billing.catalog.api.Currency]
65
57
  @base_currency = j_obj.base_currency
66
58
  @base_currency = @base_currency.to_s.to_sym unless @base_currency.nil?
67
59
 
68
- # conversion for rates [type = com.ning.billing.currency.api.Rates]
60
+ # conversion for rates [type = java.util.Set]
69
61
  @rates = j_obj.rates
70
- @rates = Killbill::Plugin::Model::Rates.new.to_ruby(@rates) unless @rates.nil?
62
+ tmp = []
63
+ (@rates || []).each do |m|
64
+ # conversion for m [type = com.ning.billing.currency.api.Rate]
65
+ m = Killbill::Plugin::Model::Rate.new.to_ruby(m) unless m.nil?
66
+ tmp << m
67
+ end
68
+ @rates = tmp
71
69
  self
72
70
  end
73
71
 
@@ -27,10 +27,10 @@ module Killbill
27
27
  module Plugin
28
28
  module Model
29
29
 
30
- java_package 'com.ning.billing.currency.plugin.api'
30
+ java_package 'com.ning.billing.currency.api'
31
31
  class Rate
32
32
 
33
- include com.ning.billing.currency.plugin.api.Rate
33
+ include com.ning.billing.currency.api.Rate
34
34
 
35
35
  attr_accessor :base_currency, :currency, :value, :conversion_date
36
36
 
@@ -55,7 +55,7 @@ require 'killbill/gen/api/unit'
55
55
  require 'killbill/gen/api/currency_conversion'
56
56
  require 'killbill/gen/api/currency_conversion_api'
57
57
  require 'killbill/gen/api/currency_conversion_exception'
58
- require 'killbill/gen/api/rates'
58
+ require 'killbill/gen/api/rate'
59
59
  require 'killbill/gen/api/blockable'
60
60
  require 'killbill/gen/api/blocking_api_exception'
61
61
  require 'killbill/gen/api/blocking_state'
@@ -128,7 +128,7 @@ module Killbill
128
128
  # conversion for res [type = java.util.Set]
129
129
  tmp = java.util.TreeSet.new
130
130
  (res || []).each do |m|
131
- # conversion for m [type = com.ning.billing.currency.plugin.api.Rate]
131
+ # conversion for m [type = com.ning.billing.currency.api.Rate]
132
132
  m = m.to_java unless m.nil?
133
133
  tmp.add(m)
134
134
  end
@@ -163,7 +163,7 @@ module Killbill
163
163
  # conversion for res [type = java.util.Set]
164
164
  tmp = java.util.TreeSet.new
165
165
  (res || []).each do |m|
166
- # conversion for m [type = com.ning.billing.currency.plugin.api.Rate]
166
+ # conversion for m [type = com.ning.billing.currency.api.Rate]
167
167
  m = m.to_java unless m.nil?
168
168
  tmp.add(m)
169
169
  end
@@ -29,6 +29,5 @@ require 'killbill/gen/plugin-api/payment_plugin_api_exception'
29
29
  require 'killbill/gen/plugin-api/ext_bus_event'
30
30
  require 'killbill/gen/plugin-api/notification_plugin_api'
31
31
  require 'killbill/gen/plugin-api/currency_plugin_api'
32
- require 'killbill/gen/plugin-api/rate'
33
32
  require 'killbill/gen/plugin-api/payment_info_plugin'
34
33
  require 'killbill/gen/plugin-api/refund_info_plugin'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: killbill
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.2
4
+ version: 1.8.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-10-28 00:00:00.000000000 Z
12
+ date: 2013-10-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: sinatra
@@ -194,7 +194,7 @@ files:
194
194
  - lib/killbill/gen/api/price_list.rb
195
195
  - lib/killbill/gen/api/price_list_set.rb
196
196
  - lib/killbill/gen/api/product.rb
197
- - lib/killbill/gen/api/rates.rb
197
+ - lib/killbill/gen/api/rate.rb
198
198
  - lib/killbill/gen/api/record_id_api.rb
199
199
  - lib/killbill/gen/api/refund.rb
200
200
  - lib/killbill/gen/api/require_gen.rb
@@ -227,7 +227,6 @@ files:
227
227
  - lib/killbill/gen/plugin-api/payment_method_info_plugin.rb
228
228
  - lib/killbill/gen/plugin-api/payment_plugin_api.rb
229
229
  - lib/killbill/gen/plugin-api/payment_plugin_api_exception.rb
230
- - lib/killbill/gen/plugin-api/rate.rb
231
230
  - lib/killbill/gen/plugin-api/refund_info_plugin.rb
232
231
  - lib/killbill/gen/plugin-api/require_gen.rb
233
232
  - lib/killbill/http_servlet.rb
@@ -1,79 +0,0 @@
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 'com.ning.billing.currency.api'
31
- class Rates
32
-
33
- include com.ning.billing.currency.api.Rates
34
-
35
- attr_accessor :currencies, :rate
36
-
37
- def initialize()
38
- end
39
-
40
- def to_java()
41
- # conversion for currencies [type = java.util.Set]
42
- tmp = java.util.TreeSet.new
43
- (@currencies || []).each do |m|
44
- # conversion for m [type = com.ning.billing.catalog.api.Currency]
45
- m = Java::com.ning.billing.catalog.api.Currency.value_of("#{m.to_s}") unless m.nil?
46
- tmp.add(m)
47
- end
48
- @currencies = tmp
49
-
50
- # conversion for rate [type = java.math.BigDecimal]
51
- if @rate.nil?
52
- @rate = java.math.BigDecimal::ZERO
53
- else
54
- @rate = java.math.BigDecimal.new(@rate.to_s)
55
- end
56
- self
57
- end
58
-
59
- def to_ruby(j_obj)
60
- # conversion for currencies [type = java.util.Set]
61
- @currencies = j_obj.currencies
62
- tmp = []
63
- (@currencies || []).each do |m|
64
- # conversion for m [type = com.ning.billing.catalog.api.Currency]
65
- m = m.to_s.to_sym unless m.nil?
66
- tmp << m
67
- end
68
- @currencies = tmp
69
-
70
- # conversion for rate [type = java.math.BigDecimal]
71
- @rate = j_obj.rate
72
- @rate = @rate.nil? ? 0 : BigDecimal.new(@rate.to_s)
73
- self
74
- end
75
-
76
- end
77
- end
78
- end
79
- end