Class: Msf::Plugin::Capture::ConsoleCommandDispatcher::CaptureJobListener

Inherits:
Object
  • Object
show all
Defined in:
plugins/capture.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, done_event, dispatcher) ⇒ CaptureJobListener

Returns a new instance of CaptureJobListener.



16
17
18
19
20
# File 'plugins/capture.rb', line 16

def initialize(name, done_event, dispatcher)
  @name = name
  @done_event = done_event
  @dispatcher = dispatcher
end

Instance Attribute Details

#succeededObject

Returns the value of attribute succeeded.



37
38
39
# File 'plugins/capture.rb', line 37

def succeeded
  @succeeded
end

Instance Method Details

#completed(id, result, mod) ⇒ Object



30
# File 'plugins/capture.rb', line 30

def completed(id, result, mod); end

#failed(_id, _error, _mod) ⇒ Object



32
33
34
35
# File 'plugins/capture.rb', line 32

def failed(_id, _error, _mod)
  @dispatcher.print_error("#{@name} failed to start")
  @done_event.set
end

#start(id) ⇒ Object



28
# File 'plugins/capture.rb', line 28

def start(id); end

#waiting(_id) ⇒ Object



22
23
24
25
26
# File 'plugins/capture.rb', line 22

def waiting(_id)
  self.succeeded = true
  @dispatcher.print_good("#{@name} started")
  @done_event.set
end