⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pidll.h

📁 mini http server,可以集成嵌入到程序中,实现简单的web功能
💻 H
字号:
/*____________________________________________________________________________*\
 *

 Copyright (c) 1997-2003 John Roy, Holger Zimmermann. All rights reserved.

 These sources, libraries and applications are
 FREE FOR COMMERCIAL AND NON-COMMERCIAL USE
 as long as the following conditions are adhered to.

 Redistribution and use in source and binary forms, with or without
 modification, are permitted provided that the following conditions
 are met:

 1. Redistributions of source code must retain the above copyright
    notice, this list of conditions and the following disclaimer. 

 2. Redistributions in binary form must reproduce the above copyright
    notice, this list of conditions and the following disclaimer in
    the documentation and/or other materials provided with the
    distribution.

 3. The name of the author may not be used to endorse or promote products
    derived from this software without specific prior written permission.

 THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
 OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 IN NO EVENT SHALL THE AUTHORS OR ITS CONTRIBUTORS BE LIABLE FOR ANY
 DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
 STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
 OF THE POSSIBILITY OF SUCH DAMAGE.

 *____________________________________________________________________________*|
 *
 * $Source: /cvsroot/pi3web/Pi3Web_200/Source/PiAPI/PIDLL.h,v $
 * $Date: 2003/05/13 18:42:12 $
 *
 Description:
\*____________________________________________________________________________*/
/* $HeaderTop:$ */

#ifndef PIDLL_H_
#define PIDLL_H_

#include "PiAPI.h"

/*____________________________________________________________________________*\
 *
 Typedefs:
\*____________________________________________________________________________*/
typedef struct DLL PIDLL;

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_new

 Synopsis:
	PIDLL *PIDLL_new( const char *pPath )

 Description:
	Create a new dynamic link library object by loading the
	library pointed to by pPath.

 Notes:

 Return Values:
	On success PIDLL_new returns a pointer to a new dynamic link
	library.

 Errors:
	If pPath is NULL or memory cannot be allocated PIDLL_new() will
	return NULL.

	More specific error information can be retrieved using
	PIPlatform_getLastError().

 See Also:
	PIDLL_delete().
\*____________________________________________________________________________*/
PUBLIC_PIAPI PIDLL *PIDLL_new( const char *pPath );

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_isLoaded

 Synopsis:
	int PIDLL_isLoaded( const PIDLL *pDLL )

 Description:
	Indicates whether or not a new DLL object actually represents
	a loaded dynamic link library.

 Notes:

 Return Values:
	PIDLL_isLoaded() returns either PIAPI_TRUE or PIAPI_FALSE. If
	PIAPI_FALSE is returned and no error code is set (see below), the
	function PIDLL_getErrorDescription() can be used to get a
	text description of the reason the library could not be loaded.

 Errors:
	On error PIDLL_isLoaded() returns PIAPI_FALSE and sets the
	error code to a value other than PIAPI_COMPLETED. This error
	code may be retrieved using PIPlatform_getLastError().

 See Also:
	PIDLL_new().
\*____________________________________________________________________________*/
PUBLIC_PIAPI int PIDLL_isLoaded( const PIDLL *pDLL );

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_delete

 Synopsis:
	int PIDLL_delete( PIDLL *pDLL )

 Description:
	Destroys and free memory associated with the dynamic link object
	pDLL.

 Notes:
	Whether or not the DLL is unloaded from the address space of
	the process is implementation specific. Typically a DLL only
	becomes unloaded when the load reference count reaches zero.

 Return Values:
	On success PIDLL_delete() returns zero (PIAPI_COMPLETED).

 Errors:
	On error PIDLL_delete() returns a negative value.

	More specific error information can be retrieved using
	PIPlatform_getLastError().

 See Also:
	PIDLL_new()
\*____________________________________________________________________________*/
PUBLIC_PIAPI int PIDLL_delete( PIDLL *pDLL );

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_getAddress

 Synopsis:
	void *PIDLL_getAddress( PIDLL *pDLL, const char *pSymbolName )

 Description:
	Returns the address of symbol pSymbolName is the DLL pDLL.

 Notes:
	This function is intended primarily for retrieving the address
	of functions with "C" linkage.

 Return Values:
	On success PIDLL_getAddress() returns a pointer to the memory
	address of the required symbol.

 Errors:
	PIDLL_getAddress returns NULL if the address of the function
	could not be retrieved.

	More specific error information can be retrieved using
	PIPlatform_getLastError().

	Additionally the PIDLL_getErrorDescription() can be used to get
	an english description of the last error.

 See Also:
\*____________________________________________________________________________*/
PUBLIC_PIAPI void *PIDLL_getAddress( PIDLL *pDLL, const char *pSymbolName );

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_getErrorDescription

 Synopsis:
	const char *PIDLL_getErrorDescription( const PIDLL *pDLL )

 Description:
	Returns an english description of the last error which 
	occurred when performing a DLL operation.	

 Notes:
	The error message string is allocate by the DLL object and
	is invalided by invoking another operation on that DLL or
	destroying the DLL object with PIDLL_delete().

 Return Values:
	PIDLL_getErrorDescription() always returns an error 
	description.

 Errors:
	None.

 See Also:
\*____________________________________________________________________________*/
PUBLIC_PIAPI const char *PIDLL_getErrorDescription( const PIDLL *pDLL );

/*____________________________________________________________________________*\
 *
 Name:
	PIDLL_getSystemHandle()

 Synopsis:
	void *PIDLL_getSystemHandle( const PIDLL *pDLL )

 Description:
	Returns the operating system specific handle of the DLL.

 Notes:

 Return Values:
	Returns the operating system specific handle of the DLL.

 Errors:
	None.

 See Also:
\*____________________________________________________________________________*/
PUBLIC_PIAPI void *PIDLL_getSystemHandle( const PIDLL *pDLL );

#endif	/* PIDLL_H_ */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -