Class: Contentful::Bootstrap::Commands::Base

Inherits:
Object
  • Object
show all
Includes:
Support
Defined in:
lib/contentful/bootstrap/commands/base.rb

Direct Known Subclasses

CreateSpace, GenerateToken, UpdateSpace

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Support

#silence_stderr

Constructor Details

#initialize(token, space, trigger_oauth = true) ⇒ Base

Returns a new instance of Base.



13
14
15
16
17
18
# File 'lib/contentful/bootstrap/commands/base.rb', line 13

def initialize(token, space, trigger_oauth = true)
  @token = token
  configuration if trigger_oauth
  management_client_init if trigger_oauth
  @space = space
end

Instance Attribute Details

#spaceObject (readonly)

Returns the value of attribute space.



11
12
13
# File 'lib/contentful/bootstrap/commands/base.rb', line 11

def space
  @space
end

#tokenObject (readonly)

Returns the value of attribute token.



11
12
13
# File 'lib/contentful/bootstrap/commands/base.rb', line 11

def token
  @token
end

Instance Method Details

#runObject



20
21
22
# File 'lib/contentful/bootstrap/commands/base.rb', line 20

def run
  fail 'must implement'
end