Package com.graphhopper.util.details
Class ConstantDetailsBuilder
java.lang.Object
com.graphhopper.util.details.AbstractPathDetailsBuilder
com.graphhopper.util.details.ConstantDetailsBuilder
- All Implemented Interfaces:
PathDetailsBuilder
Simply returns the same value everywhere, useful to represent values that are the same between two (via-)points
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
void
endInterval
(int lastIndex) Ending intervals multiple times is safe, we only write the interval if it was open and not empty.protected Object
The value of the Path at this moment, that should be stored in the PathDetail when calling startIntervalboolean
Methods inherited from class com.graphhopper.util.details.AbstractPathDetailsBuilder
getName, startInterval, toString
-
Constructor Details
-
ConstantDetailsBuilder
-
-
Method Details
-
getCurrentValue
Description copied from class:AbstractPathDetailsBuilder
The value of the Path at this moment, that should be stored in the PathDetail when calling startInterval- Specified by:
getCurrentValue
in classAbstractPathDetailsBuilder
-
isEdgeDifferentToLastEdge
-
endInterval
public void endInterval(int lastIndex) Description copied from class:AbstractPathDetailsBuilder
Ending intervals multiple times is safe, we only write the interval if it was open and not empty. Writes the interval to the pathDetails- Specified by:
endInterval
in interfacePathDetailsBuilder
- Overrides:
endInterval
in classAbstractPathDetailsBuilder
- Parameters:
lastIndex
- the index the PathDetail ends
-
build
- Specified by:
build
in interfacePathDetailsBuilder
- Overrides:
build
in classAbstractPathDetailsBuilder
-