HP Anywhere 10.02 API Reference
Show:

HPA.Server Class

Module: HPA

Available since HP Anywhere 10.00

Server API - helper methods for client-server communication.

Methods

getAppFolder

() String

Base path of HP Anywhere URL

Returns:

String: always "app"

getAppName

() String

Get the app name.

Returns:

String: The app name.

request

(
  • opts
)
async

Send an HTTP request to the HPA server.

Special properties for requestObject:

 uri:       {String}          the relative uri of the requested resource
 appId: {String} [optional]   unique app ID, useful in the event that the current app attempts to access another app

Important: Ajax server requests are asynchronous, and this call will return before the response has been received. Process any returned data in a callback function. Based on Sencha’s Ajax API. See also Sencha's documentation.

Parameters:

  • opts Object

    filled with relevant data in order to submit an http request

resourceUrl

(
  • relativePath
  • appId
)
String deprecated

Deprecated: Apps can generate URIs by themselves.

Available since HP Anywhere 10.00

Service provided by the given app to submit a valid REST URI to the request.

Parameters:

  • relativePath String

    Relative path of the resource.

  • appId String

    ID of the provider app.

Returns:

String: A valid REST URI.