map

Returns a BinaryDecisionDiagram containing nodes of applying the given transform function to each element in the original BinaryDecisionDiagram. The internal structure of the diagram is maintained. Used e.g. by it.unibo.tuprolog.solve.problog.lib.knowledge.impl.BinaryDecisionDiagramExplanation.apply to rewrite the Prolog terms held by every variable of an explanation (e.g. after applying a substitution), as diagram.map { transformation(it) }.

Return

a new diagram with the same shape, whose variable values are the result of applying mapper to the original ones.

Parameters

mapper

transforms each variable value of type T into a value of type E.

Throws