Class: Contentful::Bootstrap::Commands::Base
- Inherits:
-
Object
- Object
- Contentful::Bootstrap::Commands::Base
- Defined in:
- lib/contentful/bootstrap/commands/base.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
-
#no_input ⇒ Object
readonly
Returns the value of attribute no_input.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#quiet ⇒ Object
readonly
Returns the value of attribute quiet.
-
#space ⇒ Object
readonly
Returns the value of attribute space.
-
#token ⇒ Object
readonly
Returns the value of attribute token.
Instance Method Summary collapse
-
#initialize(token, space, options = {}) ⇒ Base
constructor
A new instance of Base.
- #run ⇒ Object
Constructor Details
#initialize(token, space, options = {}) ⇒ Base
Returns a new instance of Base.
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 12 def initialize(token, space, = {}) trigger_oauth = .fetch(:trigger_oauth, true) @token = token @options = @quiet = .fetch(:quiet, false) @no_input = .fetch(:no_input, false) configuration if trigger_oauth management_client_init if trigger_oauth @space = space end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def client @client end |
#no_input ⇒ Object (readonly)
Returns the value of attribute no_input.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def no_input @no_input end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def @options end |
#quiet ⇒ Object (readonly)
Returns the value of attribute quiet.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def quiet @quiet end |
#space ⇒ Object (readonly)
Returns the value of attribute space.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def space @space end |
#token ⇒ Object (readonly)
Returns the value of attribute token.
10 11 12 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 10 def token @token end |
Instance Method Details
#run ⇒ Object
25 26 27 |
# File 'lib/contentful/bootstrap/commands/base.rb', line 25 def run fail 'must implement' end |