Share via


String.Intern Method

Retrieves the system's reference to a specified String object.

Namespace: System
Assembly: mscorlib (in mscorlib.dll)

Syntax

public static string Intern (
         string str
)

Parameters

  • str
    A value that represents a specific String object.

Return Value

The system's reference, if the value of the str parameter is already interned; otherwise, a new reference to a string with the value of str.

Version Information

Available in the .NET Micro Framework versions 2.0, 2.5, 3.0, 4.0, 4.1, and 4.2.

See Also

Reference

String Class
String Members
System Namespace