Class: Verizon::FotaV1CallbackRegistrationRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- Verizon::FotaV1CallbackRegistrationRequest
- Defined in:
- lib/verizon/models/fota_v1_callback_registration_request.rb
Overview
Callback endpoint information.
Instance Attribute Summary collapse
-
#name ⇒ String
The name of the callback service that you want to subscribe to, which must be ‘Fota’ for Software Management Services callbacks.
-
#password ⇒ String
The password that ThingSpace should return in the callback messages.
-
#url ⇒ String
The address on your server where you have enabled a listening service for Software Management Services callback messages.
-
#username ⇒ String
The user name that ThingSpace should return in the callback messages.
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(name = nil, url = nil, username = SKIP, password = SKIP) ⇒ FotaV1CallbackRegistrationRequest
constructor
A new instance of FotaV1CallbackRegistrationRequest.
Methods inherited from BaseModel
Constructor Details
#initialize(name = nil, url = nil, username = SKIP, password = SKIP) ⇒ FotaV1CallbackRegistrationRequest
Returns a new instance of FotaV1CallbackRegistrationRequest.
53 54 55 56 57 58 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 53 def initialize(name = nil, url = nil, username = SKIP, password = SKIP) @name = name @url = url @username = username unless username == SKIP @password = password unless password == SKIP end |
Instance Attribute Details
#name ⇒ String
The name of the callback service that you want to subscribe to, which must be ‘Fota’ for Software Management Services callbacks.
15 16 17 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 15 def name @name end |
#password ⇒ String
The password that ThingSpace should return in the callback messages.
28 29 30 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 28 def password @password end |
#url ⇒ String
The address on your server where you have enabled a listening service for Software Management Services callback messages.
20 21 22 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 20 def url @url end |
#username ⇒ String
The user name that ThingSpace should return in the callback messages.
24 25 26 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 24 def username @username end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 61 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. name = hash.key?('name') ? hash['name'] : nil url = hash.key?('url') ? hash['url'] : nil username = hash.key?('username') ? hash['username'] : SKIP password = hash.key?('password') ? hash['password'] : SKIP # Create object from extracted values. FotaV1CallbackRegistrationRequest.new(name, url, username, password) end |
.names ⇒ Object
A mapping from model property names to API property names.
31 32 33 34 35 36 37 38 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 31 def self.names @_hash = {} if @_hash.nil? @_hash['name'] = 'name' @_hash['url'] = 'url' @_hash['username'] = 'username' @_hash['password'] = 'password' @_hash end |
.nullables ⇒ Object
An array for nullable fields
49 50 51 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 49 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
41 42 43 44 45 46 |
# File 'lib/verizon/models/fota_v1_callback_registration_request.rb', line 41 def self.optionals %w[ username password ] end |