Class: GlobiGuard::Credential
- Inherits:
-
Struct
- Object
- Struct
- GlobiGuard::Credential
- Defined in:
- lib/globiguard.rb
Instance Attribute Summary collapse
-
#environment ⇒ Object
Returns the value of attribute environment.
-
#kind ⇒ Object
Returns the value of attribute kind.
-
#project_id ⇒ Object
Returns the value of attribute project_id.
-
#token ⇒ Object
Returns the value of attribute token.
Class Method Summary collapse
- .local(token = nil) ⇒ Object
- .publishable(project_id, token, environment) ⇒ Object
- .secret(project_id, token, environment) ⇒ Object
Instance Attribute Details
#environment ⇒ Object
Returns the value of attribute environment
14 15 16 |
# File 'lib/globiguard.rb', line 14 def environment @environment end |
#kind ⇒ Object
Returns the value of attribute kind
14 15 16 |
# File 'lib/globiguard.rb', line 14 def kind @kind end |
#project_id ⇒ Object
Returns the value of attribute project_id
14 15 16 |
# File 'lib/globiguard.rb', line 14 def project_id @project_id end |
#token ⇒ Object
Returns the value of attribute token
14 15 16 |
# File 'lib/globiguard.rb', line 14 def token @token end |
Class Method Details
.local(token = nil) ⇒ Object
23 24 25 |
# File 'lib/globiguard.rb', line 23 def self.local(token = nil) new(kind: "local", project_id: nil, token: token, environment: "local") end |
.publishable(project_id, token, environment) ⇒ Object
19 20 21 |
# File 'lib/globiguard.rb', line 19 def self.publishable(project_id, token, environment) new(kind: "publishable", project_id: project_id, token: token, environment: environment) end |
.secret(project_id, token, environment) ⇒ Object
15 16 17 |
# File 'lib/globiguard.rb', line 15 def self.secret(project_id, token, environment) new(kind: "secret", project_id: project_id, token: token, environment: environment) end |