Important: The information in this document is obsolete and should not be used for new development.
ASPGetStatus
TheASPGetStatus
function returns status information about the server whose internet socket address you provide.
FUNCTION ASPGetStatus (thePBptr: XPPParmBlkPtr; async: Boolean): OSErr;
thePBptr
- A pointer to an XPP parameter block.
async
- A Boolean that specifies whether the function should be executed asynchronously or synchronously. Specify
TRUE
for asynchronous execution.
--> ioCompletion ProcPtr A pointer to a completion routine. <-- ioResult OSErr The function result. --> ioRefNum Integer The .XPP driver reference number. --> csCode Integer Always getStatus for this function. --> aspTimeout Byte The retry interval in seconds. --> aspRetry Byte The number of retries. --> serverAddr AddrBlock The server socket address. <-> rbSize Integer The reply buffer and reply size. --> rbPtr Ptr A pointer to the reply buffer. <-- ccbStart Array The beginning of memory for the CCB.
Field Description
aspTimeout
- The time in seconds after which ASP is to retry to obtain information about the status of the server whose address
you provide.aspRetry
- The number of times ASP is to retry to obtain the server status information.
serverAddr
- The internet socket address of the server about which you want status information.
rbSize
- On input, the size in bytes of the buffer that you allocated to contain the reply that you expect to receive from the server. On return, the size in bytes of the reply (status) data that was actually returned.
rbPtr
- A pointer to the buffer for the reply data.
ccbStart
- The beginning of the memory for the command control block (CCB) that the .XPP driver is to use. The memory allocated for the CCB must not exceed the maximum of 150 bytes.
DESCRIPTION
You can use theASPGetStatus
function to obtain service status information about a server without opening a session between your application and that server. ASP does not impose any structure on the status block. The protocol above ASP defines the structure. The .XPP driver uses the memory at the end of the XPP parameter block defined as
aCCBStart
array as an internal command control block (CCB). To ensure that the function executes successfully, you can specify the maximum size for this array as indicated in particular for the function that uses it. If you want to limit the amount of memory used for the CCB, you can specify the minimum amount of memory required for this array.SPECIAL CONSIDERATIONS
Note that you must provide the .XPP driver reference number as an input parameter
to this function. You can obtain the driver reference number by calling the Device Manager'sOpenDriver
function.ASSEMBLY-LANGUAGE INFORMATION
To execute theASPGetStatus
function from assembly language, call the_Control
trap macro with a value ofgetStatus
in thecsCode
field of the parameter block.
You must also specify the .XPP driver reference number. To execute the_Control
trap asynchronously, include the value,ASYNC
in the operand field.RESULT CODES
aspBufTooSmall -1067 The reply data exceeds the size of the reply buffer; the .XPP driver will fill the buffer and truncate the data aspNoServer -1069 There was no response from the server whose address you specified as the value of serverAddr
SEE ALSO
To determine the minimum amount of memory required for the CCB, refer to the description of theASPUserCommand
function on page 8-15.