1 // Licensed under the Apache License, Version 2.0
2 // <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
3 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option.
4 // All files in the project carrying such notice may not be copied, modified, or distributed
5 // except according to those terms.
6 //! This file contains structures, function prototypes, and definitions for the NetMessage API
7 use shared::lmcons::NET_API_STATUS;
8 use shared::minwindef::{DWORD, LPBYTE, LPDWORD};
9 use um::winnt::{LPCWSTR, LPWSTR};
10 extern "system" {
NetMessageNameAdd( servername: LPCWSTR, msgname: LPCWSTR, ) -> NET_API_STATUS11     pub fn NetMessageNameAdd(
12         servername: LPCWSTR,
13         msgname: LPCWSTR,
14     ) -> NET_API_STATUS;
NetMessageNameEnum( servername: LPCWSTR, level: DWORD, bufptr: *mut LPBYTE, prefmaxlen: DWORD, entriesread: LPDWORD, totalentries: LPDWORD, resumehandle: LPDWORD, ) -> NET_API_STATUS15     pub fn NetMessageNameEnum(
16         servername: LPCWSTR,
17         level: DWORD,
18         bufptr: *mut LPBYTE,
19         prefmaxlen: DWORD,
20         entriesread: LPDWORD,
21         totalentries: LPDWORD,
22         resumehandle: LPDWORD,
23     ) -> NET_API_STATUS;
NetMessageNameGetInfo( servername: LPCWSTR, msgname: LPCWSTR, level: DWORD, bufptr: *mut LPBYTE, ) -> NET_API_STATUS24     pub fn NetMessageNameGetInfo(
25         servername: LPCWSTR,
26         msgname: LPCWSTR,
27         level: DWORD,
28         bufptr: *mut LPBYTE,
29     ) -> NET_API_STATUS;
NetMessageNameDel( servername: LPCWSTR, msgname: LPCWSTR, ) -> NET_API_STATUS30     pub fn NetMessageNameDel(
31         servername: LPCWSTR,
32         msgname: LPCWSTR,
33     ) -> NET_API_STATUS;
NetMessageBufferSend( servername: LPCWSTR, msgname: LPCWSTR, fromname: LPCWSTR, buf: LPBYTE, buflen: DWORD, ) -> NET_API_STATUS34     pub fn NetMessageBufferSend(
35         servername: LPCWSTR,
36         msgname: LPCWSTR,
37         fromname: LPCWSTR,
38         buf: LPBYTE,
39         buflen: DWORD,
40     ) -> NET_API_STATUS;
41 }
42 STRUCT!{struct MSG_INFO_0 {
43     msgi0_name: LPWSTR,
44 }}
45 pub type PMSG_INFO_0 = *mut MSG_INFO_0;
46 pub type LPMSG_INFO_0 = *mut MSG_INFO_0;
47 STRUCT!{struct MSG_INFO_1 {
48     msgi1_name: LPWSTR,
49     msgi1_forward_flag: DWORD,
50     msgi1_forward: LPWSTR,
51 }}
52 pub type PMSG_INFO_1 = *mut MSG_INFO_1;
53 pub type LPMSG_INFO_1 = *mut MSG_INFO_1;
54 pub const MSGNAME_NOT_FORWARDED: DWORD = 0;
55 pub const MSGNAME_FORWARDED_TO: DWORD = 0x04;
56 pub const MSGNAME_FORWARDED_FROM: DWORD = 0x10;
57