C# Класс SourceGrid.Range

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
Empty Range

Открытые методы

Метод Описание
Contains ( Position p_Position ) : bool

Returns true if the specified cell position is present in the current range.

Contains ( Range p_Range ) : bool

Returns true if the specified range is present in the current range.

ContainsColumn ( int p_Col ) : bool

Returns true if the specified column is present in the current range.

ContainsRow ( int p_Row ) : bool

Returns true if the specified row is present in the current range.

Equals ( Range p_Range ) : bool

Equals ( object obj ) : bool

Exclude ( Range range ) : RangeRegion

Return all the cells that don't intersect with the specified cells. (Remove the specified cells from the current cells ad returns the remaining cells)

GetBounds ( Range p_Range1, Range p_Range2 ) : Range

Returns a range with the smaller Start and the bigger End. The Union of the 2 Range. If one of the range is empty then the return is the other range.

GetCellsPositions ( ) : PositionCollection

GetHashCode ( ) : int

Intersect ( Range p_Range ) : Range

Returns the intersection between the 2 Range. If one of the range is empty then the return is empty.

Intersect ( Range p_Range1, Range p_Range2 ) : Range

Returns the intersection between the 2 Range. If one of the range is empty then the return is empty.

IntersectsWith ( Range p_Range ) : bool

Returns true if the specified range intersects (one or more cells) with the current range. If one of the range is empty then the return is false.

IntersectsWith ( Range p_Range1, Range p_Range2 ) : bool

Returns true if the specified range intersects (one or more cells) with the current range. If one of the range is empty then the return is false.

IsEmpty ( ) : bool

Determines if the current range is empty

MoveTo ( Position p_StartPosition ) : void

Move the current range to the specified position, leaving the current ColumnsCount and RowsCount

Range ( Position p_SinglePosition ) : System

Construct a Range of a single cell

Range ( Position p_Start, Position p_End ) : System

Constructor

Range ( int p_StartRow, int p_StartCol, int p_EndRow, int p_EndCol ) : System

Constructor

ToString ( ) : string

Union ( Range p_Range1, Range p_Range2 ) : RangeRegion

Returns a range with the smaller Start and the bigger End. The Union of the 2 Range. If one of the range is empty then the return is the other range.

operator ( ) : bool

Приватные методы

Метод Описание
Normalize ( ) : void

Check and fix the range to always have Start smaller than End

Range ( ) : System
Range ( Position p_Start, Position p_End, bool p_bCheck ) : System

Описание методов

Contains() публичный Метод

Returns true if the specified cell position is present in the current range.
public Contains ( Position p_Position ) : bool
p_Position Position
Результат bool

Contains() публичный Метод

Returns true if the specified range is present in the current range.
public Contains ( Range p_Range ) : bool
p_Range Range
Результат bool

ContainsColumn() публичный Метод

Returns true if the specified column is present in the current range.
public ContainsColumn ( int p_Col ) : bool
p_Col int
Результат bool

ContainsRow() публичный Метод

Returns true if the specified row is present in the current range.
public ContainsRow ( int p_Row ) : bool
p_Row int
Результат bool

Equals() публичный Метод

public Equals ( Range p_Range ) : bool
p_Range Range
Результат bool

Equals() публичный Метод

public Equals ( object obj ) : bool
obj object
Результат bool

Exclude() публичный Метод

Return all the cells that don't intersect with the specified cells. (Remove the specified cells from the current cells ad returns the remaining cells)
public Exclude ( Range range ) : RangeRegion
range Range
Результат RangeRegion

GetBounds() публичный статический Метод

Returns a range with the smaller Start and the bigger End. The Union of the 2 Range. If one of the range is empty then the return is the other range.
public static GetBounds ( Range p_Range1, Range p_Range2 ) : Range
p_Range1 Range
p_Range2 Range
Результат Range

GetCellsPositions() публичный Метод

public GetCellsPositions ( ) : PositionCollection
Результат PositionCollection

GetHashCode() публичный Метод

public GetHashCode ( ) : int
Результат int

Intersect() публичный Метод

Returns the intersection between the 2 Range. If one of the range is empty then the return is empty.
public Intersect ( Range p_Range ) : Range
p_Range Range
Результат Range

Intersect() публичный статический Метод

Returns the intersection between the 2 Range. If one of the range is empty then the return is empty.
public static Intersect ( Range p_Range1, Range p_Range2 ) : Range
p_Range1 Range
p_Range2 Range
Результат Range

IntersectsWith() публичный Метод

Returns true if the specified range intersects (one or more cells) with the current range. If one of the range is empty then the return is false.
public IntersectsWith ( Range p_Range ) : bool
p_Range Range
Результат bool

IntersectsWith() публичный статический Метод

Returns true if the specified range intersects (one or more cells) with the current range. If one of the range is empty then the return is false.
public static IntersectsWith ( Range p_Range1, Range p_Range2 ) : bool
p_Range1 Range
p_Range2 Range
Результат bool

IsEmpty() публичный Метод

Determines if the current range is empty
public IsEmpty ( ) : bool
Результат bool

MoveTo() публичный Метод

Move the current range to the specified position, leaving the current ColumnsCount and RowsCount
public MoveTo ( Position p_StartPosition ) : void
p_StartPosition Position
Результат void

Range() публичный Метод

Construct a Range of a single cell
public Range ( Position p_SinglePosition ) : System
p_SinglePosition Position
Результат System

Range() публичный Метод

Constructor
public Range ( Position p_Start, Position p_End ) : System
p_Start Position
p_End Position
Результат System

Range() публичный Метод

Constructor
public Range ( int p_StartRow, int p_StartCol, int p_EndRow, int p_EndCol ) : System
p_StartRow int
p_StartCol int
p_EndRow int
p_EndCol int
Результат System

ToString() публичный Метод

public ToString ( ) : string
Результат string

Union() публичный статический Метод

Returns a range with the smaller Start and the bigger End. The Union of the 2 Range. If one of the range is empty then the return is the other range.
public static Union ( Range p_Range1, Range p_Range2 ) : RangeRegion
p_Range1 Range
p_Range2 Range
Результат RangeRegion

operator() публичный статический Метод

public static operator ( ) : bool
Результат bool

Описание свойств

Empty публичное статическое свойство

Represents an empty range
public static Range,SourceGrid Empty
Результат Range