Class: SubSpawn::IoHolder::PTY

Inherits:
Composite show all
Defined in:
lib/subspawn/pipes.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(master, slave) ⇒ PTY

Returns a new instance of PTY.



37
38
39
# File 'lib/subspawn/pipes.rb', line 37

def initialize(master, slave)
	@master, @slave = master, slave
end

Instance Attribute Details

#masterObject (readonly) Also known as: to_io

Returns the value of attribute master.



40
41
42
# File 'lib/subspawn/pipes.rb', line 40

def master
  @master
end

#slaveObject (readonly)

Returns the value of attribute slave.



40
41
42
# File 'lib/subspawn/pipes.rb', line 40

def slave
  @slave
end

Instance Method Details

#filenoObject



45
46
47
# File 'lib/subspawn/pipes.rb', line 45

def fileno
	@master.fileno
end

#to_aryObject



42
43
44
# File 'lib/subspawn/pipes.rb', line 42

def to_ary
	[@master, @slave]
end