ReactOS 0.4.15-dev-7994-gb388cb6
string.c
Go to the documentation of this file.
1/*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS NDIS library
4 * FILE: ndis/string.c
5 * PURPOSE: String management routines
6 * PROGRAMMERS: Casper S. Hornstrup (chorns@users.sourceforge.net)
7 * Vizzini (vizzini@plasmic.com)
8 * REVISIONS:
9 * CSH 01/08-2000 Created
10 * Vizzini 08-Oct-2003 Error checking, documentation, and formatting
11 */
12
13#include "ndissys.h"
14
15/*
16 * @implemented
17 */
18#undef NdisAnsiStringToUnicodeString
24/*
25 * FUNCTION: Converts an ANSI string to an NDIS (unicode) string
26 * ARGUMENTS:
27 * DestinationString = Address of buffer to place converted string in
28 * SourceString = Pointer to ANSI string to be converted
29 * NOTES:
30 * - caller must be running at IRQL = PASSIVE_LEVEL
31 */
32{
33 PAGED_CODE();
36
40}
41
42
43/*
44 * @implemented
45 */
46#undef NdisEqualString
50 IN PNDIS_STRING String1,
53/*
54 * FUNCTION: Tests two strings for equality
55 * ARGUMENTS:
56 * String1 = Pointer to first string
57 * String2 = Pointer to second string
58 * CaseInsensitive = TRUE if the compare should be case insensitive
59 * NOTES:
60 * - caller must be at IRQL = PASSIVE_LEVEL
61 */
62{
63 PAGED_CODE();
64 ASSERT(String1);
66
70}
71
72/*
73 * @implemented
74 */
75#undef NdisInitAnsiString
76VOID
81/*
82 * FUNCTION: Initializes an ANSI string
83 * ARGUMENTS:
84 * DestinationString = Address of buffer to place string in
85 * SourceString = Pointer to null terminated ANSI string
86 * NOTES:
87 * - Caller must be at IRQL <= DISPATCH_LEVEL
88 */
89{
92
94}
95
96/*
97 * @implemented
98 */
99VOID
100EXPORT
104/*
105 * FUNCTION: Initializes an NDIS (unicode) string
106 * ARGUMENTS:
107 * DestinationString = Address of buffer to place string in
108 * SourceString = Pointer to null terminated ANSI string
109 * NOTES:
110 * - Must be called at IRQL = PASSIVE_LEVEL
111 */
112{
114
115 PAGED_CODE();
118
120
122}
123
124/*
125 * @implemented
126 */
127#undef NdisInitUnicodeString
128VOID
129EXPORT
133/*
134 * FUNCTION: Initializes an unicode string
135 * ARGUMENTS:
136 * DestinationString = Address of buffer to place string in
137 * SourceString = Pointer to null terminated unicode string
138 * NOTES:
139 * - call with IRQL <= DISPATCH_LEVEL
140 */
141{
144
146}
147
148/*
149 * @implemented
150 */
151#undef NdisUnicodeStringToAnsiString
153EXPORT
157/*
158 * FUNCTION: Converts an NDIS (unicode) string to an ANSI string
159 * ARGUMENTS:
160 * DestinationString = Address of buffer to place converted string in
161 * SourceString = Pointer to unicode string to be converted
162 * NOTES:
163 * - must be called at IRQL = PASSIVE_LEVEL
164 */
165{
166 PAGED_CODE();
169
173 FALSE);
174}
175
176/*
177 * @implemented
178 */
179#undef NdisUpcaseUnicodeString
181EXPORT
185/*
186 * FUNCTION: Uppercase a UNICODE string
187 * ARGUMENTS:
188 * DestinationString: caller-allocated space for the uppercased string
189 * SourceString: string to be uppercased
190 * NOTES:
191 * - Currently requires caller to allocate destination string - XXX is this right?
192 * - callers must be running at IRQL = PASSIVE_LEVEL
193 */
194{
195 PAGED_CODE();
198
200}
201
202/* EOF */
#define PAGED_CODE()
unsigned char BOOLEAN
LONG NTSTATUS
Definition: precomp.h:26
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
@ AnsiString
Definition: dnslib.h:19
VOID EXPORT NdisInitUnicodeString(IN OUT PNDIS_STRING DestinationString, IN PCWSTR SourceString)
Definition: string.c:130
VOID EXPORT NdisInitializeString(IN OUT PNDIS_STRING DestinationString, IN PUCHAR SourceString)
Definition: string.c:101
NTSTATUS RtlUpcaseUnicodeString(PUNICODE_STRING dst, PUNICODE_STRING src, BOOLEAN Alloc)
Definition: string_lib.cpp:46
#define ASSERT(a)
Definition: mode.c:44
#define NdisAnsiStringToUnicodeString(_us, _as)
Definition: ndis.h:4036
#define NdisUnicodeStringToAnsiString(_as, _us)
Definition: ndis.h:4074
#define NdisEqualString
Definition: ndis.h:4045
#define NdisInitAnsiString
Definition: ndis.h:4057
#define NdisUpcaseUnicodeString(_d, _s)
Definition: ndis.h:5934
_In_ const STRING * String2
Definition: rtlfuncs.h:2357
_Out_ _Inout_ POEM_STRING _In_ PCUNICODE_STRING SourceString
Definition: rtlfuncs.h:1910
_In_ const STRING _In_ BOOLEAN CaseInsensitive
Definition: rtlfuncs.h:2359
_Out_ _Inout_ POEM_STRING DestinationString
Definition: rtlfuncs.h:1909
NTSYSAPI NTSTATUS NTAPI RtlUnicodeStringToAnsiString(PANSI_STRING DestinationString, PUNICODE_STRING SourceString, BOOLEAN AllocateDestinationString)
NTSYSAPI VOID NTAPI RtlInitString(PSTRING DestinationString, PCSZ SourceString)
NTSYSAPI NTSTATUS NTAPI RtlAnsiStringToUnicodeString(PUNICODE_STRING DestinationString, PANSI_STRING SourceString, BOOLEAN AllocateDestinationString)
NTSYSAPI VOID NTAPI RtlInitUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
NTSYSAPI BOOLEAN NTAPI RtlEqualUnicodeString(PUNICODE_STRING String1, PUNICODE_STRING String2, BOOLEAN CaseInSensitive)
NTSYSAPI VOID NTAPI RtlInitAnsiString(PANSI_STRING DestinationString, PCSZ SourceString)
int NDIS_STATUS
Definition: ntddndis.h:475
const uint16_t * PCWSTR
Definition: typedefs.h:57
const char * PCSTR
Definition: typedefs.h:52
#define IN
Definition: typedefs.h:39
unsigned char * PUCHAR
Definition: typedefs.h:53
#define OUT
Definition: typedefs.h:40
CONST char * PCSZ
Definition: umtypes.h:125