WMS Map

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
               xmlns:s="library://ns.adobe.com/flex/spark"
               xmlns:esri="http://www.esri.com/2008/ags"
               backgroundColor="0xEEEEEE"
               pageTitle="Using a WMS map service with the ArcGIS API for Flex">
    <!--
    Description:
    This sample demonstrates how to use a WMS service as a layer
    in your ArcGIS API for Flex application.

    Documentation:
    For more information, see the API documentation.
    https://developers.arcgis.com/en/flex/api-reference/com/esri/ags/Map.html
    https://developers.arcgis.com/en/flex/api-reference/com/esri/ags/layers/WMSLayer.html

    http://en.wikipedia.org/wiki/Web_Map_Service
    http://www.opengeospatial.org/standards/wms

    http://resources.arcgis.com/en/help/flex-api/concepts/index.html#/Types_of_layers/017p00000027000000/
    -->

    <s:controlBarContent>
        <s:RichText width="100%">
            This sample demonstrates how to use a WMS service as a layer
            in your ArcGIS API for Flex application.
        </s:RichText>
    </s:controlBarContent>

    <esri:Map>
        <esri:WMSLayer url="http://sampleserver1.arcgisonline.com/arcgis/services/Specialty/ESRI_StatesCitiesRivers_USA/MapServer/WMSServer">
            <esri:visibleLayers>
                <!--Order matters-->
                <s:ArrayList>
                    <!--States-->
                    <fx:String>0</fx:String>
                    <!--Cities-->
                    <fx:String>2</fx:String>
                </s:ArrayList>
            </esri:visibleLayers>
        </esri:WMSLayer>
    </esri:Map>
</s:Application>