Redigera

Dela via


CodeGenerator.IsValidLanguageIndependentIdentifier(String) Method

Definition

Gets a value indicating whether the specified string is a valid identifier.

public:
 static bool IsValidLanguageIndependentIdentifier(System::String ^ value);
public static bool IsValidLanguageIndependentIdentifier (string value);
static member IsValidLanguageIndependentIdentifier : string -> bool
Public Shared Function IsValidLanguageIndependentIdentifier (value As String) As Boolean

Parameters

value
String

The string to test for validity.

Returns

true if the specified string is a valid identifier; otherwise, false.

Remarks

This method checks the specified string to ensure that it does not contain certain characters that can be used to escape an identifier field. The ValidateIdentifiers method calls this method to perform string validation. Calling the ValidateIdentifiers method and passing a CodeCompileUnit before generating code from it can prevent the use of certain character sequences to include hidden code within an identifier field.

Applies to

See also