class Orocos::Async::CORBA::Port
Attributes
options[RW]
Public Class Methods
new(async_task,port,options=Hash.new)
click to toggle source
Calls superclass method
Orocos::Async::ObjectBase.new
# File lib/orocos/async/ports.rb, line 212 def initialize(async_task,port,options=Hash.new) raise ArgumentError, "no task is given" unless async_task raise ArgumentError, "no port is given" unless port @options ||= options @task ||= async_task @mutex ||= Mutex.new super(port.name,async_task.event_loop) @task.on_unreachable do unreachable! end disable_emitting do reachable!(port) end end
Public Instance Methods
reachable!(port,options = Hash.new)
click to toggle source
Calls superclass method
Orocos::Async::ObjectBase#reachable!
# File lib/orocos/async/ports.rb, line 186 def reachable!(port,options = Hash.new) @mutex.synchronize do super end end
reachable?()
click to toggle source
Calls superclass method
Orocos::Async::ObjectBase#reachable?
# File lib/orocos/async/ports.rb, line 198 def reachable? super && @task.reachable? end
task()
click to toggle source
# File lib/orocos/async/ports.rb, line 182 def task @task end
to_async(options=Hash.new)
click to toggle source
# File lib/orocos/async/ports.rb, line 202 def to_async(options=Hash.new) self end
to_proxy(options=Hash.new)
click to toggle source
# File lib/orocos/async/ports.rb, line 206 def to_proxy(options=Hash.new) task.to_proxy(options).port(name) end
unreachable!(options = Hash.new)
click to toggle source
Calls superclass method
Orocos::Async::ObjectBase#unreachable!
# File lib/orocos/async/ports.rb, line 192 def unreachable!(options = Hash.new) @mutex.synchronize do super end end
Protected Instance Methods
connection_error(error)
click to toggle source
# File lib/orocos/async/ports.rb, line 227 def connection_error(error) emit_error error end
port()
click to toggle source
# File lib/orocos/async/ports.rb, line 231 def port @mutex.synchronize do if !valid_delegator? error = Orocos::NotFound.new "Port #{name} is not reachable" [nil,error] else @delegator_obj end end end