Class: StickyIoRestfulApiV2025731::GetUnassignedProductLicenseKeys
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- StickyIoRestfulApiV2025731::GetUnassignedProductLicenseKeys
- Defined in:
- lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb
Overview
GetUnassignedProductLicenseKeys Model.
Instance Attribute Summary collapse
-
#current_page ⇒ Integer
TODO: Write general description for this method.
-
#data ⇒ Array[DataGetUnassignedProductLicenseKeys]
TODO: Write general description for this method.
-
#first_page_url ⇒ String
TODO: Write general description for this method.
-
#from ⇒ Integer
TODO: Write general description for this method.
-
#last_page ⇒ Integer
TODO: Write general description for this method.
-
#last_page_url ⇒ String
TODO: Write general description for this method.
-
#next_page_url ⇒ String
TODO: Write general description for this method.
-
#path ⇒ String
TODO: Write general description for this method.
-
#per_page ⇒ Integer
TODO: Write general description for this method.
-
#prev_page_url ⇒ String
TODO: Write general description for this method.
-
#status ⇒ String
TODO: Write general description for this method.
-
#to ⇒ Integer
TODO: Write general description for this method.
-
#total ⇒ Integer
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.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(status:, current_page:, data:, first_page_url:, from:, last_page:, last_page_url:, next_page_url:, path:, per_page:, prev_page_url:, to:, total:, additional_properties: nil) ⇒ GetUnassignedProductLicenseKeys
constructor
A new instance of GetUnassignedProductLicenseKeys.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(status:, current_page:, data:, first_page_url:, from:, last_page:, last_page_url:, next_page_url:, path:, per_page:, prev_page_url:, to:, total:, additional_properties: nil) ⇒ GetUnassignedProductLicenseKeys
Returns a new instance of GetUnassignedProductLicenseKeys.
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 96 def initialize(status:, current_page:, data:, first_page_url:, from:, last_page:, last_page_url:, next_page_url:, path:, per_page:, prev_page_url:, to:, total:, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @status = status @current_page = current_page @data = data @first_page_url = first_page_url @from = from @last_page = last_page @last_page_url = last_page_url @next_page_url = next_page_url @path = path @per_page = per_page @prev_page_url = prev_page_url @to = to @total = total @additional_properties = additional_properties end |
Instance Attribute Details
#current_page ⇒ Integer
TODO: Write general description for this method
18 19 20 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 18 def current_page @current_page end |
#data ⇒ Array[DataGetUnassignedProductLicenseKeys]
TODO: Write general description for this method
22 23 24 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 22 def data @data end |
#first_page_url ⇒ String
TODO: Write general description for this method
26 27 28 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 26 def first_page_url @first_page_url end |
#from ⇒ Integer
TODO: Write general description for this method
30 31 32 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 30 def from @from end |
#last_page ⇒ Integer
TODO: Write general description for this method
34 35 36 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 34 def last_page @last_page end |
#last_page_url ⇒ String
TODO: Write general description for this method
38 39 40 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 38 def last_page_url @last_page_url end |
#next_page_url ⇒ String
TODO: Write general description for this method
42 43 44 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 42 def next_page_url @next_page_url end |
#path ⇒ String
TODO: Write general description for this method
46 47 48 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 46 def path @path end |
#per_page ⇒ Integer
TODO: Write general description for this method
50 51 52 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 50 def per_page @per_page end |
#prev_page_url ⇒ String
TODO: Write general description for this method
54 55 56 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 54 def prev_page_url @prev_page_url end |
#status ⇒ String
TODO: Write general description for this method
14 15 16 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 14 def status @status end |
#to ⇒ Integer
TODO: Write general description for this method
58 59 60 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 58 def to @to end |
#total ⇒ Integer
TODO: Write general description for this method
62 63 64 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 62 def total @total end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 119 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. status = hash.key?('status') ? hash['status'] : nil current_page = hash.key?('current_page') ? hash['current_page'] : nil # Parameter is an array, so we need to iterate through it data = nil unless hash['data'].nil? data = [] hash['data'].each do |structure| data << (DataGetUnassignedProductLicenseKeys.from_hash(structure) if structure) end end data = nil unless hash.key?('data') first_page_url = hash.key?('first_page_url') ? hash['first_page_url'] : nil from = hash.key?('from') ? hash['from'] : nil last_page = hash.key?('last_page') ? hash['last_page'] : nil last_page_url = hash.key?('last_page_url') ? hash['last_page_url'] : nil next_page_url = hash.key?('next_page_url') ? hash['next_page_url'] : nil path = hash.key?('path') ? hash['path'] : nil per_page = hash.key?('per_page') ? hash['per_page'] : nil prev_page_url = hash.key?('prev_page_url') ? hash['prev_page_url'] : nil to = hash.key?('to') ? hash['to'] : nil total = hash.key?('total') ? hash['total'] : nil # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. GetUnassignedProductLicenseKeys.new(status: status, current_page: current_page, data: data, first_page_url: first_page_url, from: from, last_page: last_page, last_page_url: last_page_url, next_page_url: next_page_url, path: path, per_page: per_page, prev_page_url: prev_page_url, to: to, total: total, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 65 def self.names @_hash = {} if @_hash.nil? @_hash['status'] = 'status' @_hash['current_page'] = 'current_page' @_hash['data'] = 'data' @_hash['first_page_url'] = 'first_page_url' @_hash['from'] = 'from' @_hash['last_page'] = 'last_page' @_hash['last_page_url'] = 'last_page_url' @_hash['next_page_url'] = 'next_page_url' @_hash['path'] = 'path' @_hash['per_page'] = 'per_page' @_hash['prev_page_url'] = 'prev_page_url' @_hash['to'] = 'to' @_hash['total'] = 'total' @_hash end |
.nullables ⇒ Object
An array for nullable fields
89 90 91 92 93 94 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 89 def self.nullables %w[ next_page_url prev_page_url ] end |
.optionals ⇒ Object
An array for optional fields
84 85 86 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 84 def self.optionals [] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
182 183 184 185 186 187 188 189 190 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 182 def inspect class_name = self.class.name.split('::').last "<#{class_name} status: #{@status.inspect}, current_page: #{@current_page.inspect}, data:"\ " #{@data.inspect}, first_page_url: #{@first_page_url.inspect}, from: #{@from.inspect},"\ " last_page: #{@last_page.inspect}, last_page_url: #{@last_page_url.inspect}, next_page_url:"\ " #{@next_page_url.inspect}, path: #{@path.inspect}, per_page: #{@per_page.inspect},"\ " prev_page_url: #{@prev_page_url.inspect}, to: #{@to.inspect}, total: #{@total.inspect},"\ " additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
172 173 174 175 176 177 178 179 |
# File 'lib/sticky_io_restful_api_v2025731/models/get_unassigned_product_license_keys.rb', line 172 def to_s class_name = self.class.name.split('::').last "<#{class_name} status: #{@status}, current_page: #{@current_page}, data: #{@data},"\ " first_page_url: #{@first_page_url}, from: #{@from}, last_page: #{@last_page},"\ " last_page_url: #{@last_page_url}, next_page_url: #{@next_page_url}, path: #{@path},"\ " per_page: #{@per_page}, prev_page_url: #{@prev_page_url}, to: #{@to}, total: #{@total},"\ " additional_properties: #{@additional_properties}>" end |