class BavetMapBridgeQuadConstraintStream<Solution_, A, B, C, D, NewA>
        extends BavetAbstractQuadConstraintStream<Solution_, A, B, C, D> {

    private final BavetAbstractQuadConstraintStream<Solution_, A, B, C, D> parent;
    private final QuadFunction<A, B, C, D, NewA> mappingFunction;
    private BavetMapUniConstraintStream<Solution_, NewA> mapStream;

    public BavetMapBridgeQuadConstraintStream(BavetConstraintFactory<Solution_> constraintFactory,
            BavetAbstractQuadConstraintStream<Solution_, A, B, C, D> parent, QuadFunction<A, B, C, D, NewA> mappingFunction) {
        super(constraintFactory, parent.getRetrievalSemantics());
        this.parent = parent;
        this.mappingFunction = mappingFunction;
    }

    @Override
    public boolean guaranteesDistinct() {
        return false;
    }

    public void setMapStream(BavetMapUniConstraintStream<Solution_, NewA> mapStream) {
        this.mapStream = mapStream;
    }

    // ************************************************************************
    // Node creation
    // ************************************************************************

    @Override
    public void collectActiveConstraintStreams(Set<BavetAbstractConstraintStream<Solution_>> constraintStreamSet) {
        parent.collectActiveConstraintStreams(constraintStreamSet);
        constraintStreamSet.add(this);
    }

    @Override
    public BavetAbstractConstraintStream<Solution_> getTupleSource() {
        return parent.getTupleSource();
    }

    @Override
    public <Score_ extends Score<Score_>> void buildNode(NodeBuildHelper<Score_> buildHelper) {<FILL_FUNCTION_BODY>}

    // ************************************************************************
    // Equality for node sharing
    // ************************************************************************

    // TODO

    // ************************************************************************
    // Getters/setters
    // ************************************************************************

}

        if (!childStreamList.isEmpty()) {
            throw new IllegalStateException("Impossible state: the stream (" + this
                    + ") has a non-empty childStreamList (" + childStreamList + ") but it's a flattenLast bridge.");
        }
        int inputStoreIndex = buildHelper.reserveTupleStoreIndex(parent.getTupleSource());
        int outputStoreSize = buildHelper.extractTupleStoreSize(mapStream);
        AbstractMapNode<QuadTuple<A, B, C, D>, NewA> node = new MapQuadNode<>(inputStoreIndex, mappingFunction,
                buildHelper.getAggregatedTupleLifecycle(mapStream.getChildStreamList()), outputStoreSize);
        buildHelper.addNode(node, this);
    
<methods>public void <init>(BavetConstraintFactory<Solution_>, org.optaplanner.constraint.streams.common.RetrievalSemantics) ,public BavetAbstractQuadConstraintStream<Solution_,A,B,C,D> filter(QuadPredicate<A,B,C,D>) ,public QuadConstraintStream<A,B,C,ResultD_> flattenLast(Function<D,Iterable<ResultD_>>) ,public List<BavetAbstractQuadConstraintStream<Solution_,A,B,C,D>> getChildStreamList() ,public UniConstraintStream<Result_> groupBy(QuadConstraintCollector<A,B,C,D,ResultContainer_,Result_>) ,public BiConstraintStream<ResultA_,ResultB_> groupBy(QuadConstraintCollector<A,B,C,D,ResultContainerA_,ResultA_>, QuadConstraintCollector<A,B,C,D,ResultContainerB_,ResultB_>) ,public TriConstraintStream<ResultA_,ResultB_,ResultC_> groupBy(QuadConstraintCollector<A,B,C,D,ResultContainerA_,ResultA_>, QuadConstraintCollector<A,B,C,D,ResultContainerB_,ResultB_>, QuadConstraintCollector<A,B,C,D,ResultContainerC_,ResultC_>) ,public QuadConstraintStream<ResultA_,ResultB_,ResultC_,ResultD_> groupBy(QuadConstraintCollector<A,B,C,D,ResultContainerA_,ResultA_>, QuadConstraintCollector<A,B,C,D,ResultContainerB_,ResultB_>, QuadConstraintCollector<A,B,C,D,ResultContainerC_,ResultC_>, QuadConstraintCollector<A,B,C,D,ResultContainerD_,ResultD_>) ,public UniConstraintStream<GroupKey_> groupBy(QuadFunction<A,B,C,D,GroupKey_>) ,public TriConstraintStream<GroupKey_,ResultB_,ResultC_> groupBy(QuadFunction<A,B,C,D,GroupKey_>, QuadConstraintCollector<A,B,C,D,ResultContainerB_,ResultB_>, QuadConstraintCollector<A,B,C,D,ResultContainerC_,ResultC_>) ,public QuadConstraintStream<GroupKey_,ResultB_,ResultC_,ResultD_> groupBy(QuadFunction<A,B,C,D,GroupKey_>, QuadConstraintCollector<A,B,C,D,ResultContainerB_,ResultB_>, QuadConstraintCollector<A,B,C,D,ResultContainerC_,ResultC_>, QuadConstraintCollector<A,B,C,D,ResultContainerD_,ResultD_>) ,public BiConstraintStream<GroupKey_,Result_> groupBy(QuadFunction<A,B,C,D,GroupKey_>, QuadConstraintCollector<A,B,C,D,ResultContainer_,Result_>) ,public BiConstraintStream<GroupKeyA_,GroupKeyB_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>) ,public TriConstraintStream<GroupKeyA_,GroupKeyB_,Result_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>, QuadConstraintCollector<A,B,C,D,ResultContainer_,Result_>) ,public QuadConstraintStream<GroupKeyA_,GroupKeyB_,ResultC_,ResultD_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>, QuadConstraintCollector<A,B,C,D,ResultContainerC_,ResultC_>, QuadConstraintCollector<A,B,C,D,ResultContainerD_,ResultD_>) ,public TriConstraintStream<GroupKeyA_,GroupKeyB_,GroupKeyC_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>, QuadFunction<A,B,C,D,GroupKeyC_>) ,public QuadConstraintStream<GroupKeyA_,GroupKeyB_,GroupKeyC_,ResultD_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>, QuadFunction<A,B,C,D,GroupKeyC_>, QuadConstraintCollector<A,B,C,D,ResultContainerD_,ResultD_>) ,public QuadConstraintStream<GroupKeyA_,GroupKeyB_,GroupKeyC_,GroupKeyD_> groupBy(QuadFunction<A,B,C,D,GroupKeyA_>, QuadFunction<A,B,C,D,GroupKeyB_>, QuadFunction<A,B,C,D,GroupKeyC_>, QuadFunction<A,B,C,D,GroupKeyD_>) ,public final transient QuadConstraintStream<A,B,C,D> ifExists(Class<E>, PentaJoiner<A,B,C,D,E>[]) ,public final transient QuadConstraintStream<A,B,C,D> ifExists(UniConstraintStream<E>, PentaJoiner<A,B,C,D,E>[]) ,public final transient QuadConstraintStream<A,B,C,D> ifExistsIncludingNullVars(Class<E>, PentaJoiner<A,B,C,D,E>[]) ,public final transient QuadConstraintStream<A,B,C,D> ifNotExists(Class<E>, PentaJoiner<A,B,C,D,E>[]) ,public final transient QuadConstraintStream<A,B,C,D> ifNotExists(UniConstraintStream<E>, PentaJoiner<A,B,C,D,E>[]) ,public final transient QuadConstraintStream<A,B,C,D> ifNotExistsIncludingNullVars(Class<E>, PentaJoiner<A,B,C,D,E>[]) ,public QuadConstraintBuilder<A,B,C,D,Score_> innerImpact(Score_, ToIntQuadFunction<A,B,C,D>, org.optaplanner.constraint.streams.common.ScoreImpactType) ,public QuadConstraintBuilder<A,B,C,D,Score_> innerImpact(Score_, ToLongQuadFunction<A,B,C,D>, org.optaplanner.constraint.streams.common.ScoreImpactType) ,public QuadConstraintBuilder<A,B,C,D,Score_> innerImpact(Score_, QuadFunction<A,B,C,D,java.math.BigDecimal>, org.optaplanner.constraint.streams.common.ScoreImpactType) ,public UniConstraintStream<ResultA_> map(QuadFunction<A,B,C,D,ResultA_>) ,public Stream_ shareAndAddChild(Stream_) <variables>protected final List<BavetAbstractQuadConstraintStream<Solution_,A,B,C,D>> childStreamList