In This Article

TagSnapshotRange<T> Class

Implements an object that represents an ITag and its associated TextSnapshotRange.

public class TagSnapshotRange<T>
    where T : ITag
Type Parameters:
T -

The type of tag associated with this range.

Inheritance:
Object Object

Constructors

TagSnapshotRange(TextSnapshotRange, T)

Initializes a new instance of the TagSnapshotRange class.

public TagSnapshotRange(TextSnapshotRange snapshotRange, T tag)
Parameter Type Description
snapshotRange TextSnapshotRange

The TextSnapshotRange over which the Tag applies.

tag T

The ITag data object associated with this range.

Properties

SnapshotRange

Gets the TextSnapshotRange over which the Tag applies.

public TextSnapshotRange SnapshotRange { get; }

Property Value

TextSnapshotRange:

The TextSnapshotRange over which the Tag applies.

Tag

Gets the ITag data object associated with this range.

public T Tag { get; }

Property Value

T:

The ITag data object associated with this range.

Methods

Equals(Object)

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

public override bool Equals(object obj)
Parameter Type Description
obj Object

The Object to compare with the current Object.

Returns

Boolean:

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

Exceptions

Type Condition
NullReferenceException

The obj parameter is null.

GetHashCode()

Serves as a hash function for a particular type.

public override int GetHashCode()

Returns

Int32:

A hash code for the current Object.

ToString()

Converts the object to a String.

public override string ToString()

Returns

String:

A string whose value represents this object.

Inherited Members