Class: PwData
- Inherits:
-
Object
- Object
- PwData
- Defined in:
- lib/rbpw/pw_data.rb
Instance Attribute Summary collapse
-
#key ⇒ Object
Returns the value of attribute key.
Instance Method Summary collapse
- #get_json_value ⇒ Object
- #get_password ⇒ Object
- #get_username ⇒ Object
- #set_password(value) ⇒ Object
- #set_username(value) ⇒ Object
Instance Attribute Details
#key ⇒ Object
Returns the value of attribute key.
5 6 7 |
# File 'lib/rbpw/pw_data.rb', line 5 def key @key end |
Instance Method Details
#get_json_value ⇒ Object
27 28 29 30 31 32 |
# File 'lib/rbpw/pw_data.rb', line 27 def get_json_value hash = Hash.new hash.store(:username, @username) hash.store(:password, @password) hash.to_json end |
#get_password ⇒ Object
22 23 24 25 |
# File 'lib/rbpw/pw_data.rb', line 22 def get_password value = @password value end |
#get_username ⇒ Object
13 14 15 16 |
# File 'lib/rbpw/pw_data.rb', line 13 def get_username value = @username value end |
#set_password(value) ⇒ Object
18 19 20 |
# File 'lib/rbpw/pw_data.rb', line 18 def set_password(value) @password = value end |
#set_username(value) ⇒ Object
9 10 11 |
# File 'lib/rbpw/pw_data.rb', line 9 def set_username(value) @username = value end |