DATASET  Examples

Used in:  CONFIG   REQUEST  
Servers:  Image   Query   Feature   Extract   ArcMap  
Parent elements:  LAYER  

<DATASET Attribute Description Table


     When parent element is LAYER and the layer type is featureclass:
     name ="string"
     type ="point | line | polygon"
     workspace ="string"

     When parent element is LAYER and the layer type is image:
     name ="string"
     workspace ="string"
     type ="image"

     When parent element is LAYER in GET_IMAGE or GET_EXTRACT:
     fromlayer ="Layer ID in map configuration file"
>

     (m) <PARTITION... />

</DATASET >
Bold: Attribute or child element is required.
(m):  Child element can be used multiple times.


Description:


Restrictions:


Notes:


Attribute Descriptions for DATASET:


When parent element is LAYER and the layer type is featureclass:
Attribute Usage Back to Top
name 1 The value depends on whether DATASET is used in a map configuration file or a viewer configuration file.
  • Map configuration file. For shapefiles, use the name of the data file without an extension such as STATES. For ArcSDE, use the full name of the layer such as DATA.STATES.
  • Feature Service layers in a viewer configuration file. Use the LAYER id in the map configuration file. For example, if the id for a layer is "0", then DATASET name="0".
  • Image Service layers in a viewer configuration file. Use the name of the Image Service. For example, if the service is named "world", then DATASET name="world".
type 2 Source layer feature type. Required when the layer source defined in LAYER is featureclass.
workspace 3 References the workspace name where the data resides.

When parent element is LAYER and the layer type is image:
Attribute Usage Back to Top
name 1 For images, see the table in the Notes section for details on accessing and naming image files.
type 2 Layer source type is optional for image layers.
workspace 3 References the workspace name where the data resides.

When parent element is LAYER in GET_IMAGE or GET_EXTRACT:
Attribute Usage Back to Top
fromlayer 1 References an existing layer in a map configuration file. Use the layer ID, not name.
 

Examples for DATASET:

Example 1: When used in a map configuration file. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
        <ENVELOPE minx="-178.21" miny="18.92" maxx="-66.96" maxy="71.41" name="Initial_Extent" />
        <MAPUNITS units="decimal_degrees" />
      </PROPERTIES>
      <WORKSPACES>
        <SHAPEWORKSPACE name="shp_ws-0" directory="<path to USA ESRIDATA>"/>
      </WORKSPACES>
      <LAYER type="featureclass" name="CITIES" visible="true" id="2">
      <DATASET name="CITIES" type="point" workspace="shp_ws-0" />
      <SIMPLERENDERER>
        <SIMPLEMARKERSYMBOL type="square" width="5" />
      </SIMPLERENDERER>
      </LAYER>
    </MAP>
  </CONFIG>
</ARCXML>

Example 2: When in a viewer configuration file. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
      <ENVELOPE minx="-180.0" miny="-90.0" maxx="185.6901927947995" maxy="90.0" name="Initial_Extent" />
      <MAPUNITS units="decimal_degrees" />
      </PROPERTIES>
      <WORKSPACES>
      <IMAGESERVERWORKSPACE name="mapper_ws-0" url="http://mymachine.domain.com/servlet/com.esri.esrimap.Esrimap" service="background" />
      <FEATURESERVERWORKSPACE name="ifs_ws-1" url="http://mymachine.domain.com/servlet/com.esri.esrimap.Esrimap" service="world" />
      </WORKSPACES>
      <LAYER type="image" name="background" visible="true" id="0">
      <DATASET name="background" type="image" workspace="mapper_ws-0" />
      </LAYER>
      <LAYER type="featureclass" name="Countries" visible="true" id="1">
      <DATASET name="1" type="polygon" workspace="ifs_ws-1" />
      </LAYER>
    </MAP>
    <SCALEBAR backcolor="192,192,192" fontcolor="0,0,0" mapunits="decimal_degrees" scaleunits="feet" screenunits="inches" />
  </CONFIG>
</ARCXML>

Example 3: When using fromlayer in a REQUEST. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <REQUEST>
    <GET_IMAGE>
      <PROPERTIES>
        <ENVELOPE minx="-180" miny="-90" maxx="180" maxy="90" />
        <IMAGESIZE width="643" height="502" />
      </PROPERTIES>
      <LAYER type="featureclass" name="select layer" visible="true" id="Selected">
        <DATASET fromlayer="1" />
        <SPATIALQUERY>
          <SPATIALFILTER relation="area_intersection">
            <POLYLINE>
              <PATH>
                <POINT x="-2.1079549837513" y="19.99815142335011" />
                <POINT x="28.99468788980437" y="15.88488432940315" />
                <POINT x="55.99468788980437" y="35.88488432940315" />
              </PATH>
            </POLYLINE>
          </SPATIALFILTER>
        </SPATIALQUERY>
        <SIMPLERENDERER>
          <SIMPLEPOLYGONSYMBOL fillcolor="0,255,0" filltype="cross" fillinterval="3" />
        </SIMPLERENDERER>
      </LAYER>
    </GET_IMAGE>
  </REQUEST>
</ARCXML>

Example 4: When specifying one image by name. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
        <ENVELOPE minx="192837" miny="3769109" maxx="197809" maxy="3773771" name="Initial_Extent" />
        <MAPUNITS units="meters" />
      </PROPERTIES>
      <WORKSPACES>
        <IMAGEWORKSPACE directory="<path to image>" name="jai_ws-0" />
      </WORKSPACES>
      <LAYER type="image" name="reno.sid" visible="true" id="0">
        <DATASET name="reno.sid" type="image" workspace="jai_ws-0" />
      </LAYER>
    </MAP>
  </CONFIG>
</ARCXML>

Example 5: When specifying multiple images in a directory. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
        <ENVELOPE minx="0" miny="-1.0" maxx="891.0" maxy="1000.0" name="Initial_Extent" />
        <MAPUNITS units="feet" />
      </PROPERTIES>
      <WORKSPACES>
        <IMAGEWORKSPACE directory="<path to image directory>" name="jai_ws-0" />
      </WORKSPACES>
      <LAYER type="image" name="*ImageDirectory" visible="false" id="0">
        <DATASET name="*ImageDirectory" type="image" workspace="jai_ws-0" />
      </LAYER>
    </MAP>
  </CONFIG>
</ARCXML>

Example 6: When specifying an image catalog. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
        <ENVELOPE minx="0" miny="0" maxx="2000000" maxy="2000000" name="Initial_Extent"/>
         <MAPUNITS units="meters" />
      </PROPERTIES>
      <WORKSPACES>
        <IMAGEWORKSPACE name="jai_ws-15" directory="<path to image catalog dbf file>"/>
      </WORKSPACES>
      <LAYER type="image" name="Mammoth Area" visible="true" id="0">
        <DATASET name="mammoth.dbf" type="image" workspace="jai_ws-15" />
      </LAYER>
    </MAP>
  </CONFIG>
</ARCXML>

Example 7: When specifying a GRID. Back to Top
<?xml version="1.0" encoding="UTF-8"?>
<ARCXML version="1.1">
  <CONFIG>
    <ENVIRONMENT>
      <LOCALE country="US" language="en" variant="" />
      <UIFONT color="0,0,0" name="Arial" size="12" style="regular" />
      <SCREEN dpi="96" />
    </ENVIRONMENT>
    <MAP>
      <PROPERTIES>
       <ENVELOPE minx="-2006008" miny="-1240677" maxx="-1993628" maxy="-1256187" name="Initial_Extent" />
       <MAPUNITS units="meters" />
      </PROPERTIES>
      <WORKSPACES>
       <IMAGEWORKSPACE directory="<path to parent directory above INFO and GRID directory>" name="jai_ws-15" />
      </WORKSPACES>
      <LAYER type="image" name="Mt St. Helens" visible="true" id="0">
       <DATASET name="<GRID directory>" type="image" workspace="jai_ws-15" />
      </LAYER>
    </MAP>
  </CONFIG>
</ARCXML>