| 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 | |
| 6 | // |
| 7 | // This header provides general standard string services. |
| 8 | // |
| 9 | |
| 10 | #ifndef _clr_str_h_ |
| 11 | #define _clr_str_h_ |
| 12 | |
| 13 | namespace clr |
| 14 | { |
| 15 | namespace str |
| 16 | { |
| 17 | //----------------------------------------------------------------------------------------- |
| 18 | // Returns true if the provided string is a null pointer or the empty string. |
| 19 | static inline bool |
| 20 | IsNullOrEmpty(LPCWSTR wzStr) |
| 21 | { |
| 22 | return wzStr == nullptr || *wzStr == W('\0'); |
| 23 | } |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | #endif // _clr_str_h_ |
| 28 | |
| 29 | |