if (template != null) {
for (final TriplePattern tp : template) {
final Triple trip = new Triple();
for (int i = 0; i < 3; i++) {
if (tp.getPos(i) instanceof BlankNode) {
final BlankNode bn = (BlankNode) tp.getPos(i);
AnonymousLiteral al = assignedBlankNodes.get(bn);
if (al == null) {
do {
al = new AnonymousLiteral("_:_constructedBN"
+ bnodeid++);