public static final class Polyline.Builder extends com.google.protobuf.GeneratedMessage.Builder<Polyline.Builder> implements PolylineOrBuilder
Encapsulates an encoded polyline.Protobuf type
google.maps.routing.v2.Polyline| Modifier and Type | Method and Description |
|---|---|
Polyline |
build() |
Polyline |
buildPartial() |
Polyline.Builder |
clear() |
Polyline.Builder |
clearEncodedPolyline()
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
Polyline.Builder |
clearGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
Polyline.Builder |
clearPolylineType() |
Polyline |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getEncodedPolyline()
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
com.google.protobuf.ByteString |
getEncodedPolylineBytes()
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
com.google.protobuf.Struct |
getGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
com.google.protobuf.Struct.Builder |
getGeoJsonLinestringBuilder()
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
com.google.protobuf.StructOrBuilder |
getGeoJsonLinestringOrBuilder()
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
Polyline.PolylineTypeCase |
getPolylineTypeCase() |
boolean |
hasEncodedPolyline()
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
boolean |
hasGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
Polyline.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
Polyline.Builder |
mergeFrom(com.google.protobuf.Message other) |
Polyline.Builder |
mergeFrom(Polyline other) |
Polyline.Builder |
mergeGeoJsonLinestring(com.google.protobuf.Struct value)
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
Polyline.Builder |
setEncodedPolyline(String value)
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
Polyline.Builder |
setEncodedPolylineBytes(com.google.protobuf.ByteString value)
The string encoding of the polyline using the [polyline encoding
algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1; |
Polyline.Builder |
setGeoJsonLinestring(com.google.protobuf.Struct.Builder builderForValue)
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
Polyline.Builder |
setGeoJsonLinestring(com.google.protobuf.Struct value)
Specifies a polyline using the [GeoJSON LineString
format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
|
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfindInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneofpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<Polyline.Builder>public Polyline.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessage.Builder<Polyline.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<Polyline.Builder>public Polyline getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic Polyline build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic Polyline buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic Polyline.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<Polyline.Builder>public Polyline.Builder mergeFrom(Polyline other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessage.Builder<Polyline.Builder>public Polyline.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<Polyline.Builder>IOExceptionpublic Polyline.PolylineTypeCase getPolylineTypeCase()
getPolylineTypeCase in interface PolylineOrBuilderpublic Polyline.Builder clearPolylineType()
public boolean hasEncodedPolyline()
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;hasEncodedPolyline in interface PolylineOrBuilderpublic String getEncodedPolyline()
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;getEncodedPolyline in interface PolylineOrBuilderpublic com.google.protobuf.ByteString getEncodedPolylineBytes()
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;getEncodedPolylineBytes in interface PolylineOrBuilderpublic Polyline.Builder setEncodedPolyline(String value)
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;value - The encodedPolyline to set.public Polyline.Builder clearEncodedPolyline()
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;public Polyline.Builder setEncodedPolylineBytes(com.google.protobuf.ByteString value)
The string encoding of the polyline using the [polyline encoding algorithm](https://developers.google.com/maps/documentation/utilities/polylinealgorithm)
string encoded_polyline = 1;value - The bytes for encodedPolyline to set.public boolean hasGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;hasGeoJsonLinestring in interface PolylineOrBuilderpublic com.google.protobuf.Struct getGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;getGeoJsonLinestring in interface PolylineOrBuilderpublic Polyline.Builder setGeoJsonLinestring(com.google.protobuf.Struct value)
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;public Polyline.Builder setGeoJsonLinestring(com.google.protobuf.Struct.Builder builderForValue)
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;public Polyline.Builder mergeGeoJsonLinestring(com.google.protobuf.Struct value)
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;public Polyline.Builder clearGeoJsonLinestring()
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;public com.google.protobuf.Struct.Builder getGeoJsonLinestringBuilder()
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;public com.google.protobuf.StructOrBuilder getGeoJsonLinestringOrBuilder()
Specifies a polyline using the [GeoJSON LineString format](https://tools.ietf.org/html/rfc7946#section-3.1.4).
.google.protobuf.Struct geo_json_linestring = 2;getGeoJsonLinestringOrBuilder in interface PolylineOrBuilderCopyright © 2026 Google LLC. All rights reserved.