Module: Appium::Core::Base::Device::DeviceLock

Defined in:
lib/appium_lib_core/common/device/device_lock.rb

Instance Method Summary collapse

Instance Method Details

#device_locked?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'lib/appium_lib_core/common/device/device_lock.rb', line 25

def device_locked?
  execute :device_locked?
end

#lock(duration = nil) ⇒ Object



20
21
22
23
# File 'lib/appium_lib_core/common/device/device_lock.rb', line 20

def lock(duration = nil)
  opts = duration ? { seconds: duration } : {}
  execute :lock, {}, opts
end

#unlockObject



29
30
31
# File 'lib/appium_lib_core/common/device/device_lock.rb', line 29

def unlock
  execute :unlock
end