This topic contains the following information to successfully migrate from 2.5 to 3.0:
The following requirements have changed at 3.0:
Adobe Flex SDK 4.6 or later
As of version 3.0 of the ArcGIS API for Flex, the minimum Adobe Flex software development kit (SDK) version is 4.6. For earlier versions, 2.x will work with any Adobe Flex SDK 4.0 or later, while 1.x will work with Adobe Flex SDK 3.x.
Flash Player 11.1 or later
As part of the move to Flex 4.6 SDK, Flash Player 11.1 or later is now required.
Upgrading your Flex API application code from 2.5 to 3.0
The information in this section is to ensure that your ArcGIS API 2.5 for Flex code works with ArcGIS API 3.0 for Flex and later.
Converting from 2.5 to 3.0 of the ArcGIS API for Flex
The following sections explain the changes you need to make to convert from ArcGIS API 2.5 for Flex to ArcGIS API 3.0 for Flex:
Project property changes
Change the SDK version to at least 4.6.
Change the required Flash player version to 11.1 or later.
The following name changes are effective at 3.0:
- The webmap package has been renamed portal and includes new classes for connecting to ArcGIS Online and Portal for ArcGIS.
- The Domain class is now an interface and has been renamed IDomain.
- The JSON class has been renamed JSONUtil, which is the same naming convention as all the other classes in the utils package.
- The id property in LayerInfo has been renamed layerId.
- The attribute, attribute2, attribute3, and attributeDelimiter properties for UniqueValueRenderer that were deprecated at 2.5 have been removed at 3.0; use field, field2, field3, and fieldDelimiter instead.
- The attribute property on the ClassBreaksRenderer class has been renamed field.
- The href property on the MapImage class has been renamed source.
- The arcgisSharingURL property on the WebMapUtil class has been renamed portalURL.
- The AttributeInspector form has been sparkified, which includes the following changes:
- New AttributeInspectorRenderer in the skins
- FieldInspector.renderer is now FieldInspector.editor
- FormData is now FormField
- New event: FormFieldEvent
- The formItemsOrder property on the AttributeInspector class has been renamed formFieldsOrder.
- The fromJSON() and toJSON() methods on FeatureSet take an object instead of a string.
- The default value for Map.openHandCursorVisible has changed from true to false.
- On the GeometryService, the input parameter for the project() method is now projectParameters instead of geometries. This also allows for specifying datum transformations (requires ArcGIS 10.1 for Server).
- On the Locator, the input parameter for the addressToLocation() method is now addressToLocationParameters instead of address, outfields. This also adds support for batch geocoding and searching within an extent (requires ArcGIS 10.1 for Server).
- The ClassBreaksRenderer has a new property, isMaxInclusive, that defaults to true to align with ArcGIS for Server, which is always inclusive. Previously, the behavior was not inclusive. If you were using ClassBreaksRenderer and taking advantage of the earlier behavior, you now need to set it to false.
- The layerDefinitions property on ArcGISDynamicMapServiceLayer, FindParameters, and IdentifyParameters can now take LayerDefinition in addition to a string. When using MXML, only LayerDefinition is allowed. When using ActionScript, both are allowed.
- The default value for the UniqueValueRenderer.fieldDelimiter (formerly UniqueValueRenderer.attributeDelimiter) has changed from "" (empty string) to "," (comma) and "" is no longer a valid value.
- The TextSymbol constructor now takes an alpha value as its fourth parameter. If you were using the TextSymbol constructor with more than three parameters, you need to adjust accordingly.
- The default for the visibleLayers property on ArcGISDynamicMapServiceLayer and ArcIMSMapServiceLayer changed to null.
Removed properties and methods at 3.0
- The units property in Map and Layer has been removed as it is no longer needed; instead, this information is inferred from the spatial reference.
- The visibleLayers property on ArcGISTiledMapServiceLayer has been removed.
- The autoMoveToTop property on Graphic has been removed.
- The postalTown property on VEAddress has been removed.
- The calculationMethod and matchCodes properties on VEGeocodeResult have been removed.
- The defaultVisibleLayers() method on ArcGISDynamicMapServiceLayer and ArcIMSMapServiceLayer has been removed.
- The convertFromJSON() and convertToJSON() methods on FeatureSet were deprecated at 2.4 and have been removed at 3.0. Use toJSON() and fromJSON() instead.
- The zoomToFullExtent() method on NavigationTool was deprecated at 2.3 and has been removed at 3.0. Use Map.zoomToInitialExtent() instead.
- The result event on AttachmentInspector was deprecated at 2.4 and has been removed at 3.0. Use the event types defined in AttachmentEvent instead.