core (2) [Avatar] Offline
Can I create a NodeBuilder node where the node name is variable?

Say I want to create nodes like: node1, node2, node3.

I can't do this directly...

builder= new NodeBuilder()
builder.a() {
def nodeName= 'c'+ it
println "nodeName= ${nodeName}"
nodeName () // !!! want the node name here

Realized this is not specific to the book so I should post it somewhere else.

Message was edited by: