Change constructor of InitialElementProducer
Path path = ...;
new InitialElementProducer(path);
Since Path
is an Iterable<Path>
, the InitialElementProducer
iterates its path parts. Only the following code snippet allows us to pass a Path
as single object:
Path path = ...;
new InitialElementProducer(Arrays.asList(path));
We should change the constructor from Iterable<T>
to Collection<T>
.