mx.data

# UpdateCollectionRange - AS3 ADEP Data Services

Package | mx.data
Class | public class UpdateCollectionRange
Inheritance | UpdateCollectionRange Object

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

The UpdateCollectionRange class provides specific information about a range of add and remove operations made to a collection. These objects are associated with a specific UpdateCollectionMessage and are carried in an Array on its `body` property.

View the examples

Related API Elements

mx.data.messages.UpdateCollectionMessage

Public Properties
Hide Inherited Public Properties
Show Inherited Public Properties

| Property | Defined By
--- | --- | ---
|  | constructor : Object A reference to the class object or constructor function for a given object instance. | Object
|  | identities : Array An Array of identity objects that represent which items were either deleted or inserted in the associated collection starting at the position indicated by the position property. | UpdateCollectionRange
|  | position : int Indicates the beginning index for the range of updates made to the associated collection. | UpdateCollectionRange
|  | size : int Indicates the increase in collection size. | UpdateCollectionRange
|  | updateType : int Indicates what operation this range represents. | UpdateCollectionRange

Public Methods
Hide Inherited Public Methods
Show Inherited Public Methods

| Method | Defined By
--- | --- | ---
|  | UpdateCollectionRange() Constructs an empty UpdateCollectionRange. | UpdateCollectionRange
|  | hasOwnProperty(name:String):Boolean Indicates whether an object has a specified property defined. | Object
|  | isPrototypeOf(theClass:Object):Boolean Indicates whether an instance of the Object class is in the prototype chain of the object specified as the parameter. | Object
|  | propertyIsEnumerable(name:String):Boolean Indicates whether the specified property exists and is enumerable. | Object
|  | setPropertyIsEnumerable(name:String, isEnum:Boolean = true):void Sets the availability of a dynamic property for loop operations. | Object
|  | toLocaleString():String Returns the string representation of this object, formatted according to locale-specific conventions. | Object
|  | toString():String Returns the string representation of the specified object. | Object
|  | valueOf():Object Returns the primitive value of the specified object. | Object

Public Constants

| Constant | Defined By
--- | --- | ---
|  | DECREMENT_COLLECTION_SIZE : int = 3 [static] Indicates a derease in the collection size. | UpdateCollectionRange
|  | DELETE_FROM_COLLECTION : int = 1 [static] Indicates a range of items that have been deleted from the collection. | UpdateCollectionRange
|  | INCREMENT_COLLECTION_SIZE : int = 2 [static] Indicates an increase in the collection size. | UpdateCollectionRange
|  | INSERT_INTO_COLLECTION : int = 0 [static] Indicates a range of items have been inserted into the collection. | UpdateCollectionRange
|  | UPDATE_COLLECTION_SIZE : int = 4 [static] Indicates an update to the collection size sent by the server. | UpdateCollectionRange

Property Detail

### identities

property

`public var identities:Array`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

An Array of identity objects that represent which items were either deleted or inserted in the associated collection starting at the position indicated by the `position` property.

### position

property

`public var position:int`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates the beginning index for the range of updates made to the associated collection. The `updateType` indicates if the range was an insert or a remove operation.

### size

property

`public var size:int`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates the increase in collection size. Only applicatble when update type is INCREMENT_COLLECTION_SIZE or DECREMENT_COLLECTION_SIZE

### updateType

property

`public var updateType:int`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates what operation this range represents. Valid values are:

- `UpdateCollectionRange.INSERT_INTO_COLLECTION`
- `UpdateCollectionRange.DELETE_FROM_COLLECTION`
- `UpdateCollectionRange.INCREMENT_COLLECTION_SIZE`
- `UpdateCollectionRange.DECREMENT_COLLECTION_SIZE`
- `UpdateCollectionRange.UPDATE_COLLECTION_SIZE`

Constructor Detail

### UpdateCollectionRange

()
Constructor

`public function UpdateCollectionRange()`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Constructs an empty UpdateCollectionRange.

Constant Detail

### DECREMENT_COLLECTION_SIZE

Constant

`public static const DECREMENT_COLLECTION_SIZE:int = 3`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates a derease in the collection size. The `size` property will contain an increase amount

### DELETE_FROM_COLLECTION

Constant

`public static const DELETE_FROM_COLLECTION:int = 1`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates a range of items that have been deleted from the collection. The `identities` property will contain an Array of item identity objects for each item that was inserted into the collection. The `position` property indicates at what index the insertion operation began. Inspect the `identityies.length` to determine how many items were inserted.

### INCREMENT_COLLECTION_SIZE

Constant

`public static const INCREMENT_COLLECTION_SIZE:int = 2`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates an increase in the collection size. The `size` property will contain an increase amount

### INSERT_INTO_COLLECTION

Constant

`public static const INSERT_INTO_COLLECTION:int = 0`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates a range of items have been inserted into the collection. The `identities` property will contain an Array of item identity objects for each item that was inserted into the collection. The `position` property indicates at what index the insertion operation began. Inspect the `identityies.length` to determine how many items were inserted.

### UPDATE_COLLECTION_SIZE

Constant

`public static const UPDATE_COLLECTION_SIZE:int = 4`

Language Version: | ActionScript 3.0

Product Version: | Adobe Digital Enterprise Platform Data Services for Java EE 3

Runtime Versions: | Flash Player 9, AIR 1.1

Indicates an update to the collection size sent by the server. This will occur when a paged-fill is refreshed on the server. The `size` property will contain an increase amount

Examples How to use this example
Copy

         var ucm:UpdateCollectionMessage = UpdateCollectionMessage(msg);
         var ucr:UpdateCollectionRange = UpdateCollectionRange(ucm.body[0]);
         trace("First change to the collection was "+ ucr.updateType +" at "+
                ucr.position);

© 2015 Adobe Systems Incorporated. All rights reserved.
Mon Apr 10 2017, 12:28 PM -07:00