2003-11-21 13:14:17 +00:00
2003-11-09 08:31:36 +00:00
[
2004-10-27 04:48:41 +00:00
uuid("60a15ec5-4de8-11d7-a637-005056a20182"),
2004-10-24 14:57:16 +00:00
endpoint("ncacn_np:[\\pipe\\rpcecho]", "ncacn_ip_tcp:", "ncalrpc:"),
2005-02-12 23:03:26 +00:00
pointer_default(unique),
2004-08-16 19:03:22 +00:00
version(1.0),
2006-09-18 21:52:00 +00:00
helpstring("Simple echo pipe")
2003-11-09 08:31:36 +00:00
]
interface rpcecho
{
/* Add one to an integer */
void echo_AddOne(
2005-06-01 00:00:50 +00:00
[in] uint32 in_data,
[out] uint32 *out_data
2003-11-09 08:31:36 +00:00
);
/* Echo an array of bytes back at the caller */
void echo_EchoData(
[in] uint32 len,
2003-11-13 09:26:53 +00:00
[in] [size_is(len)] uint8 in_data[],
[out] [size_is(len)] uint8 out_data[]
2003-11-09 08:31:36 +00:00
);
/* Sink data to the server */
void echo_SinkData(
[in] uint32 len,
2005-06-01 00:00:50 +00:00
[in,size_is(len)] uint8 data[]
2003-11-09 08:31:36 +00:00
);
/* Source data from server */
void echo_SourceData(
[in] uint32 len,
2005-06-01 00:00:50 +00:00
[out,size_is(len)] uint8 data[]
2003-11-09 08:31:36 +00:00
);
2003-11-13 09:26:53 +00:00
2003-11-19 12:03:11 +00:00
/* test strings */
2003-12-14 13:22:12 +00:00
void echo_TestCall (
2005-06-18 16:31:48 +00:00
[in,string,charset(UTF16)] uint16 *s1,
2006-09-15 20:07:55 +00:00
[out,string,charset(UTF16)] uint16 **s2
2003-11-19 12:03:11 +00:00
);
/* test some alignment issues */
typedef struct {
uint8 v;
} echo_info1;
typedef struct {
uint16 v;
} echo_info2;
typedef struct {
uint32 v;
} echo_info3;
2007-02-28 13:25:53 +00:00
struct echo_info4 {
2005-01-27 06:33:07 +00:00
hyper v;
2007-02-28 13:25:53 +00:00
};
2003-11-19 12:03:11 +00:00
typedef struct {
uint8 v1;
2005-01-27 06:33:07 +00:00
hyper v2;
2003-11-19 12:03:11 +00:00
} echo_info5;
typedef struct {
uint8 v1;
echo_info1 info1;
} echo_info6;
typedef struct {
uint8 v1;
2007-02-28 13:25:53 +00:00
struct echo_info4 info4;
2003-11-19 12:03:11 +00:00
} echo_info7;
2005-03-06 17:02:14 +00:00
typedef [switch_type(uint16)] union {
2003-11-19 12:03:11 +00:00
[case(1)] echo_info1 info1;
[case(2)] echo_info2 info2;
[case(3)] echo_info3 info3;
2007-02-28 13:25:53 +00:00
[case(4)] struct echo_info4 info4;
2003-11-19 12:03:11 +00:00
[case(5)] echo_info5 info5;
[case(6)] echo_info6 info6;
[case(7)] echo_info7 info7;
} echo_Info;
2003-12-14 13:22:12 +00:00
NTSTATUS echo_TestCall2 (
2003-11-20 01:32:43 +00:00
[in] uint16 level,
2003-11-19 12:03:11 +00:00
[out,switch_is(level)] echo_Info *info
2003-11-13 09:26:53 +00:00
);
2004-08-30 07:36:16 +00:00
uint32 echo_TestSleep(
[in] uint32 seconds
);
2005-01-04 23:27:12 +00:00
typedef enum {
ECHO_ENUM1 = 1,
ECHO_ENUM2 = 2
} echo_Enum1;
typedef [v1_enum] enum {
ECHO_ENUM1_32 = 1,
ECHO_ENUM2_32 = 2
} echo_Enum1_32;
typedef struct {
2007-02-21 11:51:51 +00:00
echo_Enum1 e1;
2005-01-04 23:27:12 +00:00
echo_Enum1_32 e2;
} echo_Enum2;
2005-06-01 00:00:50 +00:00
typedef [switch_type(uint16)] union {
2005-01-04 23:27:12 +00:00
[case(ECHO_ENUM1)] echo_Enum1 e1;
[case(ECHO_ENUM2)] echo_Enum2 e2;
} echo_Enum3;
void echo_TestEnum(
[in,out,ref] echo_Enum1 *foo1,
[in,out,ref] echo_Enum2 *foo2,
[in,out,ref,switch_is(*foo1)] echo_Enum3 *foo3
);
2005-02-18 23:06:13 +00:00
typedef struct {
uint32 x;
[size_is(x)] uint16 surrounding[*];
} echo_Surrounding;
void echo_TestSurrounding(
[in,out,ref] echo_Surrounding *data
);
2005-02-20 02:57:38 +00:00
2005-06-01 00:00:50 +00:00
uint16 echo_TestDoublePointer([in] uint16 ***data);
2003-11-09 08:31:36 +00:00
}