Show / Hide Table of Contents

    Class Token

    Represents the old and new values to be used for string replacements.

    Inheritance
    System.Object
    Token
    Implements
    System.IEquatable<Token>
    Inherited Members
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Nevatech.Vsb.Repository
    Assembly: Nevatech.Vsb.Repository.dll
    Syntax
    public sealed class Token : IEquatable<Token>

    Constructors

    Token(String, String)

    Initializes a new instance with provided old and new values.

    Declaration
    public Token(string oldValue, string newValue)
    Parameters
    Type Name Description
    System.String oldValue

    A string to be replaced.

    System.String newValue

    A string to replace all occurrences of old value.

    Token(String, String, StringComparison)

    Initializes a new instance with provided old and new values and string comparison.

    Declaration
    public Token(string oldValue, string newValue, StringComparison comparison)
    Parameters
    Type Name Description
    System.String oldValue

    A string to be replaced.

    System.String newValue

    A string to replace all occurrences of old value.

    System.StringComparison comparison

    String comparison rules to be used for finding old values.

    Properties

    Comparison

    Gets string comparison rules to be used for finding old values.

    Declaration
    public StringComparison Comparison { get; }
    Property Value
    Type Description
    System.StringComparison

    Index

    Gets or sets the last position of the token in the source string. This property is used internally and is not supposed to be set by the caller.

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

    NewValue

    Gets a string to replace all occurrences of old value.

    Declaration
    public string NewValue { get; }
    Property Value
    Type Description
    System.String

    OldValue

    Gets a string to be replaced.

    Declaration
    public string OldValue { get; }
    Property Value
    Type Description
    System.String

    Methods

    Equals(Token)

    Indicates whether the current object is equal to another object of the same type.

    Declaration
    public bool Equals(Token other)
    Parameters
    Type Name Description
    Token other

    An object to compare with this object.

    Returns
    Type Description
    System.Boolean

    true if the current object is equal to the other parameter; otherwise, false.

    Equals(Object)

    Determines whether the specified object is equal to the current object.

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

    The object to compare with the current object.

    Returns
    Type Description
    System.Boolean

    true if the specified object is equal to the current object; otherwise, false.

    Overrides
    System.Object.Equals(System.Object)

    GetHashCode()

    Serves as a hash function for a particular type.

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

    A hash code for the current object.

    Overrides
    System.Object.GetHashCode()

    ToString()

    Returns a string that represents the current object.

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

    A string that represents the current object.

    Overrides
    System.Object.ToString()

    Implements

    System.IEquatable<T>
    Back to top Nevatech Sentinet 6.6 Online Documentation