public abstract class AbstractPathDetailsBuilder extends Object implements PathDetailsBuilder
Constructor and Description |
---|
AbstractPathDetailsBuilder(String name) |
Modifier and Type | Method and Description |
---|---|
Map.Entry<String,List<PathDetail>> |
build() |
void |
endInterval(int lastIndex)
Ending intervals multiple times is safe, we only write the interval if it was open and not empty.
|
protected abstract Object |
getCurrentValue()
The value of the Path at this moment, that should be stored in the PathDetail when calling startInterval
|
String |
getName() |
void |
startInterval(int firstIndex)
It is only possible to open one interval at a time.
|
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
isEdgeDifferentToLastEdge
public AbstractPathDetailsBuilder(String name)
protected abstract Object getCurrentValue()
public void startInterval(int firstIndex)
startInterval
when
the interval is already open results in an Exception.startInterval
in interface PathDetailsBuilder
firstIndex
- the index the PathDetail startspublic void endInterval(int lastIndex)
endInterval
in interface PathDetailsBuilder
lastIndex
- the index the PathDetail endspublic Map.Entry<String,List<PathDetail>> build()
build
in interface PathDetailsBuilder
public String getName()
getName
in interface PathDetailsBuilder
Copyright © 2012–2019. All rights reserved.