public abstract class AbstractAverageSpeedParser extends Object implements TagParser
| Modifier and Type | Field and Description |
|---|---|
protected DecimalEncodedValue |
avgSpeedEnc |
protected Set<String> |
ferries |
protected FerrySpeedCalculator |
ferrySpeedCalc |
protected double |
maxPossibleSpeed |
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractAverageSpeedParser(DecimalEncodedValue speedEnc,
double maxPossibleSpeed) |
| Modifier and Type | Method and Description |
|---|---|
DecimalEncodedValue |
getAverageSpeedEnc() |
double |
getMaxSpeed() |
static double |
getMaxSpeed(ReaderWay way,
boolean bwd) |
String |
getName() |
abstract void |
handleWayTags(IntsRef edgeFlags,
ReaderWay way) |
void |
handleWayTags(IntsRef edgeFlags,
ReaderWay way,
IntsRef relationFlags) |
protected static boolean |
isValidSpeed(double speed) |
protected void |
setSpeed(boolean reverse,
IntsRef edgeFlags,
double speed) |
String |
toString() |
protected final DecimalEncodedValue avgSpeedEnc
protected final double maxPossibleSpeed
protected final FerrySpeedCalculator ferrySpeedCalc
protected AbstractAverageSpeedParser(DecimalEncodedValue speedEnc, double maxPossibleSpeed)
public double getMaxSpeed()
public static double getMaxSpeed(ReaderWay way, boolean bwd)
Double.NaN if no maxspeed foundprotected static boolean isValidSpeed(double speed)
Double.NaNpublic final DecimalEncodedValue getAverageSpeedEnc()
protected void setSpeed(boolean reverse,
IntsRef edgeFlags,
double speed)
public final String getName()
public void handleWayTags(IntsRef edgeFlags, ReaderWay way, IntsRef relationFlags)
handleWayTags in interface TagParserCopyright © 2012–2023. All rights reserved.