Class Utilities
- Namespace
- Stride
- Assembly
- Stride.Core.Assets.dll
public static class Utilities
- Inheritance
-
Utilities
Methods
BuildValidClassName(string, char)
Build a valid C# class name from the provided string. It replaces all the forbidden characters by the provided replacement character.
public static string BuildValidClassName(string originalName, char replacementCharacter = '_')
Parameters
Returns
BuildValidClassName(string, IEnumerable<string>, char)
Build a valid C# class name from the provided string. It replaces all the forbidden characters by the provided replacement character.
public static string BuildValidClassName(string originalName, IEnumerable<string> additionalReservedWords, char replacementCharacter = '_')
Parameters
originalName
stringThe original name
additionalReservedWords
IEnumerable<string>Reserved words that must be escaped if used directly
replacementCharacter
charThe replacement character
Returns
BuildValidFileName(string, char)
Build a valid file name from the provided string. It replaces all the forbidden characters by the provided replacement character. For reference see: https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx
public static string BuildValidFileName(string originalName, char replacementCharacter = '_')
Parameters
Returns
BuildValidNamespaceName(string, char)
Build a valid C# namespace name from the provided string. It replaces all the forbidden characters by the provided replacement character.
public static string BuildValidNamespaceName(string originalName, char replacementCharacter = '_')
Parameters
Returns
BuildValidNamespaceName(string, IEnumerable<string>, char)
Build a valid C# namespace name from the provided string. It replaces all the forbidden characters by the provided replacement character.
public static string BuildValidNamespaceName(string originalName, IEnumerable<string> additionalReservedWords, char replacementCharacter = '_')
Parameters
originalName
stringThe original name
additionalReservedWords
IEnumerable<string>Reserved words that must be escaped if used directly
replacementCharacter
charThe replacement character
Returns
BuildValidProjectName(string, char)
Build a valid C# project name from the provided string. It replaces all the forbidden characters by the provided replacement character.
public static string BuildValidProjectName(string originalName, char replacementCharacter = '_')