Sha256: 662b0b7743abfaad29ef4681e47921fb5d4977ce0ae7afdb5f2bd4daf000eb6e

Contents?: true

Size: 530 Bytes

Versions: 4

Compression:

Stored size: 530 Bytes

Contents

# frozen_string_literal: true

require 'eac_ruby_utils/patches/object/if_present'

module EacRubyUtils
  module Console
    module Speaker
      class Node
        attr_accessor :stdin, :stdout, :stderr

        def initialize(parent = nil)
          self.stdin = parent.if_present(STDIN, &:stdin)
          self.stdout = parent.if_present(STDOUT, &:stdout)
          self.stderr = parent.if_present(STDERR, &:stderr)
        end

        def configure
          yield(self)
          self
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
eac_ruby_utils-0.17.0 lib/eac_ruby_utils/console/speaker/node.rb
eac_ruby_utils-0.16.0 lib/eac_ruby_utils/console/speaker/node.rb
eac_ruby_utils-0.15.0 lib/eac_ruby_utils/console/speaker/node.rb
eac_ruby_utils-0.14.0 lib/eac_ruby_utils/console/speaker/node.rb