public class

QueryTableDataSource

extends DataSource
java.lang.Object
   ↳ com.esri.core.map.DataSource
     ↳ com.esri.core.map.QueryTableDataSource

Class Overview

The Class QueryTableDataSource is a layer/table that is defined by a SQL query.

Note:

  • When querying a table that stores geometry in the database native format the result is returned as a layer that can be used in any operation supported by dynamic layer. For example, use this layer in export operation by specifying a renderer.
  • When querying a table that stores geometry in the non-native format the result is returned as a table that can be used in query operations.
  • When querying a table that does not have geometry column, do not include geometryType and spatialReference.

  • Summary

    Public Constructors
    QueryTableDataSource()
    Instantiates a new query table data source.
    Public Methods
    Geometry.Type getGeometryType()
    Gets the geometry type.
    String getOidFields()
    Gets the oid fields.
    String getQuery()
    Gets the query.
    SpatialReference getSpatialReference()
    Gets the spatial reference.
    String getWorkspaceId()
    Gets the workspace id.
    void setGeometryType(Geometry.Type geometryType)
    Sets the geometry type.
    void setOidFields(String oidFields)
    Sets the oid fields.
    void setQuery(String query)
    Sets the query.
    void setSpatialReference(SpatialReference spatialRef)
    Sets the spatial reference.
    void setWorkspaceId(String id)
    Sets the workspace id.
    String toJson()
    String toString()
    [Expand]
    Inherited Methods
    From class com.esri.core.map.DataSource
    From class java.lang.Object

    Public Constructors

    public QueryTableDataSource ()

    Instantiates a new query table data source.

    Public Methods

    public Geometry.Type getGeometryType ()

    Gets the geometry type.

    Returns
    Geometry.Type the geometry type

    public String getOidFields ()

    Gets the oid fields. This is a comma separated list of OID fields.

    Returns
    String the oid fields

    public String getQuery ()

    Gets the query.

    Returns
    String the query

    public SpatialReference getSpatialReference ()

    Gets the spatial reference.

    Returns
    SpatialReference the spatial reference

    public String getWorkspaceId ()

    Gets the workspace id.

    Returns
    String the workspace id

    public void setGeometryType (Geometry.Type geometryType)

    Sets the geometry type.

    Parameters
    geometryType Geometry.Type: the new geometry type

    public void setOidFields (String oidFields)

    Sets the oid fields. This is a comma separated list of OID fields.

    Parameters
    oidFields String: the new oid fields

    public void setQuery (String query)

    Sets the query.

    Parameters
    query String: the new query

    public void setSpatialReference (SpatialReference spatialRef)

    Sets the spatial reference.

    Parameters
    spatialRef SpatialReference: the new spatial reference

    public void setWorkspaceId (String id)

    Sets the workspace id.

    Parameters
    id String: the new workspace id

    public String toJson ()

    Returns
    String
    Throws
    Exception

    public String toString ()

    Returns
    String