Class: MistApi::MapJibestream

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/mist_api/models/map_jibestream.rb

Overview

MapJibestream Model.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json

Constructor Details

#initialize(client_id = nil, client_secret = nil, customer_id = nil, endpoint_url = nil, map_id = nil, mmpp = nil, ppm = nil, venue_id = nil) ⇒ MapJibestream

Returns a new instance of MapJibestream.



73
74
75
76
77
78
79
80
81
82
83
84
85
# File 'lib/mist_api/models/map_jibestream.rb', line 73

def initialize(client_id = nil, client_secret = nil, customer_id = nil,
               endpoint_url = nil, map_id = nil, mmpp = nil, ppm = nil,
               venue_id = nil)
  @client_id = client_id
  @client_secret = client_secret
  @customer_id = customer_id
  @endpoint_url = endpoint_url
  @map_id = map_id
  @mmpp = mmpp
  @ppm = ppm
  @vendor_name = 'jibestream'
  @venue_id = venue_id
end

Instance Attribute Details

#client_idUUID | String

Client id

Returns:

  • (UUID | String)


14
15
16
# File 'lib/mist_api/models/map_jibestream.rb', line 14

def client_id
  @client_id
end

#client_secretString

Client secret

Returns:

  • (String)


18
19
20
# File 'lib/mist_api/models/map_jibestream.rb', line 18

def client_secret
  @client_secret
end

#customer_idInteger

Jibestream customer record id

Returns:

  • (Integer)


22
23
24
# File 'lib/mist_api/models/map_jibestream.rb', line 22

def customer_id
  @customer_id
end

#endpoint_urlString

Map contents endpoint host

Returns:

  • (String)


26
27
28
# File 'lib/mist_api/models/map_jibestream.rb', line 26

def endpoint_url
  @endpoint_url
end

#map_idUUID | String

Jibestream map id

Returns:

  • (UUID | String)


30
31
32
# File 'lib/mist_api/models/map_jibestream.rb', line 30

def map_id
  @map_id
end

#mmppInteger

Millimeter per pixel

Returns:

  • (Integer)


34
35
36
# File 'lib/mist_api/models/map_jibestream.rb', line 34

def mmpp
  @mmpp
end

#ppmFloat

Pixel per meter, same as the map JSON value.

Returns:

  • (Float)


38
39
40
# File 'lib/mist_api/models/map_jibestream.rb', line 38

def ppm
  @ppm
end

#vendor_nameString (readonly)

The vendor ‘jibestream’. enum: ‘jibestream`

Returns:

  • (String)


42
43
44
# File 'lib/mist_api/models/map_jibestream.rb', line 42

def vendor_name
  @vendor_name
end

#venue_idInteger

Venue or organization id

Returns:

  • (Integer)


46
47
48
# File 'lib/mist_api/models/map_jibestream.rb', line 46

def venue_id
  @venue_id
end

Class Method Details

.from_hash(hash) ⇒ Object

Creates an instance of the object from a hash.



88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
# File 'lib/mist_api/models/map_jibestream.rb', line 88

def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  client_id = hash.key?('client_id') ? hash['client_id'] : nil
  client_secret = hash.key?('client_secret') ? hash['client_secret'] : nil
  customer_id = hash.key?('customer_id') ? hash['customer_id'] : nil
  endpoint_url = hash.key?('endpoint_url') ? hash['endpoint_url'] : nil
  map_id = hash.key?('map_id') ? hash['map_id'] : nil
  mmpp = hash.key?('mmpp') ? hash['mmpp'] : nil
  ppm = hash.key?('ppm') ? hash['ppm'] : nil
  venue_id = hash.key?('venue_id') ? hash['venue_id'] : nil

  # Create object from extracted values.
  MapJibestream.new(client_id,
                    client_secret,
                    customer_id,
                    endpoint_url,
                    map_id,
                    mmpp,
                    ppm,
                    venue_id)
end

.namesObject

A mapping from model property names to API property names.



49
50
51
52
53
54
55
56
57
58
59
60
61
# File 'lib/mist_api/models/map_jibestream.rb', line 49

def self.names
  @_hash = {} if @_hash.nil?
  @_hash['client_id'] = 'client_id'
  @_hash['client_secret'] = 'client_secret'
  @_hash['customer_id'] = 'customer_id'
  @_hash['endpoint_url'] = 'endpoint_url'
  @_hash['map_id'] = 'map_id'
  @_hash['mmpp'] = 'mmpp'
  @_hash['ppm'] = 'ppm'
  @_hash['vendor_name'] = 'vendor_name'
  @_hash['venue_id'] = 'venue_id'
  @_hash
end

.nullablesObject

An array for nullable fields



69
70
71
# File 'lib/mist_api/models/map_jibestream.rb', line 69

def self.nullables
  []
end

.optionalsObject

An array for optional fields



64
65
66
# File 'lib/mist_api/models/map_jibestream.rb', line 64

def self.optionals
  []
end

Instance Method Details

#inspectObject

Provides a debugging-friendly string with detailed object information.



121
122
123
124
125
126
127
# File 'lib/mist_api/models/map_jibestream.rb', line 121

def inspect
  class_name = self.class.name.split('::').last
  "<#{class_name} client_id: #{@client_id.inspect}, client_secret: #{@client_secret.inspect},"\
  " customer_id: #{@customer_id.inspect}, endpoint_url: #{@endpoint_url.inspect}, map_id:"\
  " #{@map_id.inspect}, mmpp: #{@mmpp.inspect}, ppm: #{@ppm.inspect}, vendor_name:"\
  " #{@vendor_name.inspect}, venue_id: #{@venue_id.inspect}>"
end

#to_sObject

Provides a human-readable string representation of the object.



113
114
115
116
117
118
# File 'lib/mist_api/models/map_jibestream.rb', line 113

def to_s
  class_name = self.class.name.split('::').last
  "<#{class_name} client_id: #{@client_id}, client_secret: #{@client_secret}, customer_id:"\
  " #{@customer_id}, endpoint_url: #{@endpoint_url}, map_id: #{@map_id}, mmpp: #{@mmpp}, ppm:"\
  " #{@ppm}, vendor_name: #{@vendor_name}, venue_id: #{@venue_id}>"
end