Class: PrayRemote::Client

Inherits:
Struct
  • Object
show all
Includes:
DRab::DRabUndumped
Defined in:
lib/pray-remote/pray-remote.rb

Overview

A client is used to retrieve information from the client program.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#editorObject

Returns the value of attribute editor

Returns:

  • (Object)

    the current value of editor



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def editor
  @editor
end

#inputObject

Returns the value of attribute input

Returns:

  • (Object)

    the current value of input



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def input
  @input
end

#mypryObject

Returns the value of attribute mypry

Returns:

  • (Object)

    the current value of mypry



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def mypry
  @mypry
end

#outputObject

Returns the value of attribute output

Returns:

  • (Object)

    the current value of output



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def output
  @output
end

#stderrObject

Returns the value of attribute stderr

Returns:

  • (Object)

    the current value of stderr



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def stderr
  @stderr
end

#stdoutObject

Returns the value of attribute stdout

Returns:

  • (Object)

    the current value of stdout



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def stdout
  @stdout
end

#threadObject

Returns the value of attribute thread

Returns:

  • (Object)

    the current value of thread



228
229
230
# File 'lib/pray-remote/pray-remote.rb', line 228

def thread
  @thread
end

Instance Method Details

#input_proxyInputProxy

Returns Proxy for the input.

Returns:



249
250
251
# File 'lib/pray-remote/pray-remote.rb', line 249

def input_proxy
  InputProxy.new input
end

#killObject

Tells the client the session is terminated



244
245
246
# File 'lib/pray-remote/pray-remote.rb', line 244

def kill
  thread.run if not thread.nil?
end

#waitObject

Waits until both an input and output are set



239
240
241
# File 'lib/pray-remote/pray-remote.rb', line 239

def wait
  sleep 0.01 until input and output and thread
end