Class: CommandResult

Inherits:
Object
  • Object
show all
Defined in:
lib/atk/console.rb

Instance Method Summary collapse

Constructor Details

#initialize(io_object) ⇒ CommandResult

Returns a new instance of CommandResult.



13
14
15
# File 'lib/atk/console.rb', line 13

def initialize(io_object)
    @io_object = io_object
end

Instance Method Details

#exitcodeObject



24
25
26
27
28
# File 'lib/atk/console.rb', line 24

def exitcode
    if !@io_object
        return Errno::ENOENT.new
    end
end

#readObject



17
18
19
20
21
22
# File 'lib/atk/console.rb', line 17

def read
    if @read == nil && @io_object
        @read = @io_object.read
    end
    return @read
end