ServiceDefinition

AMD: require(["esri/rest/knowledgeGraph/ServiceDefinition"], (ServiceDefinition) => { /* code goes here */ });
ESM: import ServiceDefinition from "@arcgis/core/rest/knowledgeGraph/ServiceDefinition.js";
Class: esri/rest/knowledgeGraph/ServiceDefinition
Inheritance: ServiceDefinitionAccessor
Since: ArcGIS Maps SDK for JavaScript 4.26
beta

Outlines the service capabilities for a knowledgeGraphService.

Example
{
	"allowGeometryUpdates": false,
	"capabilities": [
		"Delete",
		"Query",
		"Create",
		"Editing",
		"Update"
	],
	"copyrightText": "2023 Esri, all rights reserved",
	"currentVersion": 11.0,
	"dataEditingNotSupported": false,
	"dateFieldsTimeReference": {
		"respectsDaylightSaving": false,
		"timeZone": "UTC"
	},
	"description": "Supply chain data",
	"maxRecordCount": 2000,
	"schemaEditingNotSupported": false,
	"searchMaxRecordCount": 2000,
	"serviceCapabilities": {
		"applyEditsCapabilities": {
			"graphDefaultRollbackOnFailure": false
		},
		"geometryCapabilities": {
			"geometryMaxBoundingRectangleSizeX": 180,
			"geometryMaxBoundingRectangleSizeY": 180,
			"supportedGeometryTypes": [
				"Point",
				"Mulitpoint",
				"Polyline",
				"Polygon"
			],
			"supportsMValues": false,
			"supportsZValues": false
		},
		"indexCapabilities": {
			"supportsDecendingIndex": false,
			"supportsRelationshipIndex": true,
			"supportsUniqueRelationshipConstraint": false
		}
	},
	"searchCapabilities": {
		"allowLeadingWildcardQueries": true,
		"searchTypeFilterCapabilities": [
			"esriTypeEntity",
			"esriTypeRelationship",
			"esriTypeBoth"
		]
	},
	"serviceItemId": "87941a7420e84933882502ff2e9a5c34",
	"spatialReference": {
		"wkid": 4326
	},
	"supportedQueryFormats": [
		"PBF"
	],
	"supportsDocuments": true,
	"supportsSearch": true,
	"units": "esriDecimalDegrees",
	"url": "https://myHostName.domain.com/server/rest/services/Hosted/myServiceName/KnowledgeGraphServer"
}

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
Show inherited properties Hide inherited properties
Name Type Summary Class

Indicates if geometry data in the graph can be modified.

ServiceDefinition

Specifies the operational capabilities of the knowledge graph.

ServiceDefinition

Copyright information for the knowledge graph.

ServiceDefinition

The version number of the ArcGIS Enterprise instance where the knowledge graph service is hosted.

ServiceDefinition

Indicates if data editing is not supported.

ServiceDefinition

Specifies the timezone for dateTime fields.

ServiceDefinition

The name of the class.

Accessor

The description of the service.

ServiceDefinition

The maximum number of records returned by a query operation.

ServiceDefinition

Indicates if the knowledge graph schema (data model) can be edited.

ServiceDefinition

The maximum number of records returned by a search operation.

ServiceDefinition

specifies the details of the index, edit, search and geometry capabilities of the service.

ServiceDefinition

The ArcGIS Enterprise Portal item id of the knowledge graph service.

ServiceDefinition

Specifies the SpatialReference information for the knowledge graph service.

ServiceDefinition

The query formats supported by the service.

ServiceDefinition

Indicates if the service supports entity types with a document role.

ServiceDefinition

Indicates if the service supports provenance.

ServiceDefinition

Indicates if the services supports search operations.

ServiceDefinition

The units for the spatial reference.

ServiceDefinition

Property Details

allowGeometryUpdates

Property
allowGeometryUpdates Booleanreadonly

Indicates if geometry data in the graph can be modified. If false executeApplyEdits on geometry properties will fail.

capabilities

Property
capabilities String[]readonly

Specifies the operational capabilities of the knowledge graph.

Example
["Query", "Editing", "Delete", "Create", "Update"]

copyrightText

Property
copyrightText Stringreadonly

Copyright information for the knowledge graph.

currentVersion

Property
currentVersion Numberreadonly

The version number of the ArcGIS Enterprise instance where the knowledge graph service is hosted.

dataEditingNotSupported

Property
dataEditingNotSupported Booleanreadonly

Indicates if data editing is not supported. If true executeApplyEdits will fail.

dateFieldsTimeReference

Property
dateFieldsTimeReference Objectreadonly

Specifies the timezone for dateTime fields.

Properties
respectsDaylightSaving Boolean

Indicates if datetime fields respects daylight savings.

timeZone String

the timezone for all datetime fields.

declaredClass

Inherited
Property
declaredClass Stringreadonly
Inherited from Accessor

The name of the class. The declared class name is formatted as esri.folder.className.

description

Property
description Stringreadonly

The description of the service.

maxRecordCount

Property
maxRecordCount Numberreadonly

The maximum number of records returned by a query operation.

schemaEditingNotSupported

Property
schemaEditingNotSupported Booleanreadonly

Indicates if the knowledge graph schema (data model) can be edited. Schema editing is not currently supported in the JS API, if false any updates to the schema must be made through the ArcGIS REST API for Knowledge Graph.

searchMaxRecordCount

Property
searchMaxRecordCount Numberreadonly

The maximum number of records returned by a search operation.

serviceCapabilities

Property
serviceCapabilities Objectreadonly

specifies the details of the index, edit, search and geometry capabilities of the service.

Properties
indexCapabilities Object

Information on the supported capabilities of indexes in the knowledge graph service.

Specification
supportsDescendingIndex Boolean

Specifies if the service supports indexes in descending order.

supportsUniqueRelationshipConstraint Boolean

Specifies if the system supports creating unique constraints for relationship types

supportsRelationshipIndex Boolean

Specifies if the service supports indexes on relationships.

applyEditsCapabilities Object

Information on the supported capabilities of the the executeApplyEdits operation.

Specification
graphDefaultRollbackOnFailure Boolean

If true, when an apply edits operation fails, the data will revert to it's state before the change.

searchCapabilities Object

Information on the supported capabilities of search operations in the knowledge graph service.

Specification
searchTypeFilterCapabilities String[]

The search category filters supported by this service.

Possible Values:"esriTypeEntity"|"esriTypeRelationship"|"esriTypeBoth"

allowLeadingWildcardQueries Boolean

Specifies if search strings can contain a leading wildcard operator (*).

geometryCapabilities Object

Information on the supported capabilities of geometries in the knowledge graph service.

Specification
geometryMaxBoundingRectangleSizeX Number

The maximum bounding rectangle size along the x-axis.

geometryMaxBoundingRectangleSizeY Number

The maximum bounding rectangle size along the y-axis.

supportsMValues Boolean

Specifies if the knowledge graph service supports m-values on geometry.

supportsZValues Boolean

Specifies if the knowledge graph service supports z-values on geometry.

supportedGeometryTypes String[]

Specifies what geometry types are supported by the graph such as Point, Multipoint, Polyline, Polygon.

Example
"serviceCapabilities": {
	"applyEditsCapabilities": {
		"graphDefaultRollbackOnFailure": false
	},
	"geometryCapabilities": {
		"geometryMaxBoundingRectangleSizeX": 180,
		"geometryMaxBoundingRectangleSizeY": 180,
		"supportedGeometryTypes": [
			"Point",
			"Mulitpoint",
			"Polyline",
			"Polygon"
		],
		"supportsMValues": false,
		"supportsZValues": false
	},
	"indexCapabilities": {
		"supportsDecendingIndex": false,
		"supportsRelationshipIndex": true,
		"supportsUniqueRelationshipConstraint": false
	}
	},
	"searchCapabilities": {
	"allowLeadingWildcardQueries": true,
	"searchTypeFilterCapabilities": [
		"esriTypeEntity",
		"esriTypeRelationship",
		"esriTypeBoth"
	]
}

serviceItemId

Property
serviceItemId Stringreadonly

The ArcGIS Enterprise Portal item id of the knowledge graph service.

spatialReference

Property
spatialReference SpatialReferenceautocastreadonly

Specifies the SpatialReference information for the knowledge graph service.

Default Value:null

supportedQueryFormats

Property
supportedQueryFormats String[]readonly

The query formats supported by the service.

supportsDocuments

Property
supportsDocuments Booleanreadonly

Indicates if the service supports entity types with a document role.

supportsProvenance

Property
supportsProvenance Booleanreadonly

Indicates if the service supports provenance. If false provenance cannot be used or returned in streaming queries.

supportsSearch

Property
supportsSearch Booleanreadonly

Indicates if the services supports search operations. If false, executeSearch will fail.

units

Property
units Stringreadonly

The units for the spatial reference.

Example
units: "esriDecimalDegrees"

Method Overview

Show inherited methods Hide inherited methods
Name Return Type Summary Class

Adds one or more handles which are to be tied to the lifecycle of the object.

Accessor
*

Creates a new instance of this class and initializes it with values from a JSON object generated from an ArcGIS product.

ServiceDefinition

Returns true if a named group of handles exist.

Accessor

Removes a group of handles owned by the object.

Accessor

Converts an instance of this class to its ArcGIS portal JSON representation.

ServiceDefinition

Method Details

addHandles

Inherited
Method
addHandles(handleOrHandles, groupKey)
Inherited from Accessor

Adds one or more handles which are to be tied to the lifecycle of the object. The handles will be removed when the object is destroyed.

// Manually manage handles
const handle = reactiveUtils.when(
  () => !view.updating,
  () => {
    wkidSelect.disabled = false;
  },
  { once: true }
);

this.addHandles(handle);

// Destroy the object
this.destroy();
Parameters
handleOrHandles WatchHandle|WatchHandle[]

Handles marked for removal once the object is destroyed.

groupKey *
optional

Key identifying the group to which the handles should be added. All the handles in the group can later be removed with Accessor.removeHandles(). If no key is provided the handles are added to a default group.

fromJSON

Method
fromJSON(json){*}static

Creates a new instance of this class and initializes it with values from a JSON object generated from an ArcGIS product. The object passed into the input json parameter often comes from a response to a query operation in the REST API or a toJSON() method from another ArcGIS product. See the Using fromJSON() topic in the Guide for details and examples of when and how to use this function.

Parameter
json Object

A JSON representation of the instance in the ArcGIS format. See the ArcGIS REST API documentation for examples of the structure of various input JSON objects.

Returns
Type Description
* Returns a new instance of this class.

hasHandles

Inherited
Method
hasHandles(groupKey){Boolean}
Inherited from Accessor

Returns true if a named group of handles exist.

Parameter
groupKey *
optional

A group key.

Returns
Type Description
Boolean Returns true if a named group of handles exist.
Example
// Remove a named group of handles if they exist.
if (obj.hasHandles("watch-view-updates")) {
  obj.removeHandles("watch-view-updates");
}

removeHandles

Inherited
Method
removeHandles(groupKey)
Inherited from Accessor

Removes a group of handles owned by the object.

Parameter
groupKey *
optional

A group key or an array or collection of group keys to remove.

Example
obj.removeHandles(); // removes handles from default group

obj.removeHandles("handle-group");
obj.removeHandles("other-handle-group");

toJSON

Method
toJSON(){Object}

Converts an instance of this class to its ArcGIS portal JSON representation. See the Using fromJSON() guide topic for more information.

Returns
Type Description
Object The ArcGIS portal JSON representation of an instance of this class.

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.