/*
 * $Id: hb_vm.txt 12560 2009-09-19 14:30:32Z april $
 */

/*
 * The following parts are Copyright of the individual authors.
 * www - http://www.harbour-project.org
 *
 * Copyright 1999 Antonio Linares <alinares@fivetech.com>
 *   Header file for the API
 *  $SUBCATEGORY$
 *      Virtual machine
 *
 * See COPYING for licensing terms.
 *
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmInit()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmInit( BOOL bStartMainProc )
 *  $ARGUMENTS$
 *      <bStartMainProc>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Function
 *  $NAME$
 *      hb_vmQuit()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Immediately quits the virtual machine
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmQuit( void ) --> int
 *  $ARGUMENTS$
 *
 *  $RETURNS$
 *      ERRORLEVEL code
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmExecute()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Invokes the virtual machine
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmExecute( const BYTE * pCode, PHB_SYMB pSymbols )
 *  $ARGUMENTS$
 *      <pCode>
 *
 *      <pSymbols>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmProcessSymbols()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Statics symbols initialization
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmProcessSymbols( PHB_SYMB pSymbols, USHORT uiSymbols )
 *  $ARGUMENTS$
 *      <pSymbols>
 *
 *      <uiSymbols>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmSymbolInit_RT()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Initialization of runtime support symbols
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmSymbolInit_RT( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmRequestQuit()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmRequestQuit( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmRequestEndProc()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmRequestEndProc( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmRequestCancel()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmRequestCancel( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmRequestBreak()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmRequestBreak( PHB_ITEM pItem )
 *  $ARGUMENTS$
 *      <pItem>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Function
 *  $NAME$
 *      hb_vmRequestQuery()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmRequestQuery( void ) --> ( USHORT )usResult
 *  $ARGUMENTS$
 *
 *  $RETURNS$
 *      <usResult>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmMessage()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Sends a message to an object
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmMessage( PHB_SYMB pSymMsg )
 *  $ARGUMENTS$
 *      <pSymMsg>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmDo()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Invoke the virtual machine
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmDo( USHORT uiParams )
 *  $ARGUMENTS$
 *      <uiParams>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmFunction()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Executes a function saving its result
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmFunction( USHORT uiParams )
 *  $ARGUMENTS$
 *      <uiParams>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmSend()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Sends a message to an object
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmSend( USHORT uiParams )
 *  $ARGUMENTS$
 *      <uiParams>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Function
 *  $NAME$
 *      hb_vmEvalBlock()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Executes passed codeblock with no arguments
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmEvalBlock( PHB_ITEM pBlockItem ) --> ( PHB_ITEM )pResult
 *  $ARGUMENTS$
 *      <pBlockItem>
 *  $RETURNS$
 *      <pResult>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Function
 *  $NAME$
 *      hb_vmEvalBlockV()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmEvalBlockV( PHB_ITEM pBlockItem, USHORT uiArgCount, ... ) --> ( PHB_ITEM )pResult
 *  $ARGUMENTS$
 *      <pBlockItem>
 *
 *      <uiArgCount>
 *
 *      <...>
 *  $RETURNS$
 *      <pResult>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPush()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a generic item onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPush( PHB_ITEM pItem )
 *  $ARGUMENTS$
 *      <pItem>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushNil()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      In this case it places nil at self
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushNil( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushNumber()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a number on to the stack and decides if it is integer, long or double
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushNumber( double dNumber, int iDec )
 *  $ARGUMENTS$
 *      <dNumber>
 *
 *      <iDec>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushInteger()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a integer number onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushInteger( int iNumber )
 *  $ARGUMENTS$
 *      <iNumber>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushLong()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a long number onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushLong( long lNumber )
 *  $ARGUMENTS$
 *      <lNumber>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushDouble()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a double number onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushDouble( double lNumber, int iDec )
 *  $ARGUMENTS$
 *      <lNumber>
 *
 *      <iDec>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushLogical()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a logical value onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushLogical( BOOL bValue )
 *  $ARGUMENTS$
 *      <bValue>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushString()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a string on to the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushString( char * szText, ULONG length )
 *  $ARGUMENTS$
 *      <szText>
 *
 *      <length>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushDate()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a long date onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushDate( long lDate )
 *  $ARGUMENTS$
 *      <lDate>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushSymbol()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pushes a function pointer onto the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushSymbol( PHB_SYMB pSym )
 *  $ARGUMENTS$
 *      <pSym>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_vmPushPointer()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Push an item of HB_IT_POINTER type
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_vmPushPointer( void * )
 *  $ARGUMENTS$
 *      <void *>
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_stackDispCall()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_stackDispCall( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */

/*  $DOC$
 *  $TEMPLATE$
 *      Procedure
 *  $NAME$
 *      hb_stackPop()
 *  $CATEGORY$
 *      C level API
 *  $SUBCATEGORY$
 *      Virtual machine
 *  $ONELINER$
 *      Pops an item from the stack
 *  $SYNTAX$
 *      C Prototype
 *
 *      #include <hbvm.h>
 *      hb_stackPop( void )
 *  $ARGUMENTS$
 *
 *  $DESCRIPTION$
 *
 *  $EXAMPLES$
 *
 *  $STATUS$
 *      R
 *  $COMPLIANCE$
 *      NA
 *  $FILES$
 *      Library is vm
 *  $PLATFORMS$
 *      All
 *  $SEEALSO$
 *
 *  $END$
 */
