Class: CRB_Blast::Cmd

Inherits:
Object
  • Object
show all
Defined in:
lib/crb-blast/cmd.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cmd) ⇒ Cmd

Returns a new instance of Cmd.



9
10
11
# File 'lib/crb-blast/cmd.rb', line 9

def initialize cmd
  @cmd = cmd
end

Instance Attribute Details

#cmdObject

Returns the value of attribute cmd.



7
8
9
# File 'lib/crb-blast/cmd.rb', line 7

def cmd
  @cmd
end

#statusObject

Returns the value of attribute status.



7
8
9
# File 'lib/crb-blast/cmd.rb', line 7

def status
  @status
end

#stderrObject

Returns the value of attribute stderr.



7
8
9
# File 'lib/crb-blast/cmd.rb', line 7

def stderr
  @stderr
end

#stdoutObject

Returns the value of attribute stdout.



7
8
9
# File 'lib/crb-blast/cmd.rb', line 7

def stdout
  @stdout
end

Instance Method Details

#runObject



13
14
15
# File 'lib/crb-blast/cmd.rb', line 13

def run
  @stdout, @stderr, @status = Open3.capture3 @cmd
end