Class: KrakenMobile::Models::Device

Inherits:
Object
  • Object
show all
Defined in:
lib/kraken-mobile/models/device.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, model, position, config = {}) ⇒ Device


Constructors




16
17
18
19
20
21
# File 'lib/kraken-mobile/models/device.rb', line 16

def initialize(id, model, position, config = {})
	@id = id
	@model = model
     @position = position
     @config = config
end

Instance Attribute Details

#configObject

Returns the value of attribute config.



11
12
13
# File 'lib/kraken-mobile/models/device.rb', line 11

def config
  @config
end

#idObject


Fields




8
9
10
# File 'lib/kraken-mobile/models/device.rb', line 8

def id
  @id
end

#modelObject

Returns the value of attribute model.



9
10
11
# File 'lib/kraken-mobile/models/device.rb', line 9

def model
  @model
end

#positionObject

Returns the value of attribute position.



10
11
12
# File 'lib/kraken-mobile/models/device.rb', line 10

def position
  @position
end

Instance Method Details

#screenshot_prefixObject


Helpers




26
27
28
# File 'lib/kraken-mobile/models/device.rb', line 26

def screenshot_prefix
	@id.gsub('.', '_').gsub(/:(.*)/, '').to_s + '_'
end