Transferred from the Adobe Open Source Subversion Repository

Revision: 5319
Author:   jimurphy@adobe.com
Date:     2009-03-16T15:07:19.469668Z

Log Message:
-----------
Merge 3.x revisions 5186-5187,5210,5229,5298 -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/skins/RectangularBorder.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/Channel.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/rpc/xml/SchemaManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/rpc/src/mx/messaging/MessageAgent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/CrossDomainRSLItem.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1273447 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/rpc/src/mx/messaging/Channel.as
+++ frameworks/projects/rpc/src/mx/messaging/Channel.as
@@ -44,12 +44,6 @@
  *  Dispatched after the channel has connected to its endpoint.
  *
  *  @eventType mx.messaging.events.ChannelEvent.CONNECT
- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 [Event(name="channelConnect", type="mx.messaging.events.ChannelEvent")]

@@ -57,51 +51,27 @@
  *  Dispatched after the channel has disconnected from its endpoint.
  *
  *  @eventType mx.messaging.events.ChannelEvent.DISCONNECT
- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 [Event(name="channelDisconnect", type="mx.messaging.events.ChannelEvent")]

 /**
  *  Dispatched after the channel has faulted.
- *
+ *
  *  @eventType mx.messaging.events.ChannelFaultEvent.FAULT
- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 [Event(name="channelFault", type="mx.messaging.events.ChannelFaultEvent")]

 /**
  *  Dispatched when a channel receives a message from its endpoint.
- *
+ *
  *  @eventType mx.messaging.events.MessageEvent.MESSAGE
- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 [Event(name="message", type="mx.messaging.events.MessageEvent")]

 /**
  *  Dispatched when a property of the channel changes.
- *
+ *
  *  @eventType mx.events.PropertyChangeEvent.PROPERTY_CHANGE
- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 [Event(name="propertyChange", type="mx.events.PropertyChangeEvent")]

@@ -111,13 +81,13 @@
  *  The Channel class is the base message channel class that all channels in the messaging
  *  system must extend.
  *
- *
Channels are specific protocol-based conduits for messages sent between
+ *
Channels are specific protocol-based conduits for messages sent between
  *  MessageAgents and remote destinations.
  *  Preconfigured channels are obtained within the framework using the
  *  ServerConfig.getChannel() method.
  *  You can create a Channel directly using the new operator and
  *  add it to a ChannelSet directly.

- *
+ *
  *

  *  Channels represent a physical connection to a remote endpoint.
  *  Channels are shared across destinations by default.
@@ -128,12 +98,6 @@
  *
Note: This class is for advanced use only.
  *  Use this class for creating custom channels like the existing RTMPChannel,
  *  AMFChannel, and HTTPChannel.

- *
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion BlazeDS 4
- *  @productversion LCDS 3
  */
 public class Channel extends EventDispatcher implements IMXMLObject
 {
@@ -155,63 +119,57 @@
     //--------------------------------------------------------------------------
     //
     // Constructor
-    //
-    //--------------------------------------------------------------------------
-
-    /**
-     *  Constructs an instance of a generic Channel that connects to the
-     *  specified endpoint URI.
+    //
+    //--------------------------------------------------------------------------
+
+	/**
+	 *  Constructs an instance of a generic Channel that connects to the
+	 *  specified endpoint URI.
      *
-     *  Note: The Channel type should not be constructed directly. Instead
-     *  create instances of protocol specific subclasses such as RTMPChannel or
-     *  AMFChannel.
+	 *  Note: The Channel type should not be constructed directly. Instead
+	 *  create instances of protocol specific subclasses such as RTMPChannel or
+	 *  AMFChannel.
      *
-     *  @param id The id of this channel.
-     *
-     *  @param uri The endpoint URI for this channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function Channel(id:String = null, uri:String = null)
-    {
-        super();
-
-        _log = Log.getLogger("mx.messaging.Channel");
-        _failoverIndex = -1;
+	 *  @param id The id of this channel.
+	 *
+	 *  @param uri The endpoint URI for this channel.
+	 */
+	public function Channel(id:String = null, uri:String = null)
+	{
+		super();
+
+		_log = Log.getLogger("mx.messaging.Channel");
+		_failoverIndex = -1;
+	    this.id = id;
+		_primaryURI = uri;
+		this.uri = uri; // Current URI
+	}
+
+    /**
+     * @private
+     */
+    public function initialized(document:Object, id:String):void
+    {
         this.id = id;
-        _primaryURI = uri;
-        this.uri = uri; // Current URI
-    }
-
-    /**
-     * @private
-     */
-    public function initialized(document:Object, id:String):void
-    {
-        this.id = id;
-    }
-
+    }
+
     //--------------------------------------------------------------------------
     //
     // Variables
-    //
-    //--------------------------------------------------------------------------
-
-    /**
-     *  @private
-     *  Used to prevent multiple logouts.
-     */
-    mx_internal var authenticating:Boolean;
-
+    //
+    //--------------------------------------------------------------------------
+
+	/**
+	 *  @private
+	 *  Used to prevent multiple logouts.
+	 */
+	mx_internal var authenticating:Boolean;
+
     /**
      *  @private
      *  The credentials string that is passed via a CommandMessage to the server when the
      *  Channel connects. Channels inherit the credentials of connected ChannelSets that
-     *  inherit their credentials from connected MessageAgents.
+     *  inherit their credentials from connected MessageAgents.
      *  MessageAgent.setCredentials(username, password) is generally used
      *  to set credentials.
      */
@@ -225,12 +183,12 @@
      */
     public var enableSmallMessages:Boolean = true;

-    /**
-     *  @private
-     *  Provides access to a logger for this channel.
-     */
-    protected var _log:ILogger;
-
+	/**
+	 *  @private
+	 *  Provides access to a logger for this channel.
+	 */
+	protected var _log:ILogger;
+
     /**
      *  @private
      *  Flag indicating whether the Channel is in the process of connecting.
@@ -241,20 +199,20 @@
      *  @private
      *  Timer to track connect timeouts.
      */
-    private var _connectTimer:Timer;
-
-    /**
-     *  @private
-     *  Current index into failover URIs during a failover attempt.
-     *  When not failing over, this variable is reset to a sentinal
-     *  value of -1.
-     */
-    private var _failoverIndex:int;
+    private var _connectTimer:Timer;
+
+	/**
+	 *  @private
+	 *  Current index into failover URIs during a failover attempt.
+	 *  When not failing over, this variable is reset to a sentinal
+	 *  value of -1.
+	 */
+	private var _failoverIndex:int;

     /**
      * @private
      * Flag indicating whether the endpoint has been calculated from the uri.
-     */
+     */
     private var _isEndpointCalculated:Boolean;

     /**
@@ -270,21 +228,21 @@
      *  Flag indicating whether this Channel owns the wait guard for managing initial connect attempts.
      */
     private var _ownsWaitGuard:Boolean;
-
+
     /**
      *  @private
      *  Indicates whether the Channel was previously connected successfully. Used for pinned reconnect
      *  attempts before trying failover options.
      */
     private var _previouslyConnected:Boolean;
-
-    /**
-     *  @private
-     *  Primary URI; the initial URI for this channel.
-     */
-    private var _primaryURI:String
-
-    /**
+
+	/**
+	 *  @private
+	 *  Primary URI; the initial URI for this channel.
+	 */
+	private var _primaryURI:String
+
+	/**
      *  @private
      *  Used for pinned reconnect attempts.
      */
@@ -296,40 +254,34 @@
     /**
      *  @private
      */
-    private var resourceManager:IResourceManager = ResourceManager.getInstance();
-
-    //--------------------------------------------------------------------------
+    private var resourceManager:IResourceManager = ResourceManager.getInstance();
+
+	//--------------------------------------------------------------------------
     //
     // Properties
-    //
-    //--------------------------------------------------------------------------
-
-    //----------------------------------
-    //  channelSets
-    //----------------------------------
-
+    //
+    //--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  channelSets
+	//----------------------------------
+
     /**
      *  @private
      */
     private var _channelSets:Array = [];
-
+
     /**
      *  Provides access to the ChannelSets connected to the Channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     public function get channelSets():Array
     {
-        return _channelSets;
-    }
-
-    //----------------------------------
-    //  connected
-    //----------------------------------
+        return _channelSets;
+    }
+
+	//----------------------------------
+	//  connected
+	//----------------------------------

     /**
      *  @private
@@ -337,121 +289,103 @@
     private var _connected:Boolean = false;

     [Bindable(event="propertyChange")]
-    /**
-     *  Indicates whether this channel has established a connection to the
-     *  remote destination.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function get connected():Boolean
-    {
-        return _connected;
-    }
-
-    /**
-     *  @private
-     */
-    protected function setConnected(value:Boolean):void
-    {
-        if (_connected != value)
-        {
-            if (_connected)
-               _previouslyConnected = true;
-
-            var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "connected", _connected, value)
-            _connected = value;
-            dispatchEvent(event);
-            if (!value)
-                setAuthenticated(false);
-        }
-    }
-
-    //----------------------------------
-    //  connectTimeout
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _connectTimeout:int = -1;
-
-    /**
-     *  Provides access to the connect timeout in seconds for the channel.
-     *  A value of 0 or below indicates that a connect attempt will never
+	/**
+	 *  Indicates whether this channel has established a connection to the
+	 *  remote destination.
+	 */
+	public function get connected():Boolean
+	{
+	    return _connected;
+	}
+
+	/**
+	 *  @private
+	 */
+	protected function setConnected(value:Boolean):void
+	{
+	    if (_connected != value)
+	    {
+	        if (_connected)
+	           _previouslyConnected = true;
+
+	        var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "connected", _connected, value)
+	        _connected = value;
+	        dispatchEvent(event);
+	        if (!value)
+	            setAuthenticated(false);
+        }
+	}
+
+	//----------------------------------
+	//  connectTimeout
+	//----------------------------------
+
+    /**
+	 *  @private
+	 */
+	private var _connectTimeout:int = -1;
+
+	/**
+     *  Provides access to the connect timeout in seconds for the channel.
+     *  A value of 0 or below indicates that a connect attempt will never
      *  be timed out on the client.
      *  For channels that are configured to failover, this value is the total
      *  time to wait for a connection to be established.
-     *  It is not reset for each failover URI that the channel may attempt
+     *  It is not reset for each failover URI that the channel may attempt
      *  to connect to.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
+     */
     public function get connectTimeout():int
     {
         return _connectTimeout;
     }
-
-    /**
-     *  @private
-     */
-    public function set connectTimeout(value:int):void
-    {
-        _connectTimeout = value;
-    }
-
-    //----------------------------------
-    //  endpoint
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _endpoint:String;
-
-    /**
-     *  Provides access to the endpoint for this channel.
-     *  This value is calculated based on the value of the uri
-     *  property.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function get endpoint():String
-    {
-        if (!_isEndpointCalculated)
-            calculateEndpoint();
-        return _endpoint;
-    }
-
-    //----------------------------------
-    //  loginAfterDisconnect
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    protected var _loginAfterDisconnect:Boolean = false;
-
+
+	/**
+	 *  @private
+	 */
+	public function set connectTimeout(value:int):void
+	{
+	    _connectTimeout = value;
+    }
+
+	//----------------------------------
+	//  endpoint
+	//----------------------------------
+
+    /**
+     *  @private
+     */
+	private var _endpoint:String;
+
+	/**
+	 *  Provides access to the endpoint for this channel.
+	 *  This value is calculated based on the value of the uri
+	 *  property.
+	 */
+	public function get endpoint():String
+	{
+	    if (!_isEndpointCalculated)
+    	    calculateEndpoint();
+	    return _endpoint;
+	}
+
+	//----------------------------------
+	//  loginAfterDisconnect
+	//----------------------------------
+
+    /**
+     *  @private
+     */
+    protected var _loginAfterDisconnect:Boolean = false;
+
     mx_internal function get loginAfterDisconnect():Boolean
     {
-        return _loginAfterDisconnect;
-    }
-
-    //----------------------------------
-    //  recordMessageTimes
-    //----------------------------------
-
+    	return _loginAfterDisconnect;
+    }
+
+	//----------------------------------
+	//  recordMessageTimes
+	//----------------------------------
+
     /**
      * @private
      */
@@ -459,23 +393,17 @@

     /**
      * Channel property determines the level of performance information injection - whether
-     * we inject timestamps or not.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
+     * we inject timestamps or not.
      */
     public function get recordMessageTimes():Boolean
     {
-        return _recordMessageTimes;
-    }
-
-    //----------------------------------
-    //  recordMessageSizes
-    //----------------------------------
-
+    	return _recordMessageTimes;
+    }
+
+	//----------------------------------
+	//  recordMessageSizes
+	//----------------------------------
+
     /**
      * @private
      */
@@ -484,185 +412,149 @@
     /**
      * Channel property determines the level of performance information injection - whether
      * we inject message sizes or not.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
+     */
     public function get recordMessageSizes():Boolean
     {
-        return _recordMessageSizes;
-    }
-
-    //----------------------------------
-    //  reconnecting
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _reconnecting:Boolean = false;
+    	return _recordMessageSizes;
+    }
+
+	//----------------------------------
+	//  reconnecting
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	private var _reconnecting:Boolean = false;

     [Bindable(event="propertyChange")]
     /**
      *  Indicates whether this channel is in the process of reconnecting to an
      *  alternate endpoint.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     public function get reconnecting():Boolean
     {
         return _reconnecting;
     }
-
+
     private function setReconnecting(value:Boolean):void
     {
         if (_reconnecting != value)
-        {
-            var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "reconnecting", _reconnecting, value);
-            _reconnecting = value;
-            dispatchEvent(event);
-        }
-    }
-
-    //----------------------------------
-    //  failoverURIs
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _failoverURIs:Array;
-
-    /**
+	    {
+	        var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "reconnecting", _reconnecting, value);
+	        _reconnecting = value;
+	        dispatchEvent(event);
+        }
+    }
+
+	//----------------------------------
+	//  failoverURIs
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	private var _failoverURIs:Array;
+
+	/**
      *  Provides access to the set of endpoint URIs that this channel can
-     *  attempt to failover to if the endpoint is clustered.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
+	 *  attempt to failover to if the endpoint is clustered.
+     */
     public function get failoverURIs():Array
     {
         return (_failoverURIs != null) ? _failoverURIs : [];
     }
-
-    /**
-     *  @private
-     */
-    public function set failoverURIs(value:Array):void
-    {
-        if (value != null)
-        {
-            _failoverURIs = value;
-            _failoverIndex = -1; // Reset the index, because URIs have changed
-        }
-    }
-
-    //----------------------------------
-    //  id
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _id:String;
-
-    /**
-     *  Provides access to the id of this channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function get id():String
-    {
-        return _id;
-    }
-
-    public function set id(value:String):void
-    {
-        if (_id != value)
-            _id = value;
-    }
-
-    //----------------------------------
-    //  authenticated
-    //----------------------------------
+
+	/**
+	 *  @private
+	 */
+	public function set failoverURIs(value:Array):void
+	{
+	    if (value != null)
+	    {
+	        _failoverURIs = value;
+	        _failoverIndex = -1; // Reset the index, because URIs have changed
+	    }
+    }
+
+	//----------------------------------
+	//  id
+	//----------------------------------
+
+	/**
+	 *  @private
+	 */
+	private var _id:String;
+
+	/**
+	 *  Provides access to the id of this channel.
+	 */
+	public function get id():String
+	{
+	    return _id;
+	}
+
+	public function set id(value:String):void
+	{
+	    if (_id != value)
+	        _id = value;
+	}
+
+	//----------------------------------
+	//  authenticated
+	//----------------------------------

     private var _authenticated:Boolean = false;
-
+
     [Bindable(event="propertyChange")]
-    /**
-     *  Indicates if this channel is authenticated.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function get authenticated():Boolean
-    {
-        return _authenticated;
-    }
-
-    mx_internal function setAuthenticated(value:Boolean):void
-    {
-        if (value != _authenticated)
-        {
-            var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "authenticated", _authenticated, value);
-            _authenticated = value;
-
-            var cs:ChannelSet;
-            for (var i:int = 0; i < _channelSets.length; i++)
-            {
-                cs = ChannelSet(_channelSets[i]);
-                cs.mx_internal::setAuthenticated(authenticated, credentials)
-            }
-
-            dispatchEvent(event);
-        }
-    }
-
-    //----------------------------------
-    //  protocol
-    //----------------------------------
+	/**
+	 *  Indicates if this channel is authenticated.
+     */
+	public function get authenticated():Boolean
+	{
+	    return _authenticated;
+	}
+
+	mx_internal function setAuthenticated(value:Boolean):void
+	{
+	    if (value != _authenticated)
+	    {
+	        var event:PropertyChangeEvent = PropertyChangeEvent.createUpdateEvent(this, "authenticated", _authenticated, value);
+	        _authenticated = value;
+
+	        var cs:ChannelSet;
+	        for (var i:int = 0; i < _channelSets.length; i++)
+	        {
+	            cs = ChannelSet(_channelSets[i]);
+	            cs.mx_internal::setAuthenticated(authenticated, credentials)
+	        }
+
+	        dispatchEvent(event);
+	    }
+	}
+
+	//----------------------------------
+	//  protocol
+	//----------------------------------

     /**
      *  Provides access to the protocol that the channel uses.
      *
-     *
Note: Subclasses of Channel must override this method and return
+     *
Note: Subclasses of Channel must override this method and return
      *  a string that represents their supported protocol.
      *  Examples of supported protocol strings are "rtmp", "http" or "https".
      *

-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     public function get protocol():String
     {
         throw new IllegalOperationError("Channel subclasses must override "
             + "the get function for 'protocol' to return the proper protocol "
-            + "string.");
-    }
-
-    //----------------------------------
-    //  realtime
-    //----------------------------------
+            + "string.");
+    }
+
+	//----------------------------------
+	//  realtime
+	//----------------------------------

     /**
      *  @private
@@ -672,122 +564,104 @@
     {
         return false;
     }
-
-    //----------------------------------
-    //  requestTimeout
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _requestTimeout:int = -1;
-
-    /**
-     *  Provides access to the default request timeout in seconds for the
-     *  channel. A value of 0 or below indicates that outbound requests will
+
+	//----------------------------------
+	//  requestTimeout
+	//----------------------------------
+
+    /**
+	 *  @private
+	 */
+	private var _requestTimeout:int = -1;
+
+	/**
+     *  Provides access to the default request timeout in seconds for the
+     *  channel. A value of 0 or below indicates that outbound requests will
      *  never be timed out on the client.
-     *
Request timeouts are most useful for RPC style messaging that
+     *
Request timeouts are most useful for RPC style messaging that
      *  requires a response from the remote destination.

-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
+     */
     public function get requestTimeout():int
     {
         return _requestTimeout;
     }
-
-    /**
-     *  @private
-     */
-    public function set requestTimeout(value:int):void
-    {
-        _requestTimeout = value;
+
+	/**
+	 *  @private
+	 */
+	public function set requestTimeout(value:int):void
+	{
+	    _requestTimeout = value;
     }

     //----------------------------------
     //  shouldBeConnected
     //----------------------------------
-
-    /**
-     *  @private
+
+    /**
+     *  @private
      */
     private var _shouldBeConnected:Boolean;
-
+
     /**
      *  Indicates whether this channel should be connected to its endpoint.
      *  This flag is used to control when fail over should be attempted and when disconnect
      *  notification is sent to the remote endpoint upon disconnect or fault.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     protected function get shouldBeConnected():Boolean
     {
         return _shouldBeConnected;
     }

-    //----------------------------------
-    //  uri
-    //----------------------------------
-
-    /**
-     *  @private
-     */
-    private var _uri:String;
-
-    /**
-     *  Provides access to the URI used to create the whole endpoint URI for this channel.
-     *  The URI can be a partial path, in which case the full endpoint URI is computed as necessary.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function get uri():String
-    {
-        return _uri;
-    }
+	//----------------------------------
+	//  uri
+	//----------------------------------
+
+	/**
+     *  @private
+     */
+	private var _uri:String;
+
+	/**
+	 *  Provides access to the URI used to create the whole endpoint URI for this channel.
+	 *  The URI can be a partial path, in which case the full endpoint URI is computed as necessary.
+	 */
+	public function get uri():String
+	{
+	    return _uri;
+	}

     public function set uri(value:String):void
     {
         if (value != null)
         {
             _uri = value;
-            calculateEndpoint();
-        }
-    }
+            calculateEndpoint();
+        }
+    }
+
+	/**
+	 * @private
+	 * This alternate property for an endpoint URL is provided to match the
+	 * endpoint configuration attribute "url". This property is
+	 * equivalent to the uri property.
+	 */
+	public function get url():String
+	{
+	    return uri;
+	}

     /**
      * @private
-     * This alternate property for an endpoint URL is provided to match the
-     * endpoint configuration attribute "url". This property is
-     * equivalent to the uri property.
-     */
-    public function get url():String
-    {
-        return uri;
-    }
-
-    /**
-     * @private
      */
     public function set url(value:String):void
     {
         uri = value;
     }

-    //----------------------------------
-    //  useSmallMessages
-    //----------------------------------
+	//----------------------------------
+	//  useSmallMessages
+	//----------------------------------

     /**
      * @private
@@ -817,7 +691,7 @@
     //--------------------------------------------------------------------------
     //
     // Methods
-    //
+    //
     //--------------------------------------------------------------------------

     /**
@@ -836,17 +710,11 @@
      *    </properties>
      *  </channel>
      *

-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function applySettings(settings:XML):void
-    {
-        if (Log.isInfo())
-            _log.info("'{0}' channel settings are:\n{1}", id, settings);
+     */
+	public function applySettings(settings:XML):void
+	{
+	    if (Log.isInfo())
+	        _log.info("'{0}' channel settings are:\n{1}", id, settings);

         if (settings.properties.length() != 0)
         {
@@ -861,9 +729,9 @@
                 _recordMessageSizes = props[RECORD_MESSAGE_SIZES].toString()== TRUE;
             var serializationProps:XMLList = props[SERIALIZATION];
             if (serializationProps.length() != 0 && serializationProps[ENABLE_SMALL_MESSAGES].toString()== FALSE)
-                enableSmallMessages = false;
-        }
-    }
+           		    enableSmallMessages = false;
+           	}
+        }

     /**
      *  Applies the client load balancing urls if they exists. It randomly picks
@@ -873,12 +741,6 @@
      *
      *  @param props The properties section of the XML fragment of the services-config.xml
      *  file for this channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     protected function applyClientLoadBalancingSettings(props:XML):void
     {
@@ -906,45 +768,39 @@
         var failoverURIs:Array = urls.slice(1);
         if (failoverURIs.length > 0)
             this.failoverURIs = failoverURIs;
-    }
-
-    /**
-     *  Connects the ChannelSet to the Channel. If the Channel has not yet
-     *  connected to its endpoint, it attempts to do so.
-     *  Channel subclasses must override the internalConnect()
-     *  method, and call the connectSuccess() method once the
-     *  underlying connection is established.
-     *
-     *  @param channelSet The ChannelSet to connect to the Channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    final public function connect(channelSet:ChannelSet):void
-    {
-        var exists:Boolean = false;
-        var n:int = _channelSets.length;
-        for (var i:int = 0; i < _channelSets.length; i++)
+	}
+
+	/**
+	 *  Connects the ChannelSet to the Channel. If the Channel has not yet
+	 *  connected to its endpoint, it attempts to do so.
+	 *  Channel subclasses must override the internalConnect()
+	 *  method, and call the connectSuccess() method once the
+	 *  underlying connection is established.
+	 *
+	 *  @param channelSet The ChannelSet to connect to the Channel.
+	 */
+	final public function connect(channelSet:ChannelSet):void
+	{
+	    var exists:Boolean = false;
+		var n:int = _channelSets.length;
+		for (var i:int = 0; i < _channelSets.length; i++)
         {
             if (_channelSets[i] == channelSet)
             {
                 exists = true;
-                break;
+                break;
             }
         }
-
-        _shouldBeConnected = true;
-        if (!exists)
-        {
-            _channelSets.push(channelSet);
-            // Wire up ChannelSet's channel event listeners.
-            addEventListener(ChannelEvent.CONNECT, channelSet.channelConnectHandler);
-            addEventListener(ChannelEvent.DISCONNECT, channelSet.channelDisconnectHandler);
-            addEventListener(ChannelFaultEvent.FAULT, channelSet.channelFaultHandler);
-        }
+
+		_shouldBeConnected = true;
+		if (!exists)
+		{
+			_channelSets.push(channelSet);
+			// Wire up ChannelSet's channel event listeners.
+	        addEventListener(ChannelEvent.CONNECT, channelSet.channelConnectHandler);
+	        addEventListener(ChannelEvent.DISCONNECT, channelSet.channelDisconnectHandler);
+	        addEventListener(ChannelFaultEvent.FAULT, channelSet.channelFaultHandler);
+        }
         // If we are already connected, notify the ChannelSet. Otherwise connect
         // if necessary.
         if (connected)
@@ -952,9 +808,9 @@
             channelSet.channelConnectHandler(ChannelEvent.createEvent(ChannelEvent.CONNECT, this, false, false, connected));
         }
         else if (!_connecting)
-        {
+        {
             _connecting = true;
-
+
             // If a connect timeout is defined, start the corresponding timer.
             if (connectTimeout > 0)
             {
@@ -962,7 +818,7 @@
                 _connectTimer.addEventListener(TimerEvent.TIMER, connectTimeoutHandler);
                 _connectTimer.start();
             }
-
+
             // We have to prevent a race between multipe Channel instances attempting to connect concurrently
             // at application startup. We detect this situation by testing whether the FlexClient Id has been assigned or not.
             if (FlexClient.getInstance().id == null)
@@ -980,7 +836,7 @@
                 {
                     // This Channel should wait to attempt to connect.
                     flexClient.addEventListener(PropertyChangeEvent.PROPERTY_CHANGE, flexClientWaitHandler);
-                }
+                }
             }
             else
             {
@@ -988,55 +844,49 @@
                 internalConnect();
             }
         }
-    }
-
-    /**
-     *  Disconnects the ChannelSet from the Channel. If the Channel is connected
-     *  to its endpoint and it has no more connected ChannelSets it will
-     *  internally disconnect.
-     *
-     *
Channel subclasses need to override the
-     *  internalDisconnect() method, and call the
-     *  disconnectSuccess() method when the underlying connection
-     *  has been terminated.

-     *
-     *  @param channelSet The ChannelSet to disconnect from the Channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    final public function disconnect(channelSet:ChannelSet):void
-    {
-        // If we own the wait guard for initial Channel connects release it.
-        // This will only be true if this Channel is the first to attempt to connect
-        // but its connect attempt is still pending when disconnect() is invoked.
-        if (_ownsWaitGuard)
-        {
-            _ownsWaitGuard = false;
-            FlexClient.getInstance().waitForFlexClientId = false; // Allow other Channels to connect.
-        }
-
-        // Disconnect the channelSet.
-        var i:int = channelSet != null ? _channelSets.indexOf(channelSet) : -1;
+	}
+
+	/**
+	 *  Disconnects the ChannelSet from the Channel. If the Channel is connected
+	 *  to its endpoint and it has no more connected ChannelSets it will
+	 *  internally disconnect.
+	 *
+	 *
Channel subclasses need to override the
+	 *  internalDisconnect() method, and call the
+	 *  disconnectSuccess() method when the underlying connection
+	 *  has been terminated.

+	 *
+	 *  @param channelSet The ChannelSet to disconnect from the Channel.
+	 */
+	final public function disconnect(channelSet:ChannelSet):void
+	{
+	    // If we own the wait guard for initial Channel connects release it.
+	    // This will only be true if this Channel is the first to attempt to connect
+	    // but its connect attempt is still pending when disconnect() is invoked.
+	    if (_ownsWaitGuard)
+	    {
+	        _ownsWaitGuard = false;
+	        FlexClient.getInstance().waitForFlexClientId = false; // Allow other Channels to connect.
+	    }
+
+	    // Disconnect the channelSet.
+	    var i:int = channelSet != null ? _channelSets.indexOf(channelSet) : -1;
         if (i != -1)
         {
             _channelSets.splice(i, 1);
             // Remove the ChannelSet as a listener to this Channel.
             removeEventListener(ChannelEvent.CONNECT, channelSet.channelConnectHandler, false);
-            removeEventListener(ChannelEvent.DISCONNECT, channelSet.channelDisconnectHandler, false);
+            removeEventListener(ChannelEvent.DISCONNECT, channelSet.channelDisconnectHandler, false);
             removeEventListener(ChannelFaultEvent.FAULT, channelSet.channelFaultHandler, false);
-
-            // Notify the ChannelSet of the disconnect.
-            if (connected)
-            {
+
+            // Notify the ChannelSet of the disconnect.
+            if (connected)
+            {
                 channelSet.channelDisconnectHandler(ChannelEvent.createEvent(ChannelEvent.DISCONNECT, this, false));
             }
-
-            // Shut down the underlying connection if this Channel has no more
-            // ChannelSets using it.
+
+    	    // Shut down the underlying connection if this Channel has no more
+    	    // ChannelSets using it.
             if (_channelSets.length == 0)
             {
                 _shouldBeConnected = false;
@@ -1044,24 +894,18 @@
                     internalDisconnect();
             }
         }
-    }
-
-    /**
-     *  Sends a CommandMessage to the server to logout if the Channel is connected.
-     *  Current credentials are cleared.
-     *
-     *  @param agent The MessageAgent to logout.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function logout(agent:MessageAgent):void
+	}
+
+	/**
+	 *  Sends a CommandMessage to the server to logout if the Channel is connected.
+	 *  Current credentials are cleared.
+	 *
+	 *  @param agent The MessageAgent to logout.
+	 */
+	public function logout(agent:MessageAgent):void
     {
         if ((connected && authenticated && credentials) || (authenticating && credentials))
-        {
+        {
             var msg:CommandMessage = new CommandMessage();
             msg.operation = CommandMessage.LOGOUT_OPERATION;
             internalSend(new AuthenticationMessageResponder(agent, msg, this, _log));
@@ -1070,107 +914,95 @@
         credentials = null;
     }

-    /**
-     *  Sends the specified message to its target destination.
-     *  Subclasses must override the internalSend() method to
-     *  perform the actual send.
+	/**
+	 *  Sends the specified message to its target destination.
+	 *  Subclasses must override the internalSend() method to
+	 *  perform the actual send.
      *
-     *  @param agent The MessageAgent that is sending the message.
-     *
-     *  @param message The Message to send.
-     *
-     *  @throws mx.messaging.errors.InvalidDestinationError If neither the MessageAgent nor the
-     *                                  message specify a destination.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function send(agent:MessageAgent, message:IMessage):void
-    {
+	 *  @param agent The MessageAgent that is sending the message.
+	 *
+	 *  @param message The Message to send.
+	 *
+	 *  @throws mx.messaging.errors.InvalidDestinationError If neither the MessageAgent nor the
+	 *                                  message specify a destination.
+	 */
+	public function send(agent:MessageAgent, message:IMessage):void
+	{
         // Set the destination header of the message if it is not already set.
         if (message.destination.length == 0)
         {
             if (agent.destination.length == 0)
-            {
-                var msg:String = resourceManager.getString(
-                    "messaging", "noDestinationSpecified");
+			{
+				var msg:String = resourceManager.getString(
+					"messaging", "noDestinationSpecified");
                 throw new InvalidDestinationError(msg);
-            }
+			}
             message.destination = agent.destination;
         }

         if (Log.isDebug())
             _log.debug("'{0}' channel sending message:\n{1}", id, message.toString());

-        // Tag the message with a header indicating the Channel/Endpoint used for transport.
+        // Tag the message with a header indicating the Channel/Endpoint used for transport.
         message.headers[AbstractMessage.ENDPOINT_HEADER] = id;

         var responder:MessageResponder = getMessageResponder(agent, message);
         initializeRequestTimeout(responder);
         internalSend(responder);
-    }
-
-    /**
-     *  Sets the credentials to the specified value.
-     *  If the credentials are non-null and the Channel is connected, this method also
-     *  sends a CommandMessage to the server to login using the credentials.
-     *
-     *  @param credentials The credentials string.
-     *  @param agent The MessageAgent to login, that will handle the login result.
+	}
+
+	/**
+	 *  Sets the credentials to the specified value.
+	 *  If the credentials are non-null and the Channel is connected, this method also
+	 *  sends a CommandMessage to the server to login using the credentials.
+	 *
+	 *  @param credentials The credentials string.
+	 *  @param agent The MessageAgent to login, that will handle the login result.
      *  @param charset The character set encoding used while encoding the
      *  credentials. The default is null, which implies the legacy charset of
      *  ISO-Latin-1.
-     *
-     *  @throws flash.errors.IllegalOperationError in two situations; if credentials
-     *  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.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    public function setCredentials(credentials:String, agent:MessageAgent=null, charset:String=null):void
-    {
-        var changedCreds:Boolean = this.credentials !== credentials;
-
-        if (authenticating && changedCreds)
-            throw new IllegalOperationError("Credentials cannot be set while authenticating or logging out.");
-
-        if (authenticated && changedCreds)
-            throw new IllegalOperationError("Credentials cannot be set when already authenticated. Logout must be performed before changing credentials.");
-
-        this.credentials = credentials;
-        if (connected && changedCreds && credentials != null)
-        {
+	 *
+	 *  @throws flash.errors.IllegalOperationError in two situations; if credentials
+	 *  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.
+	 */
+	public function setCredentials(credentials:String, agent:MessageAgent=null, charset:String=null):void
+	{
+	    var changedCreds:Boolean = this.credentials !== credentials;
+
+	    if (authenticating && changedCreds)
+	        throw new IllegalOperationError("Credentials cannot be set while authenticating or logging out.");
+
+	    if (authenticated && changedCreds)
+	        throw new IllegalOperationError("Credentials cannot be set when already authenticated. Logout must be performed before changing credentials.");
+
+	    this.credentials = credentials;
+	    if (connected && changedCreds && credentials != null)
+	    {
             authenticating = true;
-            var msg:CommandMessage = new CommandMessage();
-            msg.operation = CommandMessage.LOGIN_OPERATION;
-            msg.body = credentials;
-            if (charset != null)
-                msg.headers[CommandMessage.CREDENTIALS_CHARSET_HEADER] = charset;
-            internalSend(new AuthenticationMessageResponder(agent, msg, this, _log));
-        }
-    }
-
-    /**
-     * @private
+	        var msg:CommandMessage = new CommandMessage();
+	        msg.operation = CommandMessage.LOGIN_OPERATION;
+	        msg.body = credentials;
+	        if (charset != null)
+	            msg.headers[CommandMessage.CREDENTIALS_CHARSET_HEADER] = charset;
+    	    internalSend(new AuthenticationMessageResponder(agent, msg, this, _log));
+	    }
+	}
+
+    /**
+     * @private
      * Should we record any performance metrics
-     */
+     */
     public function get mpiEnabled():Boolean
     {
-        return _recordMessageSizes || _recordMessageTimes;
-    }
+    	return _recordMessageSizes || _recordMessageTimes;
+    }

     //--------------------------------------------------------------------------
     //
     // Internal Methods
-    //
+    //
     //--------------------------------------------------------------------------

     /**
@@ -1185,222 +1017,186 @@

     /**
      *  @private
-     *  This is a hook for ChannelSet (not a MessageAgent) to send requests for
-     *  clustered endpoints for a clustered destination and provide its own
-     *  custom responder, rather than relying on the generic responders used by
+     *  This is a hook for ChannelSet (not a MessageAgent) to send requests for
+     *  clustered endpoints for a clustered destination and provide its own
+     *  custom responder, rather than relying on the generic responders used by
      *  Channel implemenations.
-     *
+     *
      *  @param msgResp The message responder to use for the cluster request response.
      */
-    mx_internal function sendClusterRequest(msgResp:MessageResponder):void
-    {
-        internalSend(msgResp);
-    }
+	mx_internal function sendClusterRequest(msgResp:MessageResponder):void
+	{
+	    internalSend(msgResp);
+	}

     //--------------------------------------------------------------------------
     //
     // Protected Methods
-    //
-    //--------------------------------------------------------------------------
-
-    /**
-     *  Processes a failed internal connect and dispatches the
-     *  FAULT event for the channel.
-     *  If the Channel has failoverURI values, it will
-     *  attempt to reconnect automatically by trying these URI values in order until
-     *  a connection is established or the available values are exhausted.
-     *
-     *  @param event The ChannelFaultEvent for the failed connect.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function connectFailed(event:ChannelFaultEvent):void
-    {
-        shutdownConnectTimer();
-        setConnected(false);
-
-        if (Log.isError())
+    //
+    //--------------------------------------------------------------------------
+
+	/**
+	 *  Processes a failed internal connect and dispatches the
+	 *  FAULT event for the channel.
+	 *  If the Channel has failoverURI values, it will
+	 *  attempt to reconnect automatically by trying these URI values in order until
+	 *  a connection is established or the available values are exhausted.
+	 *
+	 *  @param event The ChannelFaultEvent for the failed connect.
+	 */
+	protected function connectFailed(event:ChannelFaultEvent):void
+	{
+	    shutdownConnectTimer();
+	    setConnected(false);
+
+	    if (Log.isError())
             _log.error("'{0}' channel connect failed.", id);
-
+
         if (!event.rejected && shouldAttemptFailover())
         {
             _connecting = true;
-            failover();
+	        failover();
         }
         else // Not attempting failover.
         {
-            connectCleanup();
-        }
-
+    	    connectCleanup();
+        }
+
         if (reconnecting)
             event.reconnecting = true;
         dispatchEvent(event);
-    }
-
-    /**
-     *  Processes a successful internal connect and dispatches the
-     *  CONNECT event for the Channel.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function connectSuccess():void
-    {
-        shutdownConnectTimer();
-
+	}
+
+	/**
+	 *  Processes a successful internal connect and dispatches the
+	 *  CONNECT event for the Channel.
+	 */
+	protected function connectSuccess():void
+	{
+	    shutdownConnectTimer();
+
         // If there were any attached agents that needed configuration they
         // should be reset.
         if (ServerConfig.fetchedConfig(endpoint))
         {
-            for (var i:int = 0; i < channelSets.length; i++)
+    		for (var i:int = 0; i < channelSets.length; i++)
             {
                 var messageAgents:Array = ChannelSet(channelSets[i]).messageAgents;
                 for (var j:int = 0; j < messageAgents.length; j++)
-                {
+				{
                     messageAgents[j].needsConfig = false;
-                }
+				}
             }
         }
-
-        setConnected(true);
-        _failoverIndex = -1;
-
+
+	    setConnected(true);
+	    _failoverIndex = -1;
+
+	    if (Log.isInfo())
+	        _log.info("'{0}' channel is connected.", id);
+
+	    dispatchEvent(ChannelEvent.createEvent(ChannelEvent.CONNECT, this, reconnecting));
+
+        connectCleanup();
+	}
+
+	/**
+	 *  Handles a connect timeout by dispatching a ChannelFaultEvent.
+	 *  Subtypes may overide this to shutdown the current connect attempt but must
+	 *  call super.connectTimeoutHandler(event).
+	 *
+	 *  @param event The timer event indicating that the connect timeout has been reached.
+	 */
+	protected function connectTimeoutHandler(event:TimerEvent):void
+	{
+	    shutdownConnectTimer();
+	    if (!connected)
+	    {
+    	    _shouldBeConnected = false;
+    	    var errorText:String = resourceManager.getString(
+				"messaging", "connectTimedOut");
+    	    var faultEvent:ChannelFaultEvent = ChannelFaultEvent.createEvent(this, false, "Channel.Connect.Failed", "error", errorText);
+    	    connectFailed(faultEvent);
+    	}
+	}
+
+	/**
+	 *  Processes a successful internal disconnect and dispatches the
+	 *  DISCONNECT event for the Channel.
+	 *  If the disconnect is due to a network failure and the Channel has
+	 *  failoverURI values, it will attempt to reconnect automatically
+	 *  by trying these URI values in order until a connection is established or the
+	 *  available values are exhausted.
+	 *
+	 *  @param rejected True if the disconnect should skip any
+	 *         failover processing that would otherwise be attempted; false
+	 *         if failover processing should be allowed to run.
+	 */
+	protected function disconnectSuccess(rejected:Boolean = false):void
+	{
+	    setConnected(false);
+
         if (Log.isInfo())
-            _log.info("'{0}' channel is connected.", id);
-
-        dispatchEvent(ChannelEvent.createEvent(ChannelEvent.CONNECT, this, reconnecting));
-
-        connectCleanup();
-    }
-
-    /**
-     *  Handles a connect timeout by dispatching a ChannelFaultEvent.
-     *  Subtypes may overide this to shutdown the current connect attempt but must
-     *  call super.connectTimeoutHandler(event).
-     *
-     *  @param event The timer event indicating that the connect timeout has been reached.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function connectTimeoutHandler(event:TimerEvent):void
-    {
-        shutdownConnectTimer();
-        if (!connected)
-        {
-            _shouldBeConnected = false;
-            var errorText:String = resourceManager.getString(
-                "messaging", "connectTimedOut");
-            var faultEvent:ChannelFaultEvent = ChannelFaultEvent.createEvent(this, false, "Channel.Connect.Failed", "error", errorText);
-            connectFailed(faultEvent);
-        }
-    }
-
-    /**
-     *  Processes a successful internal disconnect and dispatches the
-     *  DISCONNECT event for the Channel.
-     *  If the disconnect is due to a network failure and the Channel has
-     *  failoverURI values, it will attempt to reconnect automatically
-     *  by trying these URI values in order until a connection is established or the
-     *  available values are exhausted.
-     *
-     *  @param rejected True if the disconnect should skip any
-     *         failover processing that would otherwise be attempted; false
-     *         if failover processing should be allowed to run.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function disconnectSuccess(rejected:Boolean = false):void
-    {
-        setConnected(false);
-
-        if (Log.isInfo())
-            _log.info("'{0}' channel disconnected.", id);
-
-        if (!rejected && shouldAttemptFailover())
-        {
-            _connecting = true;
-            failover();
-        }
-        else
-        {
-            connectCleanup();
-        }
-
-        dispatchEvent(ChannelEvent.createEvent(ChannelEvent.DISCONNECT, this,
-                                            reconnecting, rejected));
-    }
-
-    /**
-     *  Processes a failed internal disconnect and dispatches the
-     *  FAULT event for the channel.
-     *
-     *  @param event The ChannelFaultEvent for the failed disconnect.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function disconnectFailed(event:ChannelFaultEvent):void
-    {
-        _connecting = false;
-        setConnected(false);
-
-        if (Log.isError())
-            _log.error("'{0}' channel disconnect failed.", id);
-
-        if (reconnecting)
-        {
-            resetToPrimaryURI();
-            event.reconnecting = false;
-        }
-        dispatchEvent(event);
-    }
-
-    /**
-     *  Handles a change to the guard condition for managing initial Channel connect for the application.
-     *  When this is invoked it means that this Channel is waiting to attempt to connect.
-     *
-     *  @param event The PropertyChangeEvent dispatched by the FlexClient singleton.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function flexClientWaitHandler(event:PropertyChangeEvent):void
-    {
-        if (event.property == "waitForFlexClientId")
-        {
-            var flexClient:FlexClient = event.source as FlexClient;
-            if (flexClient.waitForFlexClientId == false) // The wait is over, claim it and attempt to connect.
-            {
-                flexClient.removeEventListener(PropertyChangeEvent.PROPERTY_CHANGE, flexClientWaitHandler);
-                flexClient.waitForFlexClientId = true;
-                // This will cause other Channels to wait to attempt to connect.
+		    _log.info("'{0}' channel disconnected.", id);
+
+		if (!rejected && shouldAttemptFailover())
+		{
+		    _connecting = true;
+	        failover();
+	    }
+	    else
+	    {
+	        connectCleanup();
+	    }
+
+		dispatchEvent(ChannelEvent.createEvent(ChannelEvent.DISCONNECT, this,
+		                                    reconnecting, rejected));
+	}
+
+	/**
+	 *  Processes a failed internal disconnect and dispatches the
+	 *  FAULT event for the channel.
+	 *
+	 *  @param event The ChannelFaultEvent for the failed disconnect.
+	 */
+	protected function disconnectFailed(event:ChannelFaultEvent):void
+	{
+	    _connecting = false;
+	    setConnected(false);
+
+	    if (Log.isError())
+	        _log.error("'{0}' channel disconnect failed.", id);
+
+	    if (reconnecting)
+	    {
+	        resetToPrimaryURI();
+	        event.reconnecting = false;
+	    }
+	    dispatchEvent(event);
+	}
+
+	/**
+	 *  Handles a change to the guard condition for managing initial Channel connect for the application.
+	 *  When this is invoked it means that this Channel is waiting to attempt to connect.
+	 *
+	 *  @param event The PropertyChangeEvent dispatched by the FlexClient singleton.
+	 */
+	protected function flexClientWaitHandler(event:PropertyChangeEvent):void
+	{
+	    if (event.property == "waitForFlexClientId")
+	    {
+	        var flexClient:FlexClient = event.source as FlexClient;
+	        if (flexClient.waitForFlexClientId == false) // The wait is over, claim it and attempt to connect.
+	        {
+	            flexClient.removeEventListener(PropertyChangeEvent.PROPERTY_CHANGE, flexClientWaitHandler);
+	            flexClient.waitForFlexClientId = true;
+	            // This will cause other Channels to wait to attempt to connect.
                 // This Channel can continue its attempt.
                 _ownsWaitGuard = true;
-                internalConnect();
-            }
-        }
-    }
+	            internalConnect();
+	        }
+	    }
+	}

     /**
      *  Returns the appropriate MessageResponder for the Channel's
@@ -1408,21 +1204,15 @@
      *  Must be overridden.
      *
      *  @param agent The MessageAgent sending the message.
-     *
+     *
      *  @param message The Message to send.
-     *
+     *
      *  @return The MessageResponder to handle the result or fault.
-     *
+     *
      *  @throws flash.errors.IllegalOperationError If the Channel subclass does not override
      *                                this method.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
-     */
-    protected function getMessageResponder(agent:MessageAgent,
+     */
+    protected function getMessageResponder(agent:MessageAgent,
                                             message:IMessage):MessageResponder
     {
         throw new IllegalOperationError("Channel subclasses must override "
@@ -1432,42 +1222,24 @@
     /**
      *  Connects the Channel to its endpoint.
      *  Must be overridden.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     protected function internalConnect():void {}

     /**
-     *  Disconnects the Channel from its endpoint.
+     *  Disconnects the Channel from its endpoint.
      *  Must be overridden.
-     *
+     *
      *  @param rejected True if the disconnect was due to a connection rejection or timeout
-     * 					and reconnection should not be attempted automatically; otherwise false.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
+     * 					and reconnection should not be attempted automatically; otherwise false.
      */
     protected function internalDisconnect(rejected:Boolean = false):void {}
-
+
     /**
      *  Sends the Message out over the Channel and routes the response to the
      *  responder.
      *  Must be overridden.
-     *
+     *
      *  @param messageResponder The MessageResponder to handle the response.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     protected function internalSend(messageResponder:MessageResponder):void {}

@@ -1484,7 +1256,7 @@
     /**
      *  @private
      *  Utility method used to assign the FlexClient Id value to outbound messages.
-     *
+     *
      *  @param message The message to set the FlexClient Id on.
      */
     protected function setFlexClientIdOnMessage(message:IMessage):void
@@ -1497,11 +1269,11 @@
     //--------------------------------------------------------------------------
     //
     // Private Methods
-    //
-    //--------------------------------------------------------------------------
-
-    /**
-     *  @private
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
      *  This method calculates the endpoint value based on the current
      *  uri.
      */
@@ -1522,12 +1294,12 @@

         if (!URLUtil.hasUnresolvableTokens())
         {
-            _isEndpointCalculated = false;
+            _isEndpointCalculated = false;
             return;
         }
-
+
         uriCopy = URLUtil.replaceTokens(uriCopy);
-
+
         // Now, check for a final protocol after relative URLs and tokens
         // have been replaced
         proto = URLUtil.getProtocol(uriCopy);
@@ -1538,19 +1310,19 @@
             _endpoint = protocol + ":" + uriCopy;

         _isEndpointCalculated = true;
-
+
         if (Log.isInfo())
-            _log.info("'{0}' channel endpoint set to {1}", id, _endpoint);
-    }
-
-    /**
-     *  @private
-     *  Initializes the request timeout for this message if the outbound message
-     *  defines a REQUEST_TIMEOUT_HEADER value.
-     *  If this header is not set and the default requestTimeout for the
-     *  channel is greater than 0, the channel default is used.
+            _log.info("'{0}' channel endpoint set to {1}", id, _endpoint);
+    }
+
+    /**
+     *  @private
+     *  Initializes the request timeout for this message if the outbound message
+     *  defines a REQUEST_TIMEOUT_HEADER value.
+     *  If this header is not set and the default requestTimeout for the
+     *  channel is greater than 0, the channel default is used.
      *  Otherwise, no request timeout is enforced on the client.
-     *
+     *
      *  @param messageResponder The MessageResponder to handle the response and monitor the outbound
      *                          request for a timeout.
      */
@@ -1564,26 +1336,26 @@
         }
         else if (requestTimeout > 0) // Use the channel default.
         {
-            messageResponder.startRequestTimeout(requestTimeout);
-        }
-    }
-
+            messageResponder.startRequestTimeout(requestTimeout);
+        }
+    }
+
     /**
      *  @private
      *  Convenience method to test whether the Channel should attempt to
      *  failover.
-     *
+     *
      *  @return true if the Channel should try to failover;
      *          otherwise false.
      */
     private function shouldAttemptFailover():Boolean
     {
-        return (_shouldBeConnected &&
+        return (_shouldBeConnected &&
                    (_previouslyConnected ||
-                   (reliableReconnectDuration != -1) ||
-                   ((_failoverURIs != null) &&  (_failoverURIs.length > 0))));
-    }
-
+                   (reliableReconnectDuration != -1) ||
+                   ((_failoverURIs != null) &&  (_failoverURIs.length > 0))));
+    }
+
     /**
      *  @private
      *  This method attempts to fail the Channel over to the next available URI.
@@ -1593,17 +1365,17 @@
         // Potentially enter reliable reconnect loop.
         if (_previouslyConnected)
         {
-            _previouslyConnected = false;
-
+            _previouslyConnected = false;
+
             var acs:Class = null;
             try
             {
                 acs = getDefinitionByName("mx.messaging.AdvancedChannelSet") as Class;
-            }
+            }
             catch (ignore:Error) {}
-            var duration:int = -1;
+            var duration:int = -1;
             if (acs != null)
-            {
+            {
                 for each (var channelSet:ChannelSet in channelSets)
                 {
                     if (channelSet is acs)
@@ -1611,10 +1383,10 @@
                         var d:int = (channelSet as acs)["reliableReconnectDuration"];
                         if (d > duration)
                             duration = d;
-                    }
+                    }
                 }
             }
-
+
             if (duration != -1)
             {
                 setReconnecting(true);
@@ -1624,64 +1396,64 @@
                 return; // Exit early.
             }
         }
-
+
         // Potentially continue reliable reconnect loop.
         if (reliableReconnectDuration != -1)
         {
             _reliableReconnectLastTimestamp = new Date().valueOf();
-            var remaining:Number = reliableReconnectDuration - (_reliableReconnectLastTimestamp - _reliableReconnectBeginTimestamp);
+            var remaining:Number = reliableReconnectDuration - (_reliableReconnectLastTimestamp - _reliableReconnectBeginTimestamp);
             if (remaining > 0)
-            {
+            {
                 // Apply exponential backoff.
                 var delay:int = 1000; // 1 second.
                 delay << ++_reliableReconnectAttempts;
                 if (delay < remaining)
                 {
                     new AsyncDispatcher(reconnect, null, delay);
-                    return; // Exit early.
+                    return; // Exit early.
                 }
             }
             // At this point the reliable reconnect duration has been exhausted.
             reliableReconnectCleanup();
         }
-
+
         // General failover handling.
         ++_failoverIndex;
         if ((_failoverIndex + 1) <= failoverURIs.length)
         {
-            setReconnecting(true);
+	        setReconnecting(true);
             uri = failoverURIs[_failoverIndex];
-
+
             if (Log.isInfo())
             {
-                _log.info("'{0}' channel attempting to connect to {1}.", id, endpoint);
+		        _log.info("'{0}' channel attempting to connect to {1}.", id, endpoint);
             }
             // NetConnection based channels may have their underlying resources
             // GC'ed at the end of the execution of the handler that has
-            // invoked this method, which means that the results of a call to
-            // internalConnect() for these channels may magically vanish once
-            // the handler exits.
+            // invoked this method, which means that the results of a call to
+            // internalConnect() for these channels may magically vanish once
+            // the handler exits.
             // A timer introduces a slight delay in the reconnect attempt to
-            // give the handler time to finish executing, at which point the
-            // internals of a NetConnection channel will be stable and we can
+            // give the handler time to finish executing, at which point the
+            // internals of a NetConnection channel will be stable and we can
             // attempt to connect successfully.
-            // This timer is applied to all channels but the impact is small
-            // enough and the failover scenario rare enough that special casing
-            // this for only NetConnection channels is more trouble than it's
-            // worth.
-            new AsyncDispatcher(reconnect, null, 1);
+            // This timer is applied to all channels but the impact is small
+            // enough and the failover scenario rare enough that special casing
+            // this for only NetConnection channels is more trouble than it's
+            // worth.
+            new AsyncDispatcher(reconnect, null, 1);
         }
         else
         {
             if (Log.isInfo())
             {
-                _log.info("'{0}' channel has exhausted failover options and has reset to its primary endpoint.", id);
-            }
+		        _log.info("'{0}' channel has exhausted failover options and has reset to its primary endpoint.", id);
+		    }
             // Nothing left to failover to; reset to primary.
-            resetToPrimaryURI();
-        }
-    }
-
+            resetToPrimaryURI();
+        }
+    }
+
     /**
      *  @private
      *  Cleanup following a connect or failover attempt.
@@ -1694,18 +1466,18 @@
             _ownsWaitGuard = false;
             FlexClient.getInstance().waitForFlexClientId = false; // Allow other Channels to connect.
         }
-
+
         _connecting = false;
-
+
         setReconnecting(false); // Ensure the reconnecting flag is turned off; failover is not being attempted.
-
+
         reliableReconnectCleanup();
     }
-
-    /**
-     *  @private
-     *  This method is invoked by a timer from failover() and it works around a
-     *  reconnect issue with NetConnection based channels by invoking
+
+    /**
+     *  @private
+     *  This method is invoked by a timer from failover() and it works around a
+     *  reconnect issue with NetConnection based channels by invoking
      *  internalConnect() after a slight delay.
      */
     private function reconnect(event:TimerEvent=null):void
@@ -1724,7 +1496,7 @@
         _reliableReconnectLastTimestamp = 0;
         _reliableReconnectAttempts = 0;
     }
-
+
     /**
      *  @private
      *  This method resets the channel back to its primary URI after
@@ -1737,7 +1509,7 @@
         uri = _primaryURI;
         _failoverIndex = -1;
     }
-
+
     /**
      *  @private
      *  Shuffles the array.
@@ -1767,26 +1539,26 @@
         {
             _connectTimer.stop();
             _connectTimer.removeEventListener(TimerEvent.TIMER, connectTimeoutHandler);
-            _connectTimer = null;
+    	    _connectTimer = null;
         }
     }

     //--------------------------------------------------------------------------
     //
     // Static Constants
-    //
+    //
     //--------------------------------------------------------------------------

     /**
      * @private
      */
     public static const SMALL_MESSAGES_FEATURE:String = "small_messages";
-
+
     /**
      *  @private
      *  Creates a compile time dependency on ArrayCollection to ensure
      *  it is present for response data containing collections.
-     */
+     */
     private static const dep:ArrayCollection = null;
 }

@@ -1795,7 +1567,7 @@
 //------------------------------------------------------------------------------
 //
 // Private Classes
-//
+//
 //------------------------------------------------------------------------------

 import mx.core.mx_internal;
@@ -1817,47 +1589,41 @@
  */
 class AuthenticationMessageResponder extends MessageResponder
 {
-    //--------------------------------------------------------------------------
-    //
-    // Constructor
-    //
-    //--------------------------------------------------------------------------
+	//--------------------------------------------------------------------------
+	//
+	// Constructor
+	//
+	//--------------------------------------------------------------------------

     public function AuthenticationMessageResponder(agent:MessageAgent,
                                 message:IMessage, channel:Channel, log:ILogger)
     {
-        super(agent, message, channel);
-        _log = log;
-    }
-
-    //--------------------------------------------------------------------------
-    //
-    // Variables
-    //
-    //--------------------------------------------------------------------------
-
+	    super(agent, message, channel);
+	    _log = log;
+    }
+
+	//--------------------------------------------------------------------------
+	//
+	// Variables
+	//
+	//--------------------------------------------------------------------------
+
     /**
      *  @private
      *  Reference to the logger for the associated Channel.
      */
     private var _log:ILogger;
-
+
     //--------------------------------------------------------------------------
     //
     // Methods
-    //
+    //
     //--------------------------------------------------------------------------

     /**
      *  Handles an authentication result.
-     *
+     *
      *  @param msg The result Message.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     override protected function resultHandler(msg:IMessage):void
     {
@@ -1866,7 +1632,7 @@
         if (cmd.operation == CommandMessage.LOGIN_OPERATION)
         {
             if (Log.isDebug())
-                _log.debug("Login successful");
+                _log.debug("Login successful");

             // we want to set the authenticated property last as it will dispatch
             // an event in this case and handler code shouldn't get called
@@ -1877,30 +1643,24 @@
         {
             if (Log.isDebug())
                 _log.debug("Logout successful");
-
+
             channel.mx_internal::setAuthenticated(false);
         }
     }

     /**
      *  Handles an authentication failure.
-     *
+     *
      *  @param msg The failure Message.
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion BlazeDS 4
-     *  @productversion LCDS 3
      */
     override protected function statusHandler(msg:IMessage):void
     {
         var cmd:CommandMessage = CommandMessage(message);
-
+
         if (Log.isDebug())
         {
-            _log.debug("{1} failure: {0}", msg.toString(),
-                        cmd.operation == CommandMessage.LOGIN_OPERATION ? "Login" : "Logout");
+            _log.debug("{1} failure: {0}", msg.toString(),
+                        cmd.operation == CommandMessage.LOGIN_OPERATION ? "Login" : "Logout");
         }

         channel.mx_internal::authenticating = false;
@@ -1913,11 +1673,11 @@
         else
         {
             var errMsg:ErrorMessage = ErrorMessage(msg);
-            var channelFault:ChannelFaultEvent =
-                                        ChannelFaultEvent.createEvent(channel, false,
-                                        "Channel.Authentication.Error", "warn",
+            var channelFault:ChannelFaultEvent =
+                                        ChannelFaultEvent.createEvent(channel, false,
+                                        "Channel.Authentication.Error", "warn",
                                         errMsg.faultString);
-            channelFault.rootCause = errMsg;
+            channelFault.rootCause = errMsg;
             channel.dispatchEvent(channelFault);
         }
     }


Transferred from the Adobe Open Source Subversion Repository

Revision: 9073
Author:   chaase@adobe.com
Date:     2009-08-04T20:42:36.903355Z

Log Message:
-----------
Fixed a regression with Fade (dealing with non-IVisualElementContainer parented objects, like Popup) and improved seeking behavior with repeatDelay on composite effects. Also improved effect seeking in general, though it's still not perfect.

QE notes: Mustella failure of Sequence_seek_IntoRC2 is erroenous (the test bitmap is wrong, based on bad earlier behavior)
Doc notes: None
Bugs: SDK-22285, sdk-22555
Reviewer: Jason
Tests run: checkintests, Mustella (spark/effects, mx/effects)
Is noteworthy for integration: No

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/Animation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/CompositeEffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Fade.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/SequenceInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/ParallelInstance.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1283599 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/effects/Fade.as
+++ frameworks/projects/spark/src/spark/effects/Fade.as
@@ -11,6 +11,9 @@

 package spark.effects
 {
+import flash.display.DisplayObject;
+import flash.display.MovieClip;
+
 import mx.core.IVisualElement;
 import mx.core.IVisualElementContainer;
 import mx.effects.IEffectInstance;
@@ -161,8 +164,11 @@
             // it has no index value.
             if (container === undefined || container === null)
                 return undefined;
-            return IVisualElementContainer(container).
-                getElementIndex(target as IVisualElement);
+            if (container is IVisualElementContainer)
+                return IVisualElementContainer(container).
+                    getElementIndex(target as IVisualElement);
+            else
+                return container.getChildIndex(target);
         }

         return super.getValueFromTarget(target, property);


iterator

iterator

--- testSrc/com/kemsky/TestStream.as
+++ testSrc/com/kemsky/TestStream.as
@@ -43,6 +43,13 @@

         [Test]
+        public function testMXML():void
+        {
+            var s:Stream = new Stream();
+            s.initialized({}, "");
+        }
+
+        [Test]
         public function testConcat():void
         {
             var s:Stream = $().concat(xml.children());


Transferred from the Adobe Open Source Subversion Repository

Revision: 23246
Author:   cframpto@adobe.com
Date:     2011-12-20T17:40:08.069454Z

Log Message:
-----------
Rollback 23243.  If comment followed header it was stripped as well.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1248819 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/advancedgrids/src/mx/olap/QueryError.as
+++ frameworks/projects/advancedgrids/src/mx/olap/QueryError.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2009 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////

 package mx.olap
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 7743
Author:   clucier@adobe.com
Date:     2009-06-11T13:53:10.203664Z

Log Message:
-----------
Moving away from using namespace qualifiers in most cases in the SDK.  We've run into a few cases now where the use of qualifiers in code that is called excessively can slow things down.
Bugs: SDK-21337
Reviewer: Ryan, Paul
QE Notes: None
Tests: Ran several random Mustella test groups, checkintests.

Modified Paths:
--------------
106 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1278717 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/DataGroup.as
+++ frameworks/projects/spark/src/spark/components/DataGroup.as
@@ -501,7 +501,7 @@
                         item = IDataRenderer(renderer).data;
                     else
                         item = renderer;
-                    mx_internal::itemRemoved(item, index);
+                    itemRemoved(item, index);
                 }
                 indexToRenderer = [];
             }
@@ -518,7 +518,7 @@
                         item = IDataRenderer(renderer).data;
                     else
                         item = renderer;
-                    mx_internal::itemRemoved(item, index);
+                    itemRemoved(item, index);
                 }
                 indexToRenderer = [];

@@ -555,7 +555,7 @@
             if (!vLayout)
             {
                 for (index = 0; index < _dataProvider.length; index++)
-                    mx_internal::itemAdded(_dataProvider.getItemAt(index), index);
+                    itemAdded(_dataProvider.getItemAt(index), index);
             }
             else
             {
@@ -671,7 +671,7 @@

             initializeDataProvider();

-            mx_internal::maskChanged = true;
+            maskChanged = true;
         }

         // Need to initializeDataProvider before calling super.commitProperties
@@ -801,7 +801,7 @@
         if (topLayerItems != null)
         {
             keepLayeringEnabled = true;
-            GroupBase.mx_internal::sortOnLayer(topLayerItems);
+            GroupBase.sortOnLayer(topLayerItems);
             len = topLayerItems.length;
             for (i=0;i<len;i++)
             {
@@ -815,7 +815,7 @@
             keepLayeringEnabled = true;
             insertIndex=0;

-            GroupBase.mx_internal::sortOnLayer(bottomLayerItems);
+            GroupBase.sortOnLayer(bottomLayerItems);
             len = bottomLayerItems.length;

             for (i=0;i<len;i++)
@@ -1385,7 +1385,7 @@
         var length:int = items.length;
         for (var i:int = 0; i < length; i++)
         {
-            mx_internal::itemAdded(items[i], location + i);
+            itemAdded(items[i], location + i);
         }
     }

@@ -1397,7 +1397,7 @@
         var length:int = items.length;
         for (var i:int = length-1; i >= 0; i--)
         {
-            mx_internal::itemRemoved(items[i], location + i);
+            itemRemoved(items[i], location + i);
         }
     }

@@ -1406,14 +1406,14 @@
      */
     protected function adjustAfterMove(item:Object, location:int, oldLocation:int):void
     {
-        mx_internal::itemRemoved(item, oldLocation);
+        itemRemoved(item, oldLocation);

         // if item is removed before the newly added item
         // then change index to account for this
         if (location > oldLocation)
-            mx_internal::itemAdded(item, location-1);
+            itemAdded(item, location-1);
         else
-            mx_internal::itemAdded(item, location);
+            itemAdded(item, location);
     }

     /**
@@ -1424,12 +1424,12 @@
         var length:int = items.length;
         for (var i:int = length-1; i >= 0; i--)
         {
-            mx_internal::itemRemoved(items[i].oldValue, location + i);
+            itemRemoved(items[i].oldValue, location + i);
         }

         for (i = length-1; i >= 0; i--)
         {
-            mx_internal::itemAdded(items[i].newValue, location);
+            itemAdded(items[i].newValue, location);
         }
     }


get publisher() -> createPublisher()

get publisher() -> createPublisher()

--- exporter/src/main/as/flump/export/ExporterController.as
+++ exporter/src/main/as/flump/export/ExporterController.as
@@ -244,7 +244,7 @@
         _conf.exportDir = _confFile == null ? _exportChooser.dir.nativePath : _confFile.parent.getRelativePath(_exportChooser.dir, /*useDotDot=*/true);
     }

-    protected function get publisher () :Publisher {
+    protected function createPublisher () :Publisher {
         if (_exportChooser.dir == null || _conf.exports.length == 0) return null;
         return new Publisher(_exportChooser.dir, _conf);
     }
@@ -331,7 +331,7 @@
         const prevQuality :String = stage.quality;

         stage.quality = StageQuality.BEST;
-        this.publisher.publish(status.lib);
+        createPublisher().publish(status.lib);

         stage.quality = prevQuality;
         status.updateModified(Ternary.FALSE);
@@ -361,8 +361,9 @@
         _flashDocsGrid.dataProvider.addItem(status);

         load.succeeded.add(function (lib :XflLibrary) :void {
+            var pub :Publisher = createPublisher();
             status.lib = lib;
-            status.updateModified(Ternary.of(publisher == null || publisher.modified(lib)));
+            status.updateModified(Ternary.of(pub == null || pub.modified(lib)));
             for each (var err :ParseError in lib.getErrors()) _errorsGrid.dataProvider.addItem(err);
             status.updateValid(Ternary.of(lib.valid));
         });


Transferred from the Adobe Open Source Subversion Repository

Revision: 4009
Author:   jimurphy@adobe.com
Date:     2008-11-04T15:10:34.970681Z

Log Message:
-----------
Merged alpha_gumbo revisions 3929,3936-3937,3945,3956,3971,3986,3994,4002,4006 -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/CompositeEffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/BitmapGraphic.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/EffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/FxRotate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/utilities/src/flash_component_icon.png</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/FxComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/Group.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/IEffectInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/filters/ShaderFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/utilities/src/flash_container_icon_small.png</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/ParallelInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/StrokedElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/Effect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/effectClasses/TweenEffectInstance.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/effectClasses/FxAnimateInstance.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/ResizeMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/utilities/src/flash_container_icon.png</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/effects/Animation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxDataContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/effects/IEffect.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/baseClasses/GroupBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/graphicsClasses/GraphicElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxContainer.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/utilities/src/flash_component_icon_small.png</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1260235 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/effects/IEffect.as
+++ frameworks/projects/framework/src/mx/effects/IEffect.as
@@ -31,6 +31,87 @@
     //
     //--------------------------------------------------------------------------

+    //----------------------------------
+    //  autoReverse
+    //----------------------------------
+
+    // TODO (chaase): Should this live in Transition instead?
+    /**
+     *  Whether the effect should automatically reverse itself
+     *  when played in a transition and the opposite state
+     *  transition begins playing.
+     *
+     *
Flex does not play multiple transitions simultaneously.
+     *  This means that when a new state transition occurs, if there
+     *  is already one playing it is stopped by calling end()
+     *  on it, which snaps it to its end values. The new transition
+     *  then starts playing from that state.

+     *
+     *
The autoReverse flag allows the developer to
+     *  control whether the default snap-to-end behavior occurs, or whether,
+     *  instead, the previous effect is stopped in place and the new
+     *  effect is played from that intermediate state instead. Internally,
+     *  the transition code calculates how much of the previous effect
+     *  has been played and then plays the next effect for the inverse of that
+     *  time.

+     *
+     *
This flag is only checked when the new transition is going in the
+     *  exact opposite direction of the currently playing one. That is, if
+     *  a transition is playing between states A and B and then a transition
+     *  to return to A is started, this flag will be checked. But if the
+     *  application is going from state A to B and a transition to state C is
+     *  started, then the default behavior of snapping to the end of the A->B
+     *  transition, then playing the B->C transition will occur.

+     *
+     *  @default false
+     */
+    function get autoReverse():Boolean;
+
+    /**
+     *  @private
+     */
+    function set autoReverse(value:Boolean):void;
+
+    //----------------------------------
+    //  fromState
+    //----------------------------------
+
+    // TODO (chaase): Might be cleaner to pass handle to transition itself
+    // to the Effect, then can query from/toState from the transition
+    /**
+     *  The state that the effect is animating from, when played as a
+     *  state transition effect. This information will be set by the component
+     *  setting the state that causes the transition. It is not intended for
+     *  use outside of the Flex framework classes internally.
+     *
+     *  @default null
+     */
+    function get fromState():String;
+
+    /**
+     *  @private
+     */
+    function set fromState(value:String):void;
+
+    //----------------------------------
+    //  toState
+    //----------------------------------
+
+    /**
+     *  The state that the effect is animating to, when played as a
+     *  state transition effect. This information will be set by the component
+     *  setting the state that causes the transition. It is not intended for
+     *  use outside of the Flex framework classes internally.
+     *
+     *  @default null
+     */
+    function get toState():String;
+
+    /**
+     *  @private
+     */
+    function set toState(value:String):void;
+
     //----------------------------------
     //  className
     //----------------------------------
@@ -237,6 +318,18 @@
     function set perElementOffset(value:Number):void;

     //----------------------------------
+    //  playheadTime
+    //----------------------------------
+
+    /**
+     *  Current position in time of the effect.
+     *  This property has a value between 0 and the actual duration
+     *  (which includes the value of the startDelay,
+     *  repeatCount, and repeatDelay properties).
+     */
+    function get playheadTime():Number;
+
+    //----------------------------------
     //  relevantProperties
     //----------------------------------

@@ -472,6 +565,18 @@
      *  @see mx.effects.EffectInstance#end()
      */
     function end(effectInstance:IEffectInstance = null):void;
+
+    /**
+     * Sets the current time of an effect. Seek may be used to
+     * fast-forward or reverse to a particular point in time in an effect.
+     *
+     * @param seekTime Number of milliseconds that the effect should
+     * play at. This number should be between 0 and the duration of the
+     * effect.
+     *
+     * @see #duration
+     */
+    function seek(seekTime:Number):void;

     /**
      *  Captures the current values of the relevant properties


Transferred from the Adobe Open Source Subversion Repository

Revision: 8
Author:   open-source-svn-admin@adobe.com
Date:     2007-12-15T01:49:31.087529Z

Log Message:
-----------
The beginning of the open-source Flex SDK.

Populated the flex/sdk/trunk directory with an open-source subset of files from //depot/flex/sdk/...@191097 in the Faramir Perforce server. This changelist is a bit past the 3.0rc0 build.

The Ant scripts will not successfully build yet. They need to be adapted to the open-source subset.

Modified Paths:
--------------
2532 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1274260 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/rpc/src/mx/rpc/mxml/IMXMLSupport.as
+++ frameworks/projects/rpc/src/mx/rpc/mxml/IMXMLSupport.as
@@ -0,0 +1,62 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2005-2007 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.rpc.mxml
+{
+
+/**
+ *  Implementing this interface means that an RPC service
+ *  can be used in an MXML document via tags
+ *  since it supports the interfaces specified during Flex 1.
+ */
+public interface IMXMLSupport
+{
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+	//  concurrency
+    //----------------------------------
+
+    [Inspectable(enumeration="multiple,single,last", defaultValue="multiple", category="General")]
+
+	/**
+     *  The concurrency setting of the RPC operation or HTTPService.
+	 *  One of "multiple" "last" or "single."
+     */
+    function get concurrency():String;
+
+	/**
+     *  @private
+     */
+    function set concurrency(value:String):void;
+
+    //----------------------------------
+	//  showBusyCursor
+    //----------------------------------
+
+    /**
+     *  Indicates whether the RPC operation or HTTPService
+	 *  should show the busy cursor while it is executing.
+     */
+
+	function get showBusyCursor():Boolean;
+
+    /**
+     *  @private
+     */
+    function set showBusyCursor(value:Boolean):void;
+}
+
+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 6325
Author:   jimurphy@adobe.com
Date:     2009-04-28T15:44:12.873262Z

Log Message:
-----------
fix busted build.  package name change in new TLF swc (elements -> compose)

qa:no
doc:no
checkintests: pass

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/framework_textLayout/src/mx/core/UITLFTextField.as

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1277928 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/mx/core/UIFTETextField.as
+++ frameworks/projects/spark/src/mx/core/UIFTETextField.as
@@ -20,7 +20,7 @@
 import flash.text.TextFormat;
 import flash.text.TextLineMetrics;
 import flashx.textLayout.controls.TLFTextField;
-import flashx.textLayout.elements.ITextLineCreator;
+import flashx.textLayout.compose.ITextLineCreator;
 import mx.automation.IAutomationObject;
 import mx.core.FlexVersion;
 import mx.managers.ISystemManager;