Skip to content

Commit cae0124

Browse files
authored
revert tunnelName field (#1185)
1 parent 5988a03 commit cae0124

2 files changed

Lines changed: 0 additions & 21 deletions

File tree

services-directions-models/src/main/java/com/mapbox/api/directions/v5/models/StepIntersection.java

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -127,15 +127,6 @@ public Point location() {
127127
@Nullable
128128
public abstract List<IntersectionLanes> lanes();
129129

130-
/**
131-
* Name of the tunnel. Value may be present if {@link #classes} contains "tunnel".
132-
*
133-
* @return name of the tunnel
134-
*/
135-
@Nullable
136-
@SerializedName("tunnel_name")
137-
public abstract String tunnelName();
138-
139130
/**
140131
* The zero-based index for the intersection.
141132
* This value can be used to apply the duration annotation that corresponds with the intersection.
@@ -288,14 +279,6 @@ public abstract static class Builder {
288279
*/
289280
public abstract Builder lanes(@Nullable List<IntersectionLanes> lanes);
290281

291-
/**
292-
* Name of the tunnel. Value is present only if class is tunnel.
293-
*
294-
* @param tunnelName name of the tunnel
295-
* @return this builder for chaining options together
296-
*/
297-
public abstract Builder tunnelName(@Nullable String tunnelName);
298-
299282
/**
300283
* The zero-based index for the intersection.
301284
* This value can be used to apply the duration annotation

services-directions-models/src/test/java/com/mapbox/api/directions/v5/models/StepIntersectionTest.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ public void testToFromJson1() {
4444
.entry(Arrays.asList(true))
4545
.bearings(Arrays.asList(125))
4646
.rawLocation(new double[]{13.426579, 52.508068})
47-
.tunnelName("test tunnel")
4847
.geometryIndex(123)
4948
.isUrban(true)
5049
.mapboxStreetsV8(MapboxStreetsV8.builder().roadClass("street").build())
@@ -64,7 +63,6 @@ public void testToFromJson2() {
6463
.entry(Arrays.asList(false, true, true))
6564
.bearings(Arrays.asList(120, 210, 300))
6665
.rawLocation(new double[]{13.424671, 52.508812})
67-
.tunnelName("test tunnel")
6866
.mapboxStreetsV8(MapboxStreetsV8.builder().roadClass("street").build())
6967
.build();
7068

@@ -82,14 +80,12 @@ public void testFromJson() {
8280
+ "\"bearings\": [ 125 ], "
8381
+ "\"entry\": [true], "
8482
+ "\"out\": 0, "
85-
+ "\"tunnel_name\": \"test tunnel name\","
8683
+ "\"geometry_index\": 123,"
8784
+ "\"is_urban\": true,"
8885
+ "\"mapbox_streets_v8\": {\"class\": \"street\"}"
8986
+ "}";
9087

9188
StepIntersection stepIntersection = StepIntersection.fromJson(stepIntersectionJsonString);
92-
Assert.assertEquals("test tunnel name", stepIntersection.tunnelName());
9389
Assert.assertEquals(123, stepIntersection.geometryIndex().intValue());
9490
assertTrue(stepIntersection.isUrban());
9591
assertEquals("street", stepIntersection.mapboxStreetsV8().roadClass());

0 commit comments

Comments
 (0)