Class: Fairdom::OpenbisApi::Authentication
- Inherits:
-
OpenbisQuery
- Object
- OpenbisQuery
- Fairdom::OpenbisApi::Authentication
- Defined in:
- lib/fairdom/openbis_api/authentication.rb
Instance Attribute Summary collapse
-
#as_endpoint ⇒ Object
readonly
Returns the value of attribute as_endpoint.
-
#password ⇒ Object
readonly
Returns the value of attribute password.
-
#username ⇒ Object
readonly
Returns the value of attribute username.
Attributes inherited from OpenbisQuery
Instance Method Summary collapse
- #execute_command(_options) ⇒ Object
-
#initialize(username, password, as_endpoint, is_test = false) ⇒ Authentication
constructor
A new instance of Authentication.
- #login ⇒ Object
- #root_command_options ⇒ Object
Methods inherited from OpenbisQuery
Constructor Details
#initialize(username, password, as_endpoint, is_test = false) ⇒ Authentication
Returns a new instance of Authentication.
6 7 8 9 10 11 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 6 def initialize(username, password, as_endpoint, is_test = false) @username = username @password = password @as_endpoint = as_endpoint @is_test = is_test end |
Instance Attribute Details
#as_endpoint ⇒ Object (readonly)
Returns the value of attribute as_endpoint.
4 5 6 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 4 def as_endpoint @as_endpoint end |
#password ⇒ Object (readonly)
Returns the value of attribute password.
4 5 6 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 4 def password @password end |
#username ⇒ Object (readonly)
Returns the value of attribute username.
4 5 6 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 4 def username @username end |
Instance Method Details
#execute_command(_options) ⇒ Object
17 18 19 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 17 def execute_command() java_root_command end |
#login ⇒ Object
13 14 15 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 13 def login execute [] end |
#root_command_options ⇒ Object
21 22 23 |
# File 'lib/fairdom/openbis_api/authentication.rb', line 21 def " -account '{%username%:%#{username}%\,%password%:%#{password}%}' -endpoints '{%as%:%#{as_endpoint}%,%is_test%:%#{is_test}%}'" end |