new cercalia.Bounds(arrCoord)
| Name | Type | Description |
|---|---|---|
arrCoord |
Array.<number> |
Coordinates [left, bottom, right, top] |
Methods
-
add(x, y){cercalia.Bounds}
-
Move the limits horizontally and vertically
Name Type Description xnumber Displacement X axis
ynumber Displacement Y axis
-
clear()
-
Cleans the object bounds. It reinitializes.
-
clone(){cercalia.Bounds}
-
Object clonation.
Returns:
Object clone.
-
cloneIncreasingPercentage(p_percentage){cercalia.Bounds}
-
Name Type Description p_percentagenumber to increase for every limit (top, bottom, left, right)
Returns:
Returns the object 'cercalia.Bounds' increased
-
contains(x, y, inclusive){boolean}
-
Returns Devuelve si una coordenada se encuentra dentro de los límites del objeto
Name Type Description xnumber Latitude.
ynumber Longitude.
inclusiveboolean Inclusive, with the bounds.
Returns:
Returns if it's inside the object bounds.
-
containsBounds(bounds, partial, inclusive){boolean}
-
Name Type Description boundscercalia.Bounds Bounds.
partialboolean If one destination corner is inside the bounds consider contains the bounds. The default value is false. If false, all the destination bounds must be inside this bounds.
inclusiveboolean Include edges. Default value: true
Returns:
Returns if contains bounds inside object
-
containsLonLat(lonLat){boolean}
-
Returns true if a coordinate (cercalia.LonLat object) is inside the bounds
Name Type Description lonLatcercalia.LonLat Coordinate.
Returns:
trueorfalse.
-
equals(bounds){boolean}
-
Name Type Description boundscercalia.Bounds Returns:
Returns if bounds have the same limits
-
extend(object)
-
Expand the limits for including coordinates {ol.Coord} or more limits {cercalia.Bounds}.
Name Type Description objectcercalia.LonLat | cercalia.Bounds -
extendXY(x, y)
-
Expand the limits for including the coordinate XY {ol.Coord}
Name Type Description xnumber Longitud
ynumber Latitud
-
getBottom(){number}
-
Returns the lower limit for Y axis.
Returns:
bottom
-
getCenterLonLat(){cercalia.LonLat}
-
Returns the bounds center
Returns:
Map center
-
getClass(){string}
-
Returns the object type.
-
getDouble(){cercalia.Bounds}
-
Returns an object increasing (x0.5) all the limits (top, bottom, left, right)
Returns:
bounds
-
getHeight(){number}
-
Height - limits.
Returns:
Height bounds
-
getHeightInMeters()
-
Returns:
distance Bounds height distance in meters.
-
getLeft(){number}
-
Returns the left limit for X axis.
Returns:
left
-
getNorthEast(){Array.<number>}
-
Returns the NorthEast coordinate
Returns:
array NorthEast coordinate
-
getNorthWest(){cercalia.LonLat}
-
Returns the NorthWest coordinate
Returns:
Northwest coordinate
-
getRight(){number}
-
Returns the right limit for X axis.
Returns:
right
-
getSize(){number}
-
Array with size limits
[width,height]Returns:
Size bounds[width, height]
-
getSouthEast(){cercalia.LonLat}
-
Returns the SouthEast coordinate
Returns:
SouthEast coordinate
-
getSouthWest(){cercalia.LonLat}
-
Returns the Southwest coordinate
Returns:
Southwest coordinate
-
getTop(){number}
-
Returns the top limit for Y axis.
Returns:
top
-
getWidth(){number}
-
Width - limits.
Returns:
Bounds width
-
getWidthInMeters()
-
Returns:
distance Bounds width distance in meters.
-
intersectsBounds(bounds, options){boolean}
-
Determina si unos limites intersecta con los limites del objeto actual. Se considera que intersectan si uno de sus aristas se encuentran dentro de los limites del otro
Name Type Description boundscercalia.Bounds optionsObject -
isEmpty(){boolean}
-
Returns:
Returns if bounds are empty. (Have not been initialized)
-
toArray(){Array}
-
Returns:
Returns an array with the bounds. Format: [left, bottom, right, top]
-
toBBOX(){string}
-
Returns:
Returns BoundingBox-String "0.41,41.24,0.541,40.51"
-
toString(){string}
-
Returns the object in string [left, bottom, right, top]
Returns:
Returns a string with the bounds. Format: "left,bottom,right,top"
-
wrapDateLine(maxExtent, options){cercalia.Bounds}
-
Name Type Description maxExtentcercalia.Bounds optionsObject options.leftTolerance|options.rightTolerance