656d009690feff983bdd09afbbbc2435d20203f8
[reactos.git] / reactos / subsys / csrss / include / csrplugin.h
1 /* $Id$
2 *
3 * COPYRIGHT: See COPYING in the top level directory
4 * PROJECT: ReactOS system libraries
5 * FILE: subsys/csrss/include/csrplugin.h
6 * PURPOSE: CSRSS plugin interface
7 */
8
9 /*
10 * CSRSS is a native application and can only implicitly link against native
11 * DLLs. Since e.g. user32.dll and gdi32.dll are win32 DLLs and not native
12 * DLLs it is not possible to call functions in those DLLs directly from
13 * CSRSS.
14 * However, it is possible to explicitly load a non-native DLL. Such a DLL
15 * can then in turn be implicitly linked against other DLLs in its own
16 * subsystem.
17 */
18
19 #ifndef CSRPLUGIN_H_INCLUDED
20 #define CSRPLUGIN_H_INCLUDED
21
22 #include <windows.h>
23 #include "api.h"
24
25 typedef NTSTATUS (STDCALL *CSRSS_INSERT_OBJECT_PROC)(PCSRSS_PROCESS_DATA ProcessData,
26 PHANDLE Handle,
27 Object_t *Object);
28 typedef NTSTATUS (STDCALL *CSRSS_GET_OBJECT_PROC)(PCSRSS_PROCESS_DATA ProcessData,
29 HANDLE Handle,
30 Object_t **Object);
31 typedef NTSTATUS (STDCALL *CSRSS_RELEASE_OBJECT_PROC)(PCSRSS_PROCESS_DATA ProcessData,
32 HANDLE Object );
33
34 typedef struct tagCSRSS_EXPORTED_FUNCS
35 {
36 CSRSS_INSERT_OBJECT_PROC CsrInsertObjectProc;
37 CSRSS_GET_OBJECT_PROC CsrGetObjectProc;
38 CSRSS_RELEASE_OBJECT_PROC CsrReleaseObjectProc;
39 } CSRSS_EXPORTED_FUNCS, *PCSRSS_EXPORTED_FUNCS;
40
41 typedef BOOL (STDCALL *CSRPLUGIN_INIT_COMPLETE_PROC)(void);
42
43 typedef BOOL (STDCALL *CSRPLUGIN_INITIALIZE_PROC)(PCSRSS_API_DEFINITION *ApiDefinitions,
44 PCSRSS_OBJECT_DEFINITION *ObjectDefinitions,
45 CSRPLUGIN_INIT_COMPLETE_PROC *InitCompleteProc,
46 PCSRSS_EXPORTED_FUNCS Exports,
47 HANDLE CsrssApiHeap);
48
49 #endif /* CSRPLUGIN_H_INCLUDED */
50
51 /* EOF */