Skip to main content

This is documentation for Caché & Ensemble. See the InterSystems IRIS version of this content.Opens in a new tab

For information on migrating to InterSystems IRISOpens in a new tab, see Why Migrate to InterSystems IRIS?

SOAP.Demo

class SOAP.Demo extends SOAP.BaseService

A simple demonstration Web Service
To try this, visit /csp/samples/SOAP.Demo.cls This web service inherits from the SOAP.BaseService sample class to pickup common error handling.

Method Inventory

Parameters

parameter NAMESPACE = http://tempuri.org;
Namespace. Change this to your own namespace when you deploy a service.
parameter SERVICENAME = SOAPDemo;
This is the name of our web service.
parameter SOAPHEADERS = LicenseInfo:SOAP.LicenseInfo;
The list of request SOAP headers that are supported by this web service. Each entry in the comma separated list is of the form "headerElement:headerClassname".

Methods

method AddInteger(Arg1 As %Integer, Arg2 As %Integer) as %Integer [ WebMethod ]
Adds two integers and returns the result.
method DivideInteger(Arg1 As %Integer, Arg2 As %Integer) as %Integer [ WebMethod ]
method FindPerson(id As %String) as Sample.Person [ WebMethod ]
Returns data about the person in the database with object ID of id.
method GetByName(name As %String) as %XML.DataSet [ WebMethod ]
A sample web method to invoke dynamic SQL to query the Sample.Person class and return the results as a .NET untyped DataSet
method GetDataSetByName(name As %String) as SOAP.ByNameDataSet [ WebMethod ]
A sample web method to invoke the ByName query of the Sample.Person class and return the results as a .NET typed DataSet
method GetListByName(name As %String) as Sample.ListOfPersonIdentification [ WebMethod ]
A sample web method to invoke dynamic SQL to query the Sample.Person class and return the results as a list of objects.
method LookupCity(zip As %String) as Sample.Address [ WebMethod ]
Returns the city and state for the given U.S. ZIP Code packaged within a Sample.Address object.
method Mission() as %String [ WebMethod ]
Returns a corporate mission statement.

Queries

query QueryByName(name As %String)
SQL Query:
SELECT ID, Name, DOB, SSN FROM Sample.Person WHERE (Name %STARTSWITH :name) ORDER BY Name
A sample class query as a WebMethod that defines a typed dataset that returns Person data ordered by Name.
This query also generates a WebMethod of the same name that may be called using SOAP in order to return a typed .Net DataSet.

Inherited Members

Inherited Properties

Inherited Methods

FeedbackOpens in a new tab