Class: Bandwidth::TwoFactorCodeRequestSchema
- Defined in:
- lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb
Overview
TwoFactorCodeRequestSchema Model.
Instance Attribute Summary collapse
-
#application_id ⇒ String
TODO: Write general description for this method.
-
#from ⇒ String
TODO: Write general description for this method.
-
#scope ⇒ String
TODO: Write general description for this method.
-
#to ⇒ String
TODO: Write general description for this method.
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.
Instance Method Summary collapse
-
#initialize(to = nil, from = nil, application_id = nil, scope = nil) ⇒ TwoFactorCodeRequestSchema
constructor
A new instance of TwoFactorCodeRequestSchema.
Methods inherited from BaseModel
Constructor Details
#initialize(to = nil, from = nil, application_id = nil, scope = nil) ⇒ TwoFactorCodeRequestSchema
Returns a new instance of TwoFactorCodeRequestSchema.
35 36 37 38 39 40 41 42 43 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 35 def initialize(to = nil, from = nil, application_id = nil, scope = nil) @to = to @from = from @application_id = application_id @scope = scope end |
Instance Attribute Details
#application_id ⇒ String
TODO: Write general description for this method
19 20 21 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 19 def application_id @application_id end |
#from ⇒ String
TODO: Write general description for this method
15 16 17 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 15 def from @from end |
#scope ⇒ String
TODO: Write general description for this method
23 24 25 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 23 def scope @scope end |
#to ⇒ String
TODO: Write general description for this method
11 12 13 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 11 def to @to end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 46 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. to = hash['to'] from = hash['from'] application_id = hash['applicationId'] scope = hash['scope'] # Create object from extracted values. TwoFactorCodeRequestSchema.new(to, from, application_id, scope) end |
.names ⇒ Object
A mapping from model property names to API property names.
26 27 28 29 30 31 32 33 |
# File 'lib/bandwidth/two_factor_auth_lib/two_factor_auth/models/two_factor_code_request_schema.rb', line 26 def self.names @_hash = {} if @_hash.nil? @_hash['to'] = 'to' @_hash['from'] = 'from' @_hash['application_id'] = 'applicationId' @_hash['scope'] = 'scope' @_hash end |