Represents a rectangle on the map. More...
Public Member Functions | |
void | GetBounds (out double xMin, out double yMin, out double zMin, out double xMax, out double yMax, out double zMax) |
Gets the bounds of the extents object. More... | |
void | GetMeasureBounds (out double mMin, out double mMax) |
Gets the minimum and maximum measure bounds for the extents object. More... | |
void | MoveTo (double x, double y) |
Moves extents so that center point will be at specified coordinates, while width and height will be preserved. More... | |
bool | PointIsWithin (double x, double y) |
Checks whether a point is within extents More... | |
void | SetBounds (double xMin, double yMin, double zMin, double xMax, double yMax, double zMax) |
Sets the bounds for the extents object. More... | |
void | SetMeasureBounds (double mMin, double mMax) |
Sets the measure bounds of the extents object. More... | |
string | ToDebugString () |
Gets serialized contents of the extents for debug purposes. More... | |
Shape | ToShape () |
Creates a rectangular polygon matching current extents. More... | |
Properties | |
Point | Center [get] |
Gets a center point for the extents. More... | |
double | Depth [get] |
Gets the Depth of the extents object (zMax - zMin). More... | |
double | Height [get] |
Gets the Height of the extents object (yMax - yMin). More... | |
double | mMax [get] |
The maximum measure bound in the exents object. Measure bounds only apply to shapefiles containing measure data. More... | |
double | mMin [get] |
Gets the minimum measure bound for the extents object. Measure bounds only apply to shapefiles containing measure data. More... | |
double | Width [get] |
Gets the Width of the extents object (xMax - xMin). More... | |
double | xMax [get] |
The maximum x bound for the extents object. More... | |
double | xMin [get] |
Gets the minimum x bound for the extents object. More... | |
double | yMax [get] |
The maximum y bound for the extents object. More... | |
double | yMin [get] |
Gets the minimum y bound for the extents object More... | |
double | zMax [get] |
The maximum z bound for the extents object. More... | |
double | zMin [get] |
Gets the minimum z bound for the extents object. More... | |
Represents a rectangle on the map.
In some cases additional Z and M dimensions can also be specified to denote the altitude of the displayed data for example.
Let's see how to display certain extents on the map.
MapWinGIS doesn't hold instances of Extents class for layers or map, but generates them on each client call. Therefore it's useless to try to change those extents in the way like this:
The following line is needed:
In case of data layers, like shapefiles or images, the extents are obtained by calculation, so the only way to alter them is to change the underlying data.
void Extents.GetBounds | ( | out double | xMin, |
out double | yMin, | ||
out double | zMin, | ||
out double | xMax, | ||
out double | yMax, | ||
out double | zMax | ||
) |
Gets the bounds of the extents object.
xMin | Returns the minimum x value for the extents object. |
yMin | Returns the minimum y value for the extents object. |
zMin | Returns the minimum z value for the extents object. |
xMax | Returns the maximum x value for the extents object. |
yMax | Returns the maximum y value for the extents object. |
zMax | Returns the maximum z value for the extents object. |
void Extents.GetMeasureBounds | ( | out double | mMin, |
out double | mMax | ||
) |
Gets the minimum and maximum measure bounds for the extents object.
Measure bounds only apply to shapefiles containing measure data.
mMin | |
mMax |
void Extents.MoveTo | ( | double | x, |
double | y | ||
) |
Moves extents so that center point will be at specified coordinates, while width and height will be preserved.
x | X coordinate of new center. |
y | Y coordinate of new center. |
bool Extents.PointIsWithin | ( | double | x, |
double | y | ||
) |
Checks whether a point is within extents
x | X coordinate of point |
y | Y coordinate of point |
void Extents.SetBounds | ( | double | xMin, |
double | yMin, | ||
double | zMin, | ||
double | xMax, | ||
double | yMax, | ||
double | zMax | ||
) |
Sets the bounds for the extents object.
xMin | The new minimum x value for the bounds of the extents object. |
yMin | The new minimum y value for the bounds of the extents object. |
zMin | The new minimum z value for the bounds of the extents object. |
xMax | The new maximum x value for the bounds of the extents object. |
yMax | The new maximum y value for the bounds of the extents object. |
zMax | The new maximum z value for the bounds of the extents object. |
void Extents.SetMeasureBounds | ( | double | mMin, |
double | mMax | ||
) |
Sets the measure bounds of the extents object.
Measure bounds only apply to shapefiles containing measure data.
mMin | The new minimum measure bound for the extents object. |
mMax | The new maximum measure bound for the extents object. |
string Extents.ToDebugString | ( | ) |
Gets serialized contents of the extents for debug purposes.
Shape Extents.ToShape | ( | ) |
Creates a rectangular polygon matching current extents.
|
get |
Gets a center point for the extents.
|
get |
Gets the Depth of the extents object (zMax - zMin).
|
get |
Gets the Height of the extents object (yMax - yMin).
|
get |
The maximum measure bound in the exents object. Measure bounds only apply to shapefiles containing measure data.
|
get |
Gets the minimum measure bound for the extents object. Measure bounds only apply to shapefiles containing measure data.
|
get |
Gets the Width of the extents object (xMax - xMin).
|
get |
The maximum x bound for the extents object.
|
get |
Gets the minimum x bound for the extents object.
|
get |
The maximum y bound for the extents object.
|
get |
Gets the minimum y bound for the extents object
|
get |
The maximum z bound for the extents object.
|
get |
Gets the minimum z bound for the extents object.