JoltGetName Function

Action

Retrieves the name of the service.

Include file

Jolt.bdh

Syntax

JoltGetName( in  hRemoteService : number,
             out sName          : string,
             in  nNameSize      : number optional ): boolean;

Return value

  • true if successful

  • false otherwise

Parameter Description
hRemoteService Handle to a JoltRemoteService object that was created with JoltRemoteServiceNew
sName String variable receiving the service name
nNameSize Size of the string variable that receives the service name (optional).

Example

var
  hSession, hSessionAttr, hInquiry: number;
 dcltrans
  transaction TInit
  var
    sName: string;
  begin
    JavaSetOption(JAVA_VERSION, JAVA_V11);
    JavaSetOption(JAVA_HOME, "c:/jdk1.1.7");
    JavaSetOption(JAVA_CLASSPATH, "c:/jdk1.1.7");
    JoltInit();
    hSessionAttr := JoltSessionAttributesNew();
    JoltSetString(hSessionAttr, APPADDRESS, "//lab:8000");
    hSession := JoltSessionNew(hSessionAttr, "", "ATM", "", "");
    hInquiry := JoltRemoteServiceNew("INQUIRY", hSession);
    JoltGetName(hInquiry, sName);
    writeln(sName);
  end TInit; 

  transaction TShutdown
  begin    JoltEndSession(hSession);
    JoltFreeObject(hInquiry);
    JoltFreeObject(hSession);
    JoltFreeObject(hSessionAttr);
  end TShutdown;

See also

Java: bea.jolt.JoltRemoteService class