Module: DInstaller::DBus::Question::Interfaces::LuksActivation
- Defined in:
- lib/dinstaller/dbus/question.rb
Overview
Interface to provide information when activating a LUKS device
Class Method Summary collapse
Instance Method Summary collapse
-
#activation_attempt ⇒ Integer
Current attempt for activating the device.
- #backend ⇒ DInstaller::Question
-
#luks_password ⇒ String
Given password.
-
#luks_password=(value) ⇒ Object
Sets a password.
Class Method Details
.included(base) ⇒ Object
136 137 138 139 140 141 142 143 |
# File 'lib/dinstaller/dbus/question.rb', line 136 def self.included(base) base.class_eval do dbus_interface LUKS_ACTIVATION_INTERFACE do dbus_accessor :luks_password, "s", dbus_name: "Password" dbus_reader :activation_attempt, "u", dbus_name: "Attempt" end end end |
Instance Method Details
#activation_attempt ⇒ Integer
Current attempt for activating the device
132 133 134 |
# File 'lib/dinstaller/dbus/question.rb', line 132 def activation_attempt backend.attempt end |
#backend ⇒ DInstaller::Question
Note:
Classes including this mixin must define a #backend method
|
# File 'lib/dinstaller/dbus/question.rb', line 111
|
#luks_password ⇒ String
Given password
118 119 120 |
# File 'lib/dinstaller/dbus/question.rb', line 118 def luks_password backend.password || "" end |
#luks_password=(value) ⇒ Object
Sets a password
125 126 127 |
# File 'lib/dinstaller/dbus/question.rb', line 125 def luks_password=(value) backend.password = value end |