Class: Killbill::Plugin::Model::PaymentMethodPlugin
- Defined in:
- lib/killbill/gen/api/payment_method_plugin.rb
Instance Attribute Summary collapse
-
#external_payment_method_id ⇒ Object
Returns the value of attribute external_payment_method_id.
-
#is_default_payment_method ⇒ Object
Returns the value of attribute is_default_payment_method.
-
#kb_payment_method_id ⇒ Object
Returns the value of attribute kb_payment_method_id.
-
#properties ⇒ Object
Returns the value of attribute properties.
Instance Method Summary collapse
-
#initialize ⇒ PaymentMethodPlugin
constructor
A new instance of PaymentMethodPlugin.
- #to_java ⇒ Object
- #to_ruby(j_obj) ⇒ Object
Constructor Details
#initialize ⇒ PaymentMethodPlugin
Returns a new instance of PaymentMethodPlugin.
39 40 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 39 def initialize() end |
Instance Attribute Details
#external_payment_method_id ⇒ Object
Returns the value of attribute external_payment_method_id.
37 38 39 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 37 def external_payment_method_id @external_payment_method_id end |
#is_default_payment_method ⇒ Object
Returns the value of attribute is_default_payment_method.
37 38 39 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 37 def is_default_payment_method @is_default_payment_method end |
#kb_payment_method_id ⇒ Object
Returns the value of attribute kb_payment_method_id.
37 38 39 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 37 def kb_payment_method_id @kb_payment_method_id end |
#properties ⇒ Object
Returns the value of attribute properties.
37 38 39 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 37 def properties @properties end |
Instance Method Details
#to_java ⇒ Object
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 42 def to_java() # conversion for kb_payment_method_id [type = java.util.UUID] @kb_payment_method_id = java.util.UUID.fromString(@kb_payment_method_id.to_s) unless @kb_payment_method_id.nil? # conversion for external_payment_method_id [type = java.lang.String] @external_payment_method_id = @external_payment_method_id.to_s unless @external_payment_method_id.nil? # conversion for is_default_payment_method [type = boolean] @is_default_payment_method = @is_default_payment_method.nil? ? java.lang.Boolean.new(false) : java.lang.Boolean.new(@is_default_payment_method) # conversion for properties [type = java.util.List] tmp = java.util.ArrayList.new (@properties || []).each do |m| # conversion for m [type = org.killbill.billing.payment.api.PluginProperty] m = m.to_java unless m.nil? tmp.add(m) end @properties = tmp self end |
#to_ruby(j_obj) ⇒ Object
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/killbill/gen/api/payment_method_plugin.rb', line 63 def to_ruby(j_obj) # conversion for kb_payment_method_id [type = java.util.UUID] @kb_payment_method_id = j_obj.kb_payment_method_id @kb_payment_method_id = @kb_payment_method_id.nil? ? nil : @kb_payment_method_id.to_s # conversion for external_payment_method_id [type = java.lang.String] @external_payment_method_id = j_obj.external_payment_method_id # conversion for is_default_payment_method [type = boolean] @is_default_payment_method = j_obj.is_default_payment_method if @is_default_payment_method.nil? @is_default_payment_method = false else tmp_bool = (@is_default_payment_method.java_kind_of? java.lang.Boolean) ? @is_default_payment_method.boolean_value : @is_default_payment_method @is_default_payment_method = tmp_bool ? true : false end # conversion for properties [type = java.util.List] @properties = j_obj.properties tmp = [] (@properties || []).each do |m| # conversion for m [type = org.killbill.billing.payment.api.PluginProperty] m = Killbill::Plugin::Model::PluginProperty.new.to_ruby(m) unless m.nil? tmp << m end @properties = tmp self end |