RTI_GET_PROC_INFO Function
Description
This function returns meta-information for a specified stored procedure or event name, such as the number of arguments, its type and so on.
Syntax
ProcInfo = RTI_Get_Proc_Info( ProcID, IsEvent )
Parameters
The function has the following parameters:
Parameter | Description |
---|---|
ProcID [Required] | Contains the name of the stored procedure or event to process. When searching for a stored procedure the normal application inheritance chain is respected unless the ProcID is suffixed with a specific Application ID, in which case no resolution is performed. e.g. "MYPROC" Searches the inheritance chain "MYPROC*EXAMPLES" Only checks the EXAMPLES app to see if MYPROC exists |
IsEvent [Optional] | If set to TRUE$ (1) then ProcID is assumed to be a key to the SYSREPOSEVENTEXES table, i.e: <appID> "*" <eventID> "*" <objectID> |
Returns
If the procedure or event exists then an @fm-delimited array of information is returned describing the attributes of the specified program:
<1> Proc type <2> Argument count <3> Variable count <4> Expendable flag <5> DLL name <6> DLL exported function name <7> DLL Return Type <8> DLL Calling convention <9> DLL argument list type <10> OE DLL Internal pointer number <11> Basic+ Proc Type (subroutine (1), function(2), routine(3) ) <12> Compile User <13> Compile Time <14> ArgNames <15> ArgTypes <16> ResultRow Type
Note that some fields are only used if the specified function is a DLL function rather than a normal Basic+ one.
Remarks
Equates are provided for use with this function. See the RTI_Get_Proc_Info_Equates insert record for more information.
See Also
Example
// Example: Get the meta-information for the MYPROC function // and check that it _is_ a function. Declare Function RTI_Get_Proc_Info $Insert RTI_Get_Proc_Info_Equates ProcInfo = RTI_Get_Proc_Info( "MYPROC" ) IsFunc = ( ProcInfo<GPI_OEPROCTYPE$> = GPI_OEPROCTYPE_FUNC$ )