Class: PicasaDownloader::EnvCredentials
- Inherits:
-
Object
- Object
- PicasaDownloader::EnvCredentials
- Defined in:
- lib/picasa-downloader/env_credentials.rb
Instance Attribute Summary collapse
-
#password ⇒ Object
readonly
Returns the value of attribute password.
-
#username ⇒ Object
readonly
Returns the value of attribute username.
Instance Method Summary collapse
-
#initialize ⇒ EnvCredentials
constructor
A new instance of EnvCredentials.
- #is_configured? ⇒ Boolean
Constructor Details
#initialize ⇒ EnvCredentials
Returns a new instance of EnvCredentials.
5 6 7 8 |
# File 'lib/picasa-downloader/env_credentials.rb', line 5 def initialize @username = ENV['PICASA_USERNAME'] @password = ENV['PICASA_PASSWORD'] end |
Instance Attribute Details
#password ⇒ Object (readonly)
Returns the value of attribute password.
3 4 5 |
# File 'lib/picasa-downloader/env_credentials.rb', line 3 def password @password end |
#username ⇒ Object (readonly)
Returns the value of attribute username.
3 4 5 |
# File 'lib/picasa-downloader/env_credentials.rb', line 3 def username @username end |
Instance Method Details
#is_configured? ⇒ Boolean
10 11 12 13 |
# File 'lib/picasa-downloader/env_credentials.rb', line 10 def is_configured? ENV['PICASA_USERNAME'].to_s != '' && ENV['PICASA_PASSWORD'].to_s != '' end |