class Road: Any

Representation of an actual road (without road objects) containing the surface and information on the lane topology as well as attributes.

Fields

Name Description
val id: RoadspaceIdentifier

identifier of this road (each roadspace has exactly one road)

val surface: AbstractCurveRelativeSurface3D

surface geometry of the road with torsion applied

val surfaceWithoutTorsion: AbstractCurveRelativeSurface3D

surface geometry of the road without torsion applied

val laneOffset: UnivariateFunction

lateral lane offset to road reference line

val laneSections: List<LaneSection>

lane sections of this road

val linkage: RoadLinkage

link information to other roads and junctions

Constructors

<init>

constructor(id: RoadspaceIdentifier, surface: AbstractCurveRelativeSurface3D, surfaceWithoutTorsion: AbstractCurveRelativeSurface3D, laneOffset: UnivariateFunction, laneSections: List<LaneSection>, linkage: RoadLinkage)

Representation of an actual road (without road objects) containing the surface and information on the lane topology as well as attributes.

Parameters

Name Description
id: RoadspaceIdentifier

identifier of this road (each roadspace has exactly one road)

surface: AbstractCurveRelativeSurface3D

surface geometry of the road with torsion applied

surfaceWithoutTorsion: AbstractCurveRelativeSurface3D

surface geometry of the road without torsion applied

laneOffset: UnivariateFunction

lateral lane offset to road reference line

laneSections: List<LaneSection>

lane sections of this road

linkage: RoadLinkage

link information to other roads and junctions

Methods

getAllLeftRightLaneIdentifiers

fun getAllLeftRightLaneIdentifiers(): List<LaneIdentifier>

Returns the identifiers of all left and right lanes as a flattened list.

ReturnValue

Name Description
List<LaneIdentifier>

getAllLeftRightLanes

fun getAllLeftRightLanes(): List<Lane>

Returns all left and right lanes as a flattened list.

ReturnValue

Name Description
List<Lane>

getAllCenterLaneIdentifier

fun getAllCenterLaneIdentifier(): List<LaneIdentifier>

Returns the identifiers of all center lanes as a list.

ReturnValue

Name Description
List<LaneIdentifier>

getAllLaneIdentifiers

fun getAllLaneIdentifiers(): List<LaneIdentifier>

Returns the identifiers of all lanes (center, left and right) as a list.

ReturnValue

Name Description
List<LaneIdentifier>

getAllLaneSectionIdentifiers

fun getAllLaneSectionIdentifiers(): List<LaneSectionIdentifier>

Returns the identifiers of all lane sections as a list.

ReturnValue

Name Description
List<LaneSectionIdentifier>

getLaneReferenceLine

fun getLaneReferenceLine(): AbstractCurve3D

Returns the lane reference line which is a laterally translated road reference line.

ReturnValue

Name Description
AbstractCurve3D

getLaneSection

fun getLaneSection(laneSectionIdentifier: LaneSectionIdentifier): (laneSectionIdentifier: LaneSectionIdentifier)

Returns the lane section with the laneSectionIdentifier; if it does not exist, an Result.Failure is returned.

Parameters

Name Description
laneSectionIdentifier: LaneSectionIdentifier

ReturnValue

Name Description
(laneSectionIdentifier: LaneSectionIdentifier)

getLane

fun getLane(laneIdentifier: LaneIdentifier): Result<Lane, IllegalArgumentException>

Returns an individual lane referenced by laneIdentifier; if it does not exist, an Result.Failure is returned.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Result<Lane, IllegalArgumentException>

isLocatedInJunction

fun isLocatedInJunction(): ()

Returns true, if road belongs to a junction.

ReturnValue

Name Description
()

getRoadspaceContactPointToJunction

fun getRoadspaceContactPointToJunction(junctionIdentifier: JunctionIdentifier): Option<RoadspaceContactPointIdentifier>

Returns the contact point of the roadspace which connects to the junction with the junctionIdentifier.

Parameters

Name Description
junctionIdentifier: JunctionIdentifier

ReturnValue

Name Description
Option<RoadspaceContactPointIdentifier>

getLaneSectionIdentifier

fun getLaneSectionIdentifier(roadspaceContactPointIdentifier: RoadspaceContactPointIdentifier): LaneSectionIdentifier

Returns the LaneSectionIdentifier (first or last lane section) of the roadspace which is referenced by the roadspaceContactPointIdentifier.

Parameters

Name Description
roadspaceContactPointIdentifier: RoadspaceContactPointIdentifier

ReturnValue

Name Description
LaneSectionIdentifier

isInFirstLaneSection

fun isInFirstLaneSection(laneIdentifier: LaneIdentifier): Boolean

Returns true, if the lane with laneIdentifier is contained in the last lane section of the road.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Boolean

isInLastLaneSection

fun isInLastLaneSection(laneIdentifier: LaneIdentifier): Boolean

Returns true, if the lane with laneIdentifier is contained in the last lane section of the road.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Boolean

numberOfLaneSections

fun numberOfLaneSections(): Int

Returns the number of contained lane sections.

ReturnValue

Name Description
Int

getAllCenterLanes

fun getAllCenterLanes(): List<Triple<LaneIdentifier, AbstractCurve3D, AttributeList>>

Returns the center line of the road.

ReturnValue

Name Description
List<Triple<LaneIdentifier, AbstractCurve3D, AttributeList>>

getAllLeftLaneBoundaries

fun getAllLeftLaneBoundaries(): List<Pair<LaneIdentifier, AbstractCurve3D>>

Returns the left boundary of all lanes contained in this road.

ReturnValue

Name Description
List<Pair<LaneIdentifier, AbstractCurve3D>>

a triple of the lane identifier, the curve geometry and the lane's id attribute list

getAllRightLaneBoundaries

fun getAllRightLaneBoundaries(): List<Pair<LaneIdentifier, AbstractCurve3D>>

Returns the right boundary of all lanes contained in this road.

ReturnValue

Name Description
List<Pair<LaneIdentifier, AbstractCurve3D>>

a triple of the lane identifier, the curve geometry and the lane's id attribute list

getAllCurvesOnLanes

fun getAllCurvesOnLanes(factor: Double): List<Pair<LaneIdentifier, AbstractCurve3D>>

Returns a lane curve for all lanes contained in this road.

Parameters

Name Description
factor: Double

if the factor is 0.0, the inner lane boundary is returned; if the factor is 1.0, the outer lane boundary is returned; if the factor is 0.5, the center line of the lane is returned

ReturnValue

Name Description
List<Pair<LaneIdentifier, AbstractCurve3D>>

a triple of the lane identifier, the curve geometry and the lane's id attribute list

getLeftLaneBoundary

fun getLeftLaneBoundary(laneIdentifier: LaneIdentifier): Result<AbstractCurve3D, Exception>

Returns the left boundary of an individual lane with laneIdentifier.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getRightLaneBoundary

fun getRightLaneBoundary(laneIdentifier: LaneIdentifier): Result<AbstractCurve3D, Exception>

Returns the right boundary of an individual lane with laneIdentifier.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getInnerLaneBoundary

fun getInnerLaneBoundary(laneIdentifier: LaneIdentifier): Result<AbstractCurve3D, Exception>

Returns the inner lane boundary of an individual lane with laneIdentifier.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getOuterLaneBoundary

fun getOuterLaneBoundary(laneIdentifier: LaneIdentifier): Result<AbstractCurve3D, Exception>

Returns the outer lane boundary of an individual lane with laneIdentifier.

Parameters

Name Description
laneIdentifier: LaneIdentifier

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getCurveOfCenterLane

fun getCurveOfCenterLane(laneSectionIdentifier: LaneSectionIdentifier): Result<AbstractCurve3D, Exception>

Returns the curve of the center lane with laneSectionIdentifier.

Parameters

Name Description
laneSectionIdentifier: LaneSectionIdentifier

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getCurveOnLane

fun getCurveOnLane(laneIdentifier: LaneIdentifier, factor: Double, addLateralOffset: UnivariateFunction): Result<AbstractCurve3D, Exception>

Returns a curve that lies on the road surface and is parallel to the lane boundaries

Parameters

Name Description
laneIdentifier: LaneIdentifier

identifier for requested lane

factor: Double

if the factor is 0.0, the inner lane boundary is returned; if the factor is 1.0, the outer lane boundary is returned; if the factor is 0.5, the center line of the lane is returned

addLateralOffset: UnivariateFunction

ReturnValue

Name Description
Result<AbstractCurve3D, Exception>

getLaneSurface

fun getLaneSurface(laneIdentifier: LaneIdentifier, step: Double): Result<AbstractSurface3D, Exception>

Returns the surface of an individual lane with laneIdentifier and a certain discretization step size.

Parameters

Name Description
laneIdentifier: LaneIdentifier
step: Double

ReturnValue

Name Description
Result<AbstractSurface3D, Exception>

getInnerLateralFillerSurface

fun getInnerLateralFillerSurface(laneIdentifier: LaneIdentifier, step: Double): Result, Exception><Option<LateralFillerSurface>, Exception>

Returns the filler surface which closes the gap occurring at the lateral transition of two lane elements. These lateral transitions might contain vertical holes which are caused by e.g. lane height offsets. If no lateral surface filler is needed due to adjacent lane surfaces, Option is returned.

Parameters

Name Description
laneIdentifier: LaneIdentifier

lane identifier for which the lateral filler surfaces to the left shall be created

step: Double

discretization step size

ReturnValue

Name Description
Result, Exception><Option<LateralFillerSurface>, Exception>

getRoadMarkings

fun getRoadMarkings(laneIdentifier: LaneIdentifier, step: Double): List<Result, Exception><Pair<RoadMarking, AbstractGeometry3D>, Exception>>

Parameters

Name Description
laneIdentifier: LaneIdentifier
step: Double

ReturnValue

Name Description
List<Result, Exception><Pair<RoadMarking, AbstractGeometry3D>, Exception>>