class Beaver::PhoneRbit
PhoneRbit
Model.
Attributes
country_code[RW]
TODO: Write general description for this method @return [String]
phone_number[RW]
TODO: Write general description for this method @return [String]
phone_type[RW]
TODO: Write general description for this method @return [PhoneTypeEnum]
Public Class Methods
from_hash(hash)
click to toggle source
Creates an instance of the object from a hash.
# File lib/beaver/models/phone_rbit.rb, line 39 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. country_code = hash['country_code'] phone_number = hash['phone_number'] phone_type = hash['phone_type'] # Create object from extracted values. PhoneRbit.new(country_code, phone_number, phone_type) end
names()
click to toggle source
A mapping from model property names to API property names.
# File lib/beaver/models/phone_rbit.rb, line 22 def self.names @_hash = {} if @_hash.nil? @_hash['country_code'] = 'country_code' @_hash['phone_number'] = 'phone_number' @_hash['phone_type'] = 'phone_type' @_hash end
new(country_code = nil, phone_number = nil, phone_type = nil)
click to toggle source
# File lib/beaver/models/phone_rbit.rb, line 30 def initialize(country_code = nil, phone_number = nil, phone_type = nil) @country_code = country_code @phone_number = phone_number @phone_type = phone_type end