Class: PasswordCredentials
- Inherits:
-
Credentials
- Object
- Credentials
- PasswordCredentials
- Defined in:
- lib/jirarest2/password_credentials.rb
Overview
A Credentials object contains the data required to connect to a JIRA(tm) instance.
Instance Attribute Summary collapse
-
#password ⇒ Object
password for the connection.
Attributes inherited from Credentials
#baseurl, #connecturl, #username
Instance Method Summary collapse
-
#get_auth_header(request) ⇒ Object
Get the auth header to send to the server.
-
#initialize(url, username, password) ⇒ PasswordCredentials
constructor
A new instance of PasswordCredentials.
Constructor Details
#initialize(url, username, password) ⇒ PasswordCredentials
Returns a new instance of PasswordCredentials.
30 31 32 33 |
# File 'lib/jirarest2/password_credentials.rb', line 30 def initialize(url,username,password) super(url,username) @password = password end |
Instance Attribute Details
#password ⇒ Object
password for the connection
25 26 27 |
# File 'lib/jirarest2/password_credentials.rb', line 25 def password @password end |
Instance Method Details
#get_auth_header(request) ⇒ Object
Get the auth header to send to the server
37 38 39 |
# File 'lib/jirarest2/password_credentials.rb', line 37 def get_auth_header(request) request.basic_auth @username, @password end |