© 2026 Hedgehog Software, LLC
g.withSideEffect("map", [3: "foo", 4: "bar"]). inject("a", "b", "c", "d"). aggregate(local, "x"). map(select("x").count(local))
==>1 ==>2 ==>3 ==>4
.as("cnt").select("map").select(select("cnt"))
g.withSideEffect("map", [3: "foo", 4: "bar"]). inject("a", "b", "c", "d"). aggregate(local, "x"). map(select("x").count(local)). as("cnt"). select("map").select(select('cnt'))
select("cnt")
constant(3)
foo
==>foo ==>foo ==>foo ==>foo
g.withSideEffect("map", [3L: "foo", 4L: "bar"]). inject("a", "b", "c", "d"). aggregate(local, "x"). map(select("x").count(local)). as("cnt"). select("map").select(select('cnt')) ==>foo ==>bar