Class: Verizon::CallbackRegistered
- Defined in:
- lib/verizon/models/callback_registered.rb
Overview
Registered callback listener.
Instance Attribute Summary collapse
-
#account_name ⇒ String
The billing account number for which callback messages will be sent.
-
#name ⇒ String
The name of the callback service, which identifies the type and format of messages that will be sent to the registered URL.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(account_name = nil, name = nil) ⇒ CallbackRegistered
constructor
A new instance of CallbackRegistered.
Methods inherited from BaseModel
Constructor Details
#initialize(account_name = nil, name = nil) ⇒ CallbackRegistered
Returns a new instance of CallbackRegistered.
39 40 41 42 |
# File 'lib/verizon/models/callback_registered.rb', line 39 def initialize(account_name = nil, name = nil) @account_name = account_name @name = name end |
Instance Attribute Details
#account_name ⇒ String
The billing account number for which callback messages will be sent.
14 15 16 |
# File 'lib/verizon/models/callback_registered.rb', line 14 def account_name @account_name end |
#name ⇒ String
The name of the callback service, which identifies the type and format of messages that will be sent to the registered URL.
19 20 21 |
# File 'lib/verizon/models/callback_registered.rb', line 19 def name @name end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/verizon/models/callback_registered.rb', line 45 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. account_name = hash.key?('accountName') ? hash['accountName'] : nil name = hash.key?('name') ? hash['name'] : nil # Create object from extracted values. CallbackRegistered.new(account_name, name) end |
.names ⇒ Object
A mapping from model property names to API property names.
22 23 24 25 26 27 |
# File 'lib/verizon/models/callback_registered.rb', line 22 def self.names @_hash = {} if @_hash.nil? @_hash['account_name'] = 'accountName' @_hash['name'] = 'name' @_hash end |
.nullables ⇒ Object
An array for nullable fields
35 36 37 |
# File 'lib/verizon/models/callback_registered.rb', line 35 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
30 31 32 |
# File 'lib/verizon/models/callback_registered.rb', line 30 def self.optionals [] end |