1 | // Licensed to the .NET Foundation under one or more agreements. |
---|---|
2 | // The .NET Foundation licenses this file to you under the MIT license. |
3 | // See the LICENSE file in the project root for more information. |
4 | |
5 | #include <stdlib.h> |
6 | #include <stdio.h> |
7 | #include <string.h> |
8 | #include <xplatform.h> |
9 | |
10 | |
11 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_In(char c) |
12 | { |
13 | printf ("Char_In "); |
14 | printf ("%c",c); |
15 | printf ("\n"); |
16 | |
17 | return TRUE; |
18 | } |
19 | |
20 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_InByRef(char* c) |
21 | { |
22 | printf ("Char_InByRef "); |
23 | printf ("%c",*c); |
24 | printf ("\n"); |
25 | |
26 | return TRUE; |
27 | } |
28 | |
29 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_InOutByRef(char* c) |
30 | { |
31 | printf ("Char_InOutByRef "); |
32 | printf ("%c",*c); |
33 | printf ("\n"); |
34 | |
35 | return TRUE; |
36 | } |
37 | |
38 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_In_String(char* c) |
39 | { |
40 | printf ("native %s \n", c); |
41 | |
42 | return TRUE; |
43 | } |
44 | |
45 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_InByRef_String(char** c) |
46 | { |
47 | printf ("native %s \n", *c); |
48 | |
49 | return TRUE; |
50 | } |
51 | |
52 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_InOutByRef_String(char** c) |
53 | { |
54 | printf ("native %s \n", *c); |
55 | |
56 | return TRUE; |
57 | } |
58 | |
59 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_In_StringBuilder(char* c) |
60 | { |
61 | printf ("native %s \n", c); |
62 | |
63 | return TRUE; |
64 | } |
65 | |
66 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_InByRef_StringBuilder(char** c) |
67 | { |
68 | printf ("native %s \n", *c); |
69 | |
70 | return TRUE; |
71 | } |
72 | |
73 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE CharBuffer_InOutByRef_StringBuilder(char** c) |
74 | { |
75 | printf ("native %s \n", *c); |
76 | |
77 | return TRUE; |
78 | } |
79 | |
80 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_In_ArrayWithOffset (char* pArrayWithOffset) |
81 | { |
82 | return TRUE; |
83 | } |
84 | |
85 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_InOut_ArrayWithOffset (char* pArrayWithOffset) |
86 | { |
87 | return TRUE; |
88 | } |
89 | |
90 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_InByRef_ArrayWithOffset (char** ppArrayWithOffset) |
91 | { |
92 | return TRUE; |
93 | } |
94 | |
95 | extern "C"bool DLL_EXPORT STDMETHODCALLTYPE Char_InOutByRef_ArrayWithOffset (char** ppArrayWithOffset) |
96 | { |
97 | return TRUE; |
98 | } |
99 |