Class UdiRange
Represents a Udi range.
Inheritance
object
Namespace: Umbraco.Cms.Core
Assembly: Umbraco.Core.dll
Syntax
public class UdiRange
Remarks
Constructors
View SourceUdiRange(Udi, string)
Declaration
public UdiRange(Udi udi, string selector = "this")
Parameters
| Type | Name | Description |
|---|---|---|
| Udi | udi | A Udi. |
| string | selector | An optional selector. |
Properties
View SourceEntityType
Gets the entity type of the Udi for this range.
Declaration
public string EntityType { get; }
Property Value
| Type | Description |
|---|---|
| string |
Selector
Gets or sets the selector for this range.
Declaration
public string Selector { get; }
Property Value
| Type | Description |
|---|---|
| string |
Udi
Gets the Udi for this range.
Declaration
public Udi Udi { get; }
Property Value
| Type | Description |
|---|---|
| Udi |
Methods
View SourceEquals(object?)
Declaration
public override bool Equals(object? obj)
Parameters
| Type | Name | Description |
|---|---|---|
| object | obj |
Returns
| Type | Description |
|---|---|
| bool |
GetHashCode()
Declaration
public override int GetHashCode()
Returns
| Type | Description |
|---|---|
| int |
Parse(string)
Parses a string representation of a UDI range.
Declaration
public static UdiRange Parse(string value)
Parameters
| Type | Name | Description |
|---|---|---|
| string | value | The string to parse. |
Returns
| Type | Description |
|---|---|
| UdiRange | A UdiRange instance. |
Exceptions
| Type | Condition |
|---|---|
| FormatException | Thrown when the string is not a valid UDI range. |
ToString()
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string |
Operators
View Sourceoperator ==(UdiRange?, UdiRange?)
Determines whether two UdiRange instances are equal.
Declaration
public static bool operator ==(UdiRange? range1, UdiRange? range2)
Parameters
| Type | Name | Description |
|---|---|---|
| UdiRange | range1 | The first range to compare. |
| UdiRange | range2 | The second range to compare. |
Returns
| Type | Description |
|---|---|
| bool |
|
operator !=(UdiRange, UdiRange)
Determines whether two UdiRange instances are not equal.
Declaration
public static bool operator !=(UdiRange range1, UdiRange range2)
Parameters
| Type | Name | Description |
|---|---|---|
| UdiRange | range1 | The first range to compare. |
| UdiRange | range2 | The second range to compare. |
Returns
| Type | Description |
|---|---|
| bool |
|