Class: Kpigen::Application

Inherits:
Object
  • Object
show all
Defined in:
lib/kpigen/application.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(eve) ⇒ Application

Returns a new instance of Application.



7
8
9
# File 'lib/kpigen/application.rb', line 7

def initialize(eve)
  @eve = eve
end

Instance Attribute Details

#eveObject

Returns the value of attribute eve.



5
6
7
# File 'lib/kpigen/application.rb', line 5

def eve
  @eve
end

Instance Method Details

#cmd(raw, display_messages = true, external_cmd = false) ⇒ Object



15
16
17
# File 'lib/kpigen/application.rb', line 15

def cmd(raw,display_messages = true,external_cmd = false)
  @eve.cmd(raw,display_messages,external_cmd)
end

#redisObject



11
12
13
# File 'lib/kpigen/application.rb', line 11

def redis
  @eve.redis
end

#run(args) ⇒ Object



19
20
21
22
23
# File 'lib/kpigen/application.rb', line 19

def run(args)
  dir = File.dirname(__FILE__)
  kpigen_args = ["--register", "Eve::BaseRegistry", "--register", "Kpigen::KpigenRegistry", p("#{dir}/../registry/kpigen_registry.rb") ]
  @eve.run(args + kpigen_args)
end