class Cryptopay::ChannelUpdateParams
Constants
- ENCODER
Public Class Methods
build_from_hash(data)
click to toggle source
Builds the object from hash @param [Hash] attributes Model attributes in the form of hash @return [Cryptopay::ChannelUpdateParams] Returns the model itself
# File lib/cryptopay/models/channel_update_params.rb, line 70 def self.build_from_hash(data) attributes = ENCODER.build_from_hash(data) new(attributes) end
new(attributes = {})
click to toggle source
Initializes the object @param [Hash] attributes Model attributes in the form of hash
# File lib/cryptopay/models/channel_update_params.rb, line 28 def initialize(attributes = {}) @attributes = ENCODER.sanitize(attributes) end
Public Instance Methods
customer_id()
click to toggle source
The internal ID of your customer that the channel relates to
# File lib/cryptopay/models/channel_update_params.rb, line 45 def customer_id @attributes[:customer_id] end
description()
click to toggle source
# File lib/cryptopay/models/channel_update_params.rb, line 36 def description @attributes[:description] end
inspect()
click to toggle source
# File lib/cryptopay/models/channel_update_params.rb, line 81 def inspect "#<#{self.class}:0x#{object_id.to_s(16)}> JSON: " + JSON.pretty_generate(to_hash) end
invalid_properties()
click to toggle source
Show invalid properties with the reasons. Usually used together with valid? @return Array for valid properties with the reasons
# File lib/cryptopay/models/channel_update_params.rb, line 51 def invalid_properties properties = [] if !status.nil? && !%w[enabled disabled].include?(status) properties.push('invalid value for status, must be one of "enabled", "disabled"') end properties end
name()
click to toggle source
# File lib/cryptopay/models/channel_update_params.rb, line 32 def name @attributes[:name] end
status()
click to toggle source
# File lib/cryptopay/models/channel_update_params.rb, line 40 def status @attributes[:status] end
to_hash()
click to toggle source
Returns the object in the form of hash @return [Hash] Returns the object in the form of hash
# File lib/cryptopay/models/channel_update_params.rb, line 77 def to_hash ENCODER.to_hash(@attributes) end
valid?()
click to toggle source
Check to see if the all the properties in the model are valid @return true if the model is valid
# File lib/cryptopay/models/channel_update_params.rb, line 63 def valid? invalid_properties.empty? end