com.google.maps.gwt.client
Class LatLngBounds

java.lang.Object
  extended by JavaScriptObject
      extended by com.google.maps.gwt.client.LatLngBounds

public class LatLngBounds
extends JavaScriptObject

A LatLngBounds instance represents a rectangle in geographical coordinates, including one that crosses the 180 degrees longitudinal meridian. THIS SOURCE CODE IS GENERATED, DO NOT MODIFY


Constructor Summary
protected LatLngBounds()
          Protected constructor avoids default public constructor.
 
Method Summary
 boolean contains(LatLng latLng)
          Returns true if the given lat/lng is in this bounds.
static LatLngBounds create()
          Constructs a rectangle from the points at its south-west and north-east corners.
static LatLngBounds create(LatLng sw)
          Constructs a rectangle from the points at its south-west and north-east corners.
static LatLngBounds create(LatLng sw, LatLng ne)
          Constructs a rectangle from the points at its south-west and north-east corners.
 boolean equals(LatLngBounds other)
          Returns true if this bounds approximately equals the given bounds.
 LatLngBounds extend(LatLng point)
          Extends this bounds to contain the given point.
 LatLng getCenter()
          Computes the center of this LatLngBounds
 LatLng getNorthEast()
          Returns the north-east corner of this bounds.
 LatLng getSouthWest()
          Returns the south-west corner of this bounds.
 boolean intersects(LatLngBounds other)
          Returns true if this bounds shares any points with this bounds.
 boolean isEmpty()
          Returns if the bounds are empty.
 LatLng toSpan()
          Converts the given map bounds to a lat/lng span.
 java.lang.String toUrlValue()
          Returns a string of the form "lat_lo,lng_lo,lat_hi,lng_hi" for this bounds, where "lo" corresponds to the southwest corner of the bounding box, while "hi" corresponds to the northeast corner of that box.
 java.lang.String toUrlValue(double precision)
          Returns a string of the form "lat_lo,lng_lo,lat_hi,lng_hi" for this bounds, where "lo" corresponds to the southwest corner of the bounding box, while "hi" corresponds to the northeast corner of that box.
 LatLngBounds union(LatLngBounds other)
          Extends this bounds to contain the union of this and the given bounds.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LatLngBounds

protected LatLngBounds()
Protected constructor avoids default public constructor.

Method Detail

create

public static LatLngBounds create(LatLng sw,
                                  LatLng ne)
Constructs a rectangle from the points at its south-west and north-east corners.


create

public static LatLngBounds create(LatLng sw)
Constructs a rectangle from the points at its south-west and north-east corners.


create

public static LatLngBounds create()
Constructs a rectangle from the points at its south-west and north-east corners.


contains

public final boolean contains(LatLng latLng)
Returns true if the given lat/lng is in this bounds.


equals

public final boolean equals(LatLngBounds other)
Returns true if this bounds approximately equals the given bounds.


extend

public final LatLngBounds extend(LatLng point)
Extends this bounds to contain the given point.


getCenter

public final LatLng getCenter()
Computes the center of this LatLngBounds


getNorthEast

public final LatLng getNorthEast()
Returns the north-east corner of this bounds.


getSouthWest

public final LatLng getSouthWest()
Returns the south-west corner of this bounds.


intersects

public final boolean intersects(LatLngBounds other)
Returns true if this bounds shares any points with this bounds.


isEmpty

public final boolean isEmpty()
Returns if the bounds are empty.


toSpan

public final LatLng toSpan()
Converts the given map bounds to a lat/lng span.


toUrlValue

public final java.lang.String toUrlValue(double precision)
Returns a string of the form "lat_lo,lng_lo,lat_hi,lng_hi" for this bounds, where "lo" corresponds to the southwest corner of the bounding box, while "hi" corresponds to the northeast corner of that box.


toUrlValue

public final java.lang.String toUrlValue()
Returns a string of the form "lat_lo,lng_lo,lat_hi,lng_hi" for this bounds, where "lo" corresponds to the southwest corner of the bounding box, while "hi" corresponds to the northeast corner of that box.


union

public final LatLngBounds union(LatLngBounds other)
Extends this bounds to contain the union of this and the given bounds.