blob: 209cb3b683a10693a8119f9416d7f0b92f32fa83 [file] [log] [blame]
{ "type": "class",
"qname": "mx.messaging.ChannelSet",
"baseClassname": "org.apache.royale.events.EventDispatcher"
,
"description": "The ChannelSet is a set of Channels that are used to send messages to a target destination. The ChannelSet improves the quality of service on the client by hunting through its Channels to send messages in the face of network failures or individual Channel problems.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"members": [
{ "type": "method",
"qname": "mx.messaging.ChannelSet",
"namespace": "",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Constructs a ChannelSet. If the <code>channelIds</code> argument is provided, the ChannelSet will use automatically configured Channels obtained via <code>ServerConfig.getChannel()</code> to reach a destination. Attempting to manually assign Channels to a ChannelSet that uses configured Channels is not allowed. <p>If the <code>channelIds</code> argument is not provided or is null, Channels must be manually created and added to the ChannelSet in order to connect and send messages.</p> <p>If the ChannelSet is clustered using url-load-balancing (where each server declares a unique RTMP or HTTP URL and the client fails over from one URL to the next), the first time that a Channel in the ChannelSet successfully connects the ChannelSet will automatically make a request for all of the endpoints across the cluster for all member Channels and will assign these failover URLs to each respective Channel. This allows Channels in the ChannelSet to failover individually, and when failover options for a specific Channel are exhausted the ChannelSet will advance to the next Channel in the set to attempt to reconnect.</p> <p>Regardless of clustering, if a Channel cannot connect or looses connectivity, the ChannelSet will advance to its next available Channel and attempt to reconnect. This allows the ChannelSet to hunt through Channels that use different protocols, ports, etc., in search of one that can connect to its endpoint successfully.</p> use. If null, Channels must be manually added to the ChannelSet. using url load balancing.",
"tags": [
{ "tagName": "param",
"values": ["channelIds The ids of configured Channels obtained from ServerConfig for this ChannelSet to", "clusteredWithURLLoadBalancing True if the Channels in the ChannelSet are clustered"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "",
"params": [{ "name": "channelIds", "type": "Array"},
{ "name": "clusteredWithURLLoadBalancing", "type": "Boolean"}]}
,
{ "type": "accessor",
"access": "read-only",
"return": "Boolean",
"qname": "authenticated",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Indicates whether the ChannelSet has an underlying Channel that successfully authenticated with its endpoint.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Array",
"qname": "channels",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Provides access to the Channels in the ChannelSet. This property may be used to assign a set of channels at once or channels may be added directly to the ChannelSet via addChannel() individually. If this ChannelSet is <code>configured</code> automatically the individual channels are created lazily and added to this property as needed. <code>configured</code>, assigning to this property is not allowed.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError If the ChannelSet is"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "Array",
"qname": "channelIds",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The ids of the Channels used by the ChannelSet.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "mx.messaging.Channel",
"qname": "currentChannel",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Returns the current Channel for the ChannelSet.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Object",
"qname": "channelFailoverURIs",
"namespace": "mx_internal",
"bindable": [],
"details": [],
"deprecated": {},
"description": "",
"tags": [
{ "tagName": "private",
"values": []} ]},
{ "type": "accessor",
"access": "read-only",
"return": "Boolean",
"qname": "configured",
"namespace": "mx_internal",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Indicates whether the ChannelSet is using automatically configured Channels or manually assigned Channels.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "Boolean",
"qname": "connected",
"namespace": "public",
"bindable": ["propertyChange"],
"details": [],
"deprecated": {},
"description": "Indicates whether the ChannelSet is connected."},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "clustered",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Indicates whether the ChannelSet targets a clustered destination. If true, upon a successful connection the ChannelSet will query the destination for all clustered endpoints for its Channels and will assign failoverURIs to them. Channel ids are used to assign failoverURIs to the proper Channel instances so this requires that all Channels in the ChannelSet have non-null ids and an Error will be thrown when this property is set to true if this is not the case. If the ChannelSet is not using url load balancing on the client this property should not be set to true.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "int",
"qname": "heartbeatInterval",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The number of milliseconds between heartbeats sent to the remote host while this ChannelSet is actively connected but idle. Any outbound message traffic will delay heartbeats temporarily, with this number of milliseconds elapsing after the last sent message before the next heartbeat is issued. <p> This property is useful for applications that connect to a remote host to received pushed updates and are not actively sending any messages, but still wish to be notified of a dropped connection even when the networking layer fails to provide such notification directly. By issuing periodic heartbeats the client can force the networking layer to report a timeout if the underlying connection has dropped without notification and the application can respond to the disconnect appropriately. </p> <p> Any non-positive value disables heartbeats to the remote host. The default value is 0 indicating that heartbeats are disabled. If the application sets this value it should prefer a longer rather than shorter interval, to avoid placing unnecessary load on the remote host. As an illustrative example, low-level TCP socket keep-alives generally default to an interval of 2 hours. That is a longer interval than most applications that enable heartbeats will likely want to use, but it serves as a clear precedent to prefer a longer interval over a shorter interval. </p> <p> If the currently connected underlying Channel issues poll requests to the remote host, heartbeats are suppressed because the periodic poll requests effectively take their place.</p>"},
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "initialDestinationId",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Provides access to the initial destination this ChannelSet is used to access. When the clustered property is true, this value is used to request available failover URIs for the configured channels for the destination.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-only",
"return": "Array",
"qname": "messageAgents",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Provides access to the set of MessageAgents that use this ChannelSet.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "method",
"qname": "toString",
"namespace": "public",
"bindable": [],
"details": ["override"],
"deprecated": {},
"description": "Returns a String containing the ids of the Channels in the ChannelSet.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "return",
"values": ["String representation of the ChannelSet."]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "String",
"params": []}
,
{ "type": "method",
"qname": "addChannel",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Adds a Channel to the ChannelSet. A Channel with a null id cannot be added to the ChannelSet if the ChannelSet targets a clustered destination. <code>configured</code>, adding a Channel is not supported. This error is also thrown if the ChannelSet's <code>clustered</code> property is <code>true</code> but the Channel has a null id.",
"tags": [
{ "tagName": "param",
"values": ["channel The Channel to add."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError If the ChannelSet is"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "channel", "type": "mx.messaging.Channel"}]}
,
{ "type": "method",
"qname": "removeChannel",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Removes a Channel from the ChannelSet. If the Channel to remove is currently connected and being used by the ChannelSet, it is disconnected as well as removed. <code>configured</code>, removing a Channel is not supported.",
"tags": [
{ "tagName": "param",
"values": ["channel The Channel to remove."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError If the ChannelSet is"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "channel", "type": "mx.messaging.Channel"}]}
,
{ "type": "method",
"qname": "connect",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Connects a MessageAgent to the ChannelSet. Once connected, the agent can use the ChannelSet to send messages.",
"tags": [
{ "tagName": "param",
"values": ["agent The MessageAgent to connect."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "agent", "type": "mx.messaging.MessageAgent"}]}
,
{ "type": "method",
"qname": "disconnect",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Disconnects a specific MessageAgent from the ChannelSet. If this is the last MessageAgent using the ChannelSet and the current Channel in the set is connected, the Channel will physically disconnect from the server.",
"tags": [
{ "tagName": "param",
"values": ["agent The MessageAgent to disconnect."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "agent", "type": "mx.messaging.MessageAgent"}]}
,
{ "type": "method",
"qname": "disconnectAll",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Disconnects all associated MessageAgents and disconnects any underlying Channel that is connected. Unlike <code>disconnect(MessageAgent)</code> which is invoked by the disconnect implementations of specific service components, this method provides a single, convenient point to shut down connectivity between the client and server.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": []}
,
{ "type": "method",
"qname": "channelConnectHandler",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Handles a CONNECT ChannelEvent and redispatches the event.",
"tags": [
{ "tagName": "param",
"values": ["event The ChannelEvent."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "event", "type": "mx.messaging.events.ChannelEvent"}]}
,
{ "type": "method",
"qname": "channelDisconnectHandler",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Handles a DISCONNECT ChannelEvent and redispatches the event.",
"tags": [
{ "tagName": "param",
"values": ["event The ChannelEvent."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "event", "type": "mx.messaging.events.ChannelEvent"}]}
,
{ "type": "method",
"qname": "channelFaultHandler",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Handles a ChannelFaultEvent and redispatches the event.",
"tags": [
{ "tagName": "param",
"values": ["event The ChannelFaultEvent."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "event", "type": "mx.messaging.events.ChannelFaultEvent"}]}
,
{ "type": "method",
"qname": "login",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Authenticates the ChannelSet with the server using the provided credentials. Unlike other operations on Channels and the ChannelSet, this operation returns an AsyncToken that client code may add a responder to in order to handle success or failure directly. If the ChannelSet is not connected to the server when this method is invoked it will trigger a connect attempt, and if successful, send the login command to the server. Only one login or logout operation may be pending at a time and overlapping calls will generate an IllegalOperationError. Invoking login when the ChannelSet is already authenticated will generate also generate an IllegalOperationError. credentials. The default is null, which implies the legacy charset of ISO-Latin-1. The only other supported charset is &quot;UTF-8&quot;. success or failure directly. already authenticated, or if a login or logout operation is currently in progress.",
"tags": [
{ "tagName": "param",
"values": ["username The username.", "password The password.", "charset The character set encoding to use while encoding the"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError in two situations; if the ChannelSet is"]},
{ "tagName": "return",
"values": ["Returns a token that client code may add a responder to in order to handle"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "mx.rpc.AsyncToken",
"params": [{ "name": "username", "type": "String"},
{ "name": "password", "type": "String"},
{ "name": "charset", "type": "String"}]}
,
{ "type": "method",
"qname": "logout",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Logs the ChannelSet out from the server. Unlike other operations on Channels and the ChannelSet, this operation returns an AsyncToken that client code may add a responder to in order to handle success or failure directly. If logout is successful any credentials that have been cached for use in automatic reconnects are cleared for the ChannelSet and its Channels and their authenticated state is set to false. If the ChannelSet is not connected to the server when this method is invoked it will trigger a connect attempt, and if successful, send a logout command to the server. <p>The MessageAgent argument is present to support legacy logout behavior and client code that invokes this method should not pass a MessageAgent reference. Just invoke <code>logout()</code> passing no arguments.</p> <p>This method is also invoked by service components from their <code>logout()</code> methods, and these components pass a MessageAgent reference to this method when they logout. The presence of this argument is the trigger to execute legacy logout behavior that differs from the new behavior described above. Legacy behavior only sends a logout request to the server if the client is connected and authenticated. If these conditions are not met the legacy behavior for this method is to do nothing other than clear any credentials that have been cached for use in automatic reconnects.</p> add a responder to in order to handle success or failure directly.",
"tags": [
{ "tagName": "param",
"values": ["agent Legacy argument. The MessageAgent that is initiating the logout."]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError if a login or logout operation is currently in progress."]},
{ "tagName": "return",
"values": ["Returns a token that client code may"]} ],
"return": "mx.rpc.AsyncToken",
"params": [{ "name": "agent", "type": "mx.messaging.MessageAgent"}]}
,
{ "type": "method",
"qname": "send",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Sends a message from a MessageAgent over the currently connected Channel. Channels to use.",
"tags": [
{ "tagName": "param",
"values": ["agent The MessageAgent sending the message.", "message The Message to send."]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["mx.messaging.errors.NoChannelAvailableError If the ChannelSet has no internal"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "agent", "type": "mx.messaging.MessageAgent"},
{ "name": "message", "type": "mx.messaging.messages.IMessage"}]}
,
{ "type": "method",
"qname": "setCredentials",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Stores the credentials and passes them through to every connected channel. credentials. The default is null, which implies the legacy encoding of ISO-Latin-1. have already been set and an authentication is in progress with the remote detination, or if authenticated and the credentials specified don't match the currently authenticated credentials.",
"tags": [
{ "tagName": "param",
"values": ["credentials The credentials for the MessageAgent.", "agent The MessageAgent that is setting the credentials.", "charset The character set encoding used while encoding the"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "throws",
"values": ["flash.errors.IllegalOperationError in two situations; if credentials"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "void",
"params": [{ "name": "credentials", "type": "String"},
{ "name": "agent", "type": "mx.messaging.MessageAgent"},
{ "name": "charset", "type": "String"}]}
,
{ "type": "method",
"qname": "messageHandler",
"namespace": "protected",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Redispatches message events from the currently connected Channel.",
"tags": [
{ "tagName": "param",
"values": ["event The MessageEvent from the Channel."]} ],
"return": "void",
"params": [{ "name": "event", "type": "mx.messaging.events.MessageEvent"}]}
]
,
"events": [
{ "qname": "channelConnect",
"type": "mx.messaging.events.ChannelEvent"
,
"description": "Dispatched after a Channel in the ChannelSet has connected to its endpoint.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.messaging.events.ChannelEvent.CONNECT"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "qname": "channelDisconnect",
"type": "mx.messaging.events.ChannelEvent"
,
"description": "Dispatched after a Channel in the ChannelSet has disconnected from its endpoint.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.messaging.events.ChannelEvent.DISCONNECT"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "qname": "channelFault",
"type": "mx.messaging.events.ChannelFaultEvent"
,
"description": "Dispatched after a Channel in the ChannelSet has faulted.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.messaging.events.ChannelFaultEvent.FAULT"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "qname": "result",
"type": "mx.rpc.events.ResultEvent"
,
"description": "The result event is dispatched when a login or logout call successfully returns.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.rpc.events.ResultEvent.RESULT"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "qname": "fault",
"type": "mx.rpc.events.FaultEvent"
,
"description": "The fault event is dispatched when a login or logout call fails.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.rpc.events.FaultEvent.FAULT"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "qname": "propertyChange",
"type": "mx.events.PropertyChangeEvent"
,
"description": "Dispatched when a property of the ChannelSet changes.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "eventType",
"values": ["mx.events.PropertyChangeEvent.PROPERTY_CHANGE"]},
{ "tagName": "productversion",
"values": ["BlazeDS 4", "LCDS 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]}]
}