Struct InternedString | Package Manager UI website
docs.unity.cn
    Show / Hide Table of Contents

    Struct InternedString

    Wraps around a string to allow for faster case-insensitive string comparisons while preserving original casing.

    Namespace: UnityEngine.InputSystem.Utilities
    Syntax
    public struct InternedString : IEquatable<InternedString>, IComparable<InternedString>

    Constructors

    InternedString(String)

    Declaration
    public InternedString(string text)
    Parameters
    Type Name Description
    System.String text

    Properties

    length

    Declaration
    public int length { get; }
    Property Value
    Type Description
    System.Int32

    Methods

    CompareTo(InternedString)

    Declaration
    public int CompareTo(InternedString other)
    Parameters
    Type Name Description
    InternedString other
    Returns
    Type Description
    System.Int32

    Equals(Object)

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    System.Object obj
    Returns
    Type Description
    System.Boolean
    Overrides
    System.ValueType.Equals(System.Object)

    Equals(InternedString)

    Declaration
    public bool Equals(InternedString other)
    Parameters
    Type Name Description
    InternedString other
    Returns
    Type Description
    System.Boolean

    GetHashCode()

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    System.Int32
    Overrides
    System.ValueType.GetHashCode()

    IsEmpty()

    Declaration
    public bool IsEmpty()
    Returns
    Type Description
    System.Boolean

    ToLower()

    Declaration
    public string ToLower()
    Returns
    Type Description
    System.String

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    System.String
    Overrides
    System.ValueType.ToString()

    Operators

    Equality(String, InternedString)

    Declaration
    public static bool operator ==(string a, InternedString b)
    Parameters
    Type Name Description
    System.String a
    InternedString b
    Returns
    Type Description
    System.Boolean

    Equality(InternedString, String)

    Declaration
    public static bool operator ==(InternedString a, string b)
    Parameters
    Type Name Description
    InternedString a
    System.String b
    Returns
    Type Description
    System.Boolean

    Equality(InternedString, InternedString)

    Declaration
    public static bool operator ==(InternedString a, InternedString b)
    Parameters
    Type Name Description
    InternedString a
    InternedString b
    Returns
    Type Description
    System.Boolean

    GreaterThan(InternedString, InternedString)

    Declaration
    public static bool operator>(InternedString left, InternedString right)
    Parameters
    Type Name Description
    InternedString left
    InternedString right
    Returns
    Type Description
    System.Boolean

    Implicit(InternedString to String)

    Declaration
    public static implicit operator string (InternedString str)
    Parameters
    Type Name Description
    InternedString str
    Returns
    Type Description
    System.String

    Inequality(String, InternedString)

    Declaration
    public static bool operator !=(string a, InternedString b)
    Parameters
    Type Name Description
    System.String a
    InternedString b
    Returns
    Type Description
    System.Boolean

    Inequality(InternedString, String)

    Declaration
    public static bool operator !=(InternedString a, string b)
    Parameters
    Type Name Description
    InternedString a
    System.String b
    Returns
    Type Description
    System.Boolean

    Inequality(InternedString, InternedString)

    Declaration
    public static bool operator !=(InternedString a, InternedString b)
    Parameters
    Type Name Description
    InternedString a
    InternedString b
    Returns
    Type Description
    System.Boolean

    LessThan(InternedString, InternedString)

    Declaration
    public static bool operator <(InternedString left, InternedString right)
    Parameters
    Type Name Description
    InternedString left
    InternedString right
    Returns
    Type Description
    System.Boolean
    Back to top Copyright © 2019 Unity Technologies
    Generated by DocFX