- 2.65.0 (latest)
- 2.64.1
- 2.63.2
- 2.62.0
- 2.61.3
- 2.60.0
- 2.59.2
- 2.58.0
- 2.57.0
- 2.56.0
- 2.54.1
- 2.53.0
- 2.52.0
- 2.51.0
- 2.50.1
- 2.49.0
- 2.48.0
- 2.46.0
- 2.45.1
- 2.44.0
- 2.43.0
- 2.42.0
- 2.41.0
- 2.40.0
- 2.39.1
- 2.38.0
- 2.37.1
- 2.36.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.30.0
- 2.29.0
- 2.28.0
- 2.27.0
- 2.26.0
- 2.25.1
- 2.24.0
- 2.23.1
- 2.22.1
- 2.21.1
- 2.15.0
- 2.14.3
- 2.13.0
- 2.12.0
- 2.11.0
- 2.10.0
- 2.9.6
- 2.8.4
- 2.7.4
public static final class Viewport.Builder extends GeneratedMessage.Builder<Viewport.Builder> implements ViewportOrBuilder A latitude-longitude viewport, represented as two diagonally opposite low
and high points. A viewport is considered a closed region, i.e. it includes
its boundary. The latitude bounds must range between -90 to 90 degrees
inclusive, and the longitude bounds must range between -180 to 180 degrees
inclusive. Various cases include:
If
low=high, the viewport consists of that single point.If
low.longitude>high.longitude, the longitude range is inverted (the viewport crosses the 180 degree longitude line).If
low.longitude= -180 degrees andhigh.longitude= 180 degrees, the viewport includes all longitudes.If
low.longitude= 180 degrees andhigh.longitude= -180 degrees, the longitude range is empty.If
low.latitude>high.latitude, the latitude range is empty.Both
lowandhighmust be populated, and the represented box cannot be empty (as specified by the definitions above). An empty viewport will result in an error.For example, this viewport fully encloses New York City:
{ "low": { "latitude": 40.477398, "longitude": -74.259087 }, "high": { "latitude": 40.91618, "longitude": -73.70018 } }
Protobuf type google.geo.type.Viewport
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > Viewport.BuilderImplements
ViewportOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public Viewport build()| Returns | |
|---|---|
| Type | Description |
Viewport |
|
buildPartial()
public Viewport buildPartial()| Returns | |
|---|---|
| Type | Description |
Viewport |
|
clear()
public Viewport.Builder clear()| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
clearHigh()
public Viewport.Builder clearHigh()Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
clearLow()
public Viewport.Builder clearLow()Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
getDefaultInstanceForType()
public Viewport getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
Viewport |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getHigh()
public LatLng getHigh()Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Returns | |
|---|---|
| Type | Description |
LatLng |
The high. |
getHighBuilder()
public LatLng.Builder getHighBuilder()Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Returns | |
|---|---|
| Type | Description |
LatLng.Builder |
|
getHighOrBuilder()
public LatLngOrBuilder getHighOrBuilder()Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Returns | |
|---|---|
| Type | Description |
LatLngOrBuilder |
|
getLow()
public LatLng getLow()Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Returns | |
|---|---|
| Type | Description |
LatLng |
The low. |
getLowBuilder()
public LatLng.Builder getLowBuilder()Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Returns | |
|---|---|
| Type | Description |
LatLng.Builder |
|
getLowOrBuilder()
public LatLngOrBuilder getLowOrBuilder()Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Returns | |
|---|---|
| Type | Description |
LatLngOrBuilder |
|
hasHigh()
public boolean hasHigh()Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the high field is set. |
hasLow()
public boolean hasLow()Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the low field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(Viewport other)
public Viewport.Builder mergeFrom(Viewport other)| Parameter | |
|---|---|
| Name | Description |
other |
Viewport |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public Viewport.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public Viewport.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
mergeHigh(LatLng value)
public Viewport.Builder mergeHigh(LatLng value)Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
LatLng |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
mergeLow(LatLng value)
public Viewport.Builder mergeLow(LatLng value)Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
LatLng |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
setHigh(LatLng value)
public Viewport.Builder setHigh(LatLng value)Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
LatLng |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
setHigh(LatLng.Builder builderForValue)
public Viewport.Builder setHigh(LatLng.Builder builderForValue)Required. The high point of the viewport.
.google.type.LatLng high = 2;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
LatLng.Builder |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
setLow(LatLng value)
public Viewport.Builder setLow(LatLng value)Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
LatLng |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|
setLow(LatLng.Builder builderForValue)
public Viewport.Builder setLow(LatLng.Builder builderForValue)Required. The low point of the viewport.
.google.type.LatLng low = 1;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
LatLng.Builder |
| Returns | |
|---|---|
| Type | Description |
Viewport.Builder |
|