Packagecom.aispeech.net
Classpublic class HttpConnection
InheritanceHttpConnection Inheritance ConnectionBase Inheritance flash.events.EventDispatcher
Implements IConnection



Public Properties
 PropertyDefined By
 InheritedconnectionParams : ConnectionParams
[read-only]
ConnectionBase
 Inheritedlatency : int
ConnectionBase
 Inheritedlog : ConnectionLog
[read-only]
ConnectionBase
  netInstance : NetConnection
[read-only]
HttpConnection
 InheritedsessionId : String
[read-only]
ConnectionBase
 Inheritedstate : String
[read-only]
ConnectionBase
  streamClient : Object
[write-only]
HttpConnection
  streamInstance : NetStream
HttpConnection
 Inheritedthroughput : int
keep throughput average
ConnectionBase
Protected Properties
 PropertyDefined By
 Inherited_connectionLog : ConnectionLog
ConnectionBase
 Inherited_sessionId : String
ConnectionBase
 Inherited_state : String
ConnectionBase
 Inherited_testConnection : Boolean
ConnectionBase
 Inherited_timeoutTimerId : int
ConnectionBase
Public Methods
 MethodDefined By
  
HttpConnection(connectionParams:ConnectionParams, testConnection:Boolean = false)
Constructor
HttpConnection
  
connect():void
Connect to an HTTP server
HttpConnection
  
disconnect():void
Disconnect from an HTTP server
HttpConnection
  
HttpConnection
  
rpc(method:String, params:Object, callback:Function = null):Boolean
RPC through a HTTP connection -- i.e.
HttpConnection
  
sendRequest(request:AIHttpRequest, url:URI):Boolean
Send HTTP request through a socket
HttpConnection
Protected Methods
 MethodDefined By
 Inherited
checkLatency(repeatCount:int = 1, delay:int = 300000):void
check latency
ConnectionBase
 Inherited
Connection timeout event handler
ConnectionBase
 Inherited
ConnectionBase
Property Detail
netInstanceproperty
netInstance:NetConnection  [read-only]


Implementation
    public function get netInstance():NetConnection
streamClientproperty 
streamClient:Object  [write-only]


Implementation
    public function set streamClient(value:Object):void
streamInstanceproperty 
streamInstance:NetStream


Implementation
    public function get streamInstance():NetStream
    public function set streamInstance(value:NetStream):void
Constructor Detail
HttpConnection()Constructor
public function HttpConnection(connectionParams:ConnectionParams, testConnection:Boolean = false)

Constructor

Parameters
connectionParams:ConnectionParams
 
testConnection:Boolean (default = false)
Method Detail
connect()method
public function connect():void

Connect to an HTTP server

disconnect()method 
public function disconnect():void

Disconnect from an HTTP server

removeAllNetStreamEventListener()method 
public function removeAllNetStreamEventListener():void

rpc()method 
public function rpc(method:String, params:Object, callback:Function = null):Boolean

RPC through a HTTP connection -- i.e. HTTP request

Parameters

method:String
 
params:Object
 
callback:Function (default = null)

Returns
Boolean
sendRequest()method 
public function sendRequest(request:AIHttpRequest, url:URI):Boolean

Send HTTP request through a socket

Parameters

request:AIHttpRequest
 
url:URI

Returns
Boolean