Hide Table of Contents
esri/dijit/util
esri/layer/pixelFilters
esri/process
esri/workers
Class: TableDataSource

require(["esri/layers/TableDataSource"], function(TableDataSource) { /* code goes here */ });

Description

(Added at v2.7)
The TableDataSource class defines and provides information about a table, feature class, or raster that resides in a registered file geodatabase, SDE or Shapefile workspace. Requires ArcGIS Server 10.1 or greater.

See also

Samples

Search for samples that use this class.

Class hierarchy

esri/layers/DataSource
|_esri/layers/TableDataSource

Constructors

NameSummary
new TableDataSource(json?)Creates a new TableDataSource object.

Properties

NameTypeSummary
dataSourceNameStringThe name of a table, feature class or raster that resides in the registered workspace.
gdbVersionStringFor versioned SDE workspaces, use this property to point to an alternate version.
workspaceIdStringThe workspace id for the registered file geodatabase, SDE or Shapefile workspace.

Methods

NameReturn typeSummary
toJson()ObjectConverts object to its ArcGIS Server JSON representation.
Constructor Details

new TableDataSource(json?)

Creates a new TableDataSource object.
Parameters:
<Object> json Optional JSON object representing the TableDataSource.
Sample:
require([
  "esri/layers/TableDataSource", ... 
], function(TableDataSource, ... ) {
  var dataSource = new TableDataSource();
  ...
});
Property Details

<String> dataSourceName

The name of a table, feature class or raster that resides in the registered workspace.
Sample:

dataSource.dataSourceName = "sde.SDE.states";

<String> gdbVersion

For versioned SDE workspaces, use this property to point to an alternate version. If a gdbVersion is not provided then the version specified when the SDE workspace was registered will be used.

<String> workspaceId

The workspace id for the registered file geodatabase, SDE or Shapefile workspace.
Sample:

dataSource.workspaceId = "d203";

Method Details

toJson()

Converts object to its ArcGIS Server JSON representation.
Return type: Object