public final class Location extends GeneratedMessageV3 implements LocationOrBuilder
Encapsulates a location (a geographic point, and an optional heading).
Protobuf type google.cloud.optimization.v1.Location
Static Fields
HEADING_FIELD_NUMBER
public static final int HEADING_FIELD_NUMBER
Field Value
LAT_LNG_FIELD_NUMBER
public static final int LAT_LNG_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static Location getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static Location.Builder newBuilder()
Returns
newBuilder(Location prototype)
public static Location.Builder newBuilder(Location prototype)
Parameter
Returns
public static Location parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static Location parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static Location parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Location parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static Location parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Location parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Location parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static Location parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Location parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static Location parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static Location parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Location parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<Location> parser()
Returns
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getDefaultInstanceForType()
public Location getDefaultInstanceForType()
Returns
getHeading()
The compass heading associated with the direction of the flow of traffic.
This value is used to specify the side of the road to use for pickup and
drop-off. Heading values can be from 0 to 360, where 0 specifies a heading
of due North, 90 specifies a heading of due East, etc.
optional int32 heading = 2;
Returns
Type | Description |
int | The heading.
|
getLatLng()
public LatLng getLatLng()
The waypoint's geographic coordinates.
.google.type.LatLng lat_lng = 1;
Returns
Type | Description |
com.google.type.LatLng | The latLng.
|
getLatLngOrBuilder()
public LatLngOrBuilder getLatLngOrBuilder()
The waypoint's geographic coordinates.
.google.type.LatLng lat_lng = 1;
Returns
Type | Description |
com.google.type.LatLngOrBuilder | |
getParserForType()
public Parser<Location> getParserForType()
Returns
Overrides
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hasHeading()
public boolean hasHeading()
The compass heading associated with the direction of the flow of traffic.
This value is used to specify the side of the road to use for pickup and
drop-off. Heading values can be from 0 to 360, where 0 specifies a heading
of due North, 90 specifies a heading of due East, etc.
optional int32 heading = 2;
Returns
Type | Description |
boolean | Whether the heading field is set.
|
hasLatLng()
public boolean hasLatLng()
The waypoint's geographic coordinates.
.google.type.LatLng lat_lng = 1;
Returns
Type | Description |
boolean | Whether the latLng field is set.
|
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public Location.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Location.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public Location.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions