Home > Class Reference > ENSLIB namespace > EnsLib.REST.Service

EnsLib.REST.Service

abstract class EnsLib.REST.Service extends EnsLib.HTTP.Service, %CSP.REST, Ens.Util.JSON

Ensemble REST Service class. Can use an HTTP InboundAdapter listener, or the standard CSP Service mechanism, or both. In order for the CSP mechanism to work, HTTP Services using this class must be configured with the invoking URL including ?CfgItem= giving the config item name. (Configured Services exposed using the HTTP Inbound Adapter may also be invoked with this URL parameter but because each configured Inbound Adapter listens on its own TCP/IP port this parameter is just a safety check for them.)

Method Inventory (Including Private)

Parameters

parameter ADAPTER = EnsLib.HTTP.InboundAdapter;
Inherited description: Name of the adapter class - override this to "" if you want to use only the regular HTTP mechanism and not the custom-port HTTP InboundAdapter.
parameter EnsServicePrefix;
This prefix will be removed from the beginning of the actual URL before matching it against the UrlMap. If this prefix begins with '^' then the CSP Application will also be removed from the beginning of the URL if this service is being invoked via the CSP gateway. If this prefix begins with '|' then the Ensemble Config Name for this service will be removed from the beginning of the URL, as well as the CSP Application if this service is being invoked via the CSP gateway.
parameter PREFIXCASESENSITIVE = 0;

Methods (Including Private)

method OnProcessInput(pInput As %Library.AbstractStream, Output pOutput As %Stream.Object = $$$NULLOREF, ByRef pHint As %Library.String) as %Status
Override OnProcessInput() this in your subclass if you want to handle dispatching yourself
final classmethod Page(skipheader As %Boolean = 1) as %Status
Inherited description: This method matches the request and method and calls the dispatcher

Inherited Members

Inherited Properties (Including Private)

Inherited Methods (Including Private)