Class: MultiTkIp::Command_Queue

Inherits:
Queue
  • Object
show all
Defined in:
lib/multi-tk.rb

Instance Method Summary collapse

Constructor Details

#initialize(interp) ⇒ Command_Queue

Returns a new instance of Command_Queue.



65
66
67
68
# File 'lib/multi-tk.rb', line 65

def initialize(interp)
  @interp = interp
  super()
end

Instance Method Details

#closeObject



79
80
81
# File 'lib/multi-tk.rb', line 79

def close
  @interp = nil
end

#push(value) ⇒ Object Also known as: <<, enq



70
71
72
73
74
75
# File 'lib/multi-tk.rb', line 70

def push(value)
  if !@interp || @interp.deleted?
    fail RuntimeError, "Tk interpreter is already deleted"
  end
  super(value)
end