The goog.messaging.PortOperator Class

goog.messaging.PortOperator
> goog.Disposable

goog.messaging.PortOperator(name)

The central node of a PortNetwork.

name {string}
The name of this node.

.addOnDisposeCallback(callback, opt_scope)

Inherited from goog.Disposable .

Invokes a callback function when this object is disposed. Callbacks are invoked in the order in which they were added.

callback {!Function}
The callback function.
opt_scope {Object=}
An optional scope to call the callback in.

.addPort(name, port)

Adds a caller to the network with the given name. This port should have no services registered on it. It will be disposed along with the PortOperator.

name {string}
The name of the port to add.
port {!goog.messaging.MessageChannel}
The port to add. Must be either a {@link goog.messaging.PortChannel} or a decorator wrapping a PortChannel; in particular, it must be able to send and receive {@link MessagePort}s.

.creationStack {string}

Inherited from goog.Disposable .

If monitoring the goog.Disposable instances is enabled, stores the creation stack trace of the Disposable instance.

.dial()

.dispose()

Inherited from goog.Disposable .

Disposes of the object. If the object hasn't already been disposed of, calls {@link #disposeInternal}. Classes that extend {@code goog.Disposable} should override {@link #disposeInternal} in order to delete references to COM objects, DOM nodes, and other disposable objects. Reentrant.

returns {void}
Nothing.

.isDisposed()

Inherited from goog.Disposable .

returns {boolean}
Whether the object has been disposed of.

.registerDisposable(disposable)

Inherited from goog.Disposable .

Associates a disposable object with this object so that they will be disposed together.

disposable {goog.disposable.IDisposable}
that will be disposed when this object is disposed.