Skip to content

Commit ad3526c

Browse files
committed
chore(parser): code cleanup
1 parent 20a4172 commit ad3526c

5 files changed

Lines changed: 2 additions & 23 deletions

File tree

packages/opendrive-parser/src/elements/junction.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,12 @@ export class Connection implements IConnection {
2121
}
2222

2323
export class Junction implements IJunction {
24-
private openDrive: OpenDrive
2524
public type: string = 'junction'
2625
public id: string
2726
public name: string
2827
public connections: Connection[]
2928

30-
constructor(rawJunction: RawJunction, openDrive: OpenDrive) {
31-
this.openDrive = openDrive
29+
constructor(rawJunction: RawJunction) {
3230
this.id = rawJunction.id
3331
this.name = rawJunction.name
3432
this.connections = arrayize(rawJunction.connection).map(c => new Connection(c))

packages/opendrive-parser/src/elements/opendrive.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class OpenDrive implements IOpenDrive {
3939

4040
private parseJunctions(rawData: RawOpenDrive): void {
4141
for (const rawJunction of arrayize(rawData.junction)) {
42-
const junction = new Junction(rawJunction, this)
42+
const junction = new Junction(rawJunction)
4343
this.junctions.push(junction)
4444
}
4545
}

packages/opendrive-parser/src/elements/plan-view.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ export default class PlanView implements IPlanView {
4949
else {
5050
referencePoints.push(...points)
5151
}
52-
// referencePoints.push(...points)
5352
sStartRoad += geometryLength
5453
}
5554

packages/opendrive-parser/src/elements/road.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,6 @@ class Road implements IRoad {
148148

149149
private generateReferenceLine(step: number): void {
150150
const points = this.planView.sample(this.elevationProfile, step)
151-
// points.sort((a, b) => a.getSOfRoad() - b.getSOfRoad())
152151

153152
this.referenceLine = new ReferenceLine(points)
154153
}

packages/opendrive-parser/src/utils/binary-search.ts

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)