API / geotoolkit / contour / grid / GridRange / GridRange
Stores the x,y grid extents for a contour grid object.
Constructors
| [new GridRange()](/solutions/geotoolkit/apis/classes/geotoolkit.contour.grid.gridrange.gridrange.md#new gridrange()) | [new GridRange(left, bottom, right, top)](/solutions/geotoolkit/apis/classes/geotoolkit.contour.grid.gridrange.gridrange.md#new gridrange(left, bottom, right, top)) | [new GridRange(range)](/solutions/geotoolkit/apis/classes/geotoolkit.contour.grid.gridrange.gridrange.md#new gridrange(range)) |
|---|
Methods
Constructors
• new GridRange()
• new GridRange(left?, bottom?, right?, top?)
| Name | Type | Description |
|---|---|---|
Optional left | number | start index for coordinates arrays. |
Optional bottom | number | start index for coordinates arrays. |
Optional right | number | start index for coordinates arrays. |
Optional top | number | start index for coordinates arrays. |
• new GridRange(range)
| Name | Type |
|---|---|
range | GridRange |
Methods
▸ contains(x, y): boolean
Checks if the supplied point or range is contained within this one.
| Name | Type | Description |
|---|---|---|
x | number | X-coordinate |
y | number | Y-coordinate |
boolean
▸ contains(range): boolean
| Name | Type |
|---|---|
range | GridRange |
boolean
▸ getBottom(): number
The bottom extent of this grid range
number
bottom
▸ getClassName(): string
string
▸ getHeight(): number
The height of this grid range
number
height
▸ getLeft(): number
The left extent of this grid range
number
left
▸ getRect(): Rect
Grid Range as a Rect object
rect The range as a Rect.
▸ getRight(): number
The right extent of this grid range
number
right
▸ getTop(): number
The top extent of this grid range
number
top
▸ getWidth(): number
The width of this grid range
number
width
▸ intersection(range): GridRange
Computes the intersection between this grid range and the specified grid range.
| Name | Type | Description |
|---|---|---|
range | GridRange | The grid range |
intersection The intersected grid range.
▸ intersects(range): boolean
Determines whether this grid range intersects with the supplied grid range.
| Name | Type | Description |
|---|---|---|
range | GridRange | The grid range to check against |
boolean
intesects True if the two grid ranges intersect
▸ isEmpty(): boolean
Determines if this range is empty
boolean
empty True if the grid range is empty
▸ reset(): void
Resets this grid range to be empty: Sets the size to zero, and the position to (0,0)
void
▸ setGridRange(left, bottom, right, top): GridRange
Sets the range for this grid
| Name | Type | Description |
|---|---|---|
left | number | GridRange |
bottom | number | Bottom range extent |
right | number | Right range extent |
top | number | Top range extent |
this
▸ setGridRange(range): GridRange
Sets the range for this grid
| Name | Type | Description |
|---|---|---|
range | GridRange | GridRange |
this
▸ Static getClassName(): string
string