it.geosolutions.geoserver.rest.decoder
Class RESTFeatureType

java.lang.Object
  extended by it.geosolutions.geoserver.rest.decoder.RESTResource
      extended by it.geosolutions.geoserver.rest.decoder.RESTFeatureType

public class RESTFeatureType
extends RESTResource

Parse FeatureTypes returned as XML REST objects.

This is the XML REST representation:

 <featureType>
  <name>tasmania_cities</name>
  <nativeName>tasmania_cities</nativeName>
  <namespace>
    <name>topp</name>
    <atom:link xmlns:atom="http://www.w3.org/2005/Atom" rel="alternate" href="http://localhost:8080/geoserver/rest/namespaces/topp.xml" type="application/xml"/>
  </namespace>
  <title>Tasmania cities</title>
  <abstract>Cities in Tasmania (actually, just the capital)</abstract>
  <keywords>
    <string>cities</string>
    <string>Tasmania</string>
  </keywords>
  <nativeCRS>GEOGCS[&quot;GCS_WGS_1984&quot;,
  DATUM[&quot;WGS_1984&quot;,
    SPHEROID[&quot;WGS_1984&quot;, 6378137.0, 298.257223563]],
  PRIMEM[&quot;Greenwich&quot;, 0.0],
  UNIT[&quot;degree&quot;, 0.017453292519943295],
  AXIS[&quot;Longitude&quot;, EAST],
  AXIS[&quot;Latitude&quot;, NORTH]]</nativeCRS>
  <srs>EPSG:4326</srs>
  <nativeBoundingBox>
    <minx>147.2910004483</minx>
    <maxx>147.2910004483</maxx>
    <miny>-42.851001816890005</miny>
    <maxy>-42.851001816890005</maxy>
    <crs>EPSG:4326</crs>
  </nativeBoundingBox>
  <latLonBoundingBox>
    <minx>145.19754</minx>
    <maxx>148.27298000000002</maxx>
    <miny>-43.423512</miny>
    <maxy>-40.852802</maxy>
    <crs>EPSG:4326</crs>
  </latLonBoundingBox>
  <projectionPolicy>FORCE_DECLARED</projectionPolicy>
  <enabled>true</enabled>
  <metadata>
    <entry key="cacheAgeMax">3600</entry>
    <entry key="indexingEnabled">false</entry>
    <entry key="kml.regionateFeatureLimit">10</entry>
    <entry key="cachingEnabled">true</entry>
    <entry key="dirName">tasmania_cities</entry>
  </metadata>
  <store class="dataStore">
    <name>taz_shapes</name>
    <atom:link xmlns:atom="http://www.w3.org/2005/Atom" rel="alternate" href="http://localhost:8080/geoserver/rest/workspaces/topp/datastores/taz_shapes.xml" type="application/xml"/>
  </store>
  <attributes>
    <attribute>
      <name>the_geom</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
    <attribute>
      <name>CITY_NAME</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
    <attribute>
      <name>ADMIN_NAME</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
    <attribute>
      <name>CNTRY_NAME</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
    <attribute>
      <name>STATUS</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
    <attribute>
      <name>POP_CLASS</name>
      <minOccurs>0</minOccurs>
      <maxOccurs>1</maxOccurs>
      <nillable>false</nillable>
    </attribute>
  </attributes>
  <maxFeatures>0</maxFeatures>
  <numDecimals>0</numDecimals>
</featureType>
 

Author:
etj

Nested Class Summary
static class RESTFeatureType.Attribute
           
 
Field Summary
 
Fields inherited from class it.geosolutions.geoserver.rest.decoder.RESTResource
rootElem
 
Constructor Summary
RESTFeatureType(org.jdom.Element resource)
           
RESTFeatureType(RESTResource resource)
           
 
Method Summary
 Iterator<RESTFeatureType.Attribute> attributesIterator()
           
static RESTFeatureType build(String response)
           
 Iterable<RESTFeatureType.Attribute> getAttributes()
          Get the URL to retrieve the featuretype.
 
Methods inherited from class it.geosolutions.geoserver.rest.decoder.RESTResource
getAbstract, getAttributeList, getCRS, getEncodedAttributeList, getLatLonEdge, getMaxX, getMaxY, getMinX, getMinY, getName, getNameSpace, getNativeName, getStoreName, getStoreType, getStoreUrl, getTitle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RESTFeatureType

public RESTFeatureType(org.jdom.Element resource)

RESTFeatureType

public RESTFeatureType(RESTResource resource)
Method Detail

build

public static RESTFeatureType build(String response)

getAttributes

public Iterable<RESTFeatureType.Attribute> getAttributes()
Get the URL to retrieve the featuretype.
<resource class="featureType">
        <name>tasmania_cities</name>
        <atom:link xmlns:atom="http://www.w3.org/2005/Atom" rel="alternate" href="http://localhost:8080/geoserver/rest/workspaces/topp/datastores/taz_shapes/featuretypes/tasmania_cities.xml" type="application/xml"/>
    </resource>
 


attributesIterator

public Iterator<RESTFeatureType.Attribute> attributesIterator()


Copyright © 2007-2013 GeoSolutions. All Rights Reserved.