Force.com Apex Code Developer's Guide
Summer '26 (API version 67.0)
Spring '26 (API version 66.0)
Winter '26 (API version 65.0)
Summer '25 (API version 64.0)
Spring '25 (API version 63.0)
Winter '25 (API version 62.0)
Summer '24 (API version 61.0)
Spring '24 (API version 60.0)
Winter '24 (API version 59.0)
Summer '23 (API version 58.0)
Spring '23 (API version 57.0)
Winter '23 (API version 56.0)
Summer '22 (API version 55.0)
Spring '22 (API version 54.0)
Winter '22 (API version 53.0)
Summer '21 (API version 52.0)
Spring '21 (API version 51.0)
Winter '21 (API version 50.0)
Summer '20 (API version 49.0)
Spring '20 (API version 48.0)
Winter '20 (API version 47.0)
Summer '19 (API version 46.0)
Spring '19 (API version 45.0)
Winter '19 (API version 44.0)
Summer '18 (API version 43.0)
Spring '18 (API version 42.0)
Winter '18 (API version 41.0)
Summer '17 (API version 40.0)
Spring '17 (API version 39.0)
Winter '17 (API version 38.0)
Summer '16 (API version 37.0)
Spring '16 (API version 36.0)
Winter '16 (API version 35.0)
Summer '15 (API version 34.0)
Spring '15 (API version 33.0)
Winter '15 (API version 32.0)
Spring '14 (API version 30.0)
AuthenticationCapability Enum
AuthenticationProtocol Enum
Capability Enum
DataType Enum
FilterType Enum
IdentityType Enum
OrderDirection Enum
QueryAggregation Enum
DataSource Exceptions
Glossary
Newer Version Available
DataSource Namespace
The DataSource namespace provides the classes for the Apex Connector Framework.
Use the Apex Connector Framework to develop a custom adapter for Lightning Connect.
Then connect your Salesforce organization to any
data anywhere via the Lightning Connect custom adapter.
The following are the classes in the DataSource namespace.
-
AuthenticationCapability Enum
Specifies the types of authentication that can be used to access the external system. -
AuthenticationProtocol Enum
Determines what type of credentials are used to authenticate to the external system. -
Capability Enum
Declares which functional operations the external system supports. Also specifies required endpoint settings for the external data source definition. -
Column Class
Describes a column on a DataSource.Table. -
ColumnSelection Class
Identifies the list of columns to return during a query or search. -
Connection Class
Extend this class to enable your Salesforce organization to sync the external system’s schema and to handle queries and searches of the external data. -
ConnectionParams Class
Contains the credentials for authenticating to the external system. -
DataSourceUtil Class
Parent class for the DataSource.Provider and DataSource.Connection classes. -
DataType Enum
Specifies the data types that are supported by the Apex Connector Framework. -
Filter Class
Represents a WHERE clause in a SOSL or SOQL query. -
FilterType Enum
Referenced by the type property on a DataSource.Filter. -
IdentityType Enum
Determines which set of credentials is used to authenticate to the external system. -
Order Class
Contains details about how to sort the rows in the result set. Equivalent to an ORDER BY statement in a SOQL query. -
OrderDirection Enum
Specifies the direction for sorting rows based on column values. -
Provider Class
Extend this base class to create a custom adapter for Lightning Connect. The class informs Salesforce of the functional and authentication capabilities that are supported by or required to connect to the external system. -
QueryAggregation Enum
Specifies how to aggregate a column in a query. -
QueryContext Class
An instance of QueryContext is provided to the query method on your DataSource.Connection class. The instance corresponds to a SOQL request. -
QueryUtils Class
Contains helper methods to locally filter, sort, and apply limit and offset clauses to data rows. This helper class is provided for your convenience during early development and tests, but it isn’t supported for use in production environments. -
ReadContext Class
Abstract base class for the QueryContext and SearchContext classes. -
SearchContext Class
An instance of SearchContext is provided to the search method on your DataSource.Connection class. The instance corresponds to a search or SOSL request. -
SearchUtils Class
Helper class for implementing search on a custom adapter for Lightning Connect. -
Table Class
Describes a table on an external system that the Lightning Connect custom adapter connects to. -
TableResult Class
Contains the results of a search or query. -
TableSelection Class
Contains a breakdown of the SOQL or SOSL query. Its properties represent the FROM, ORDER BY, SELECT, and WHERE clauses in the query. -
DataSource Exceptions
The DataSource namespace contains exception classes.