Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Number:

GEP-3

Title:

Command Expression based DSL

Version:

1

Type:

Feature

Target:

1.8 or 2.0

Status:

Draft

Leader:

Jochen "blackdrag" Theodorou

Created:

2009-06-30

Last modification:

2009 2010-1203-11 23

Last update by:

Guillaume Laforge

...

So the Groovy notation would be a bit more verbose, but not much.

References

To be evaluated: Mixed case with explicit parentheses

A possible supported case is also when mixing method calls with explicit parentheses within that extended command expression.
The benefit would be to allow the ability to also be able to call methods not taking parameters, as well as allowing an odd number of "elements" (ie. a method name or a parameter).

Code Block

m1 a m2 b m3()
m1 a m2() m3 b
m1() m2 a m3 b

would be respectively equivalent to:

Code Block

m1(a).m2(b).m3()
m1(a).m2().m3(b)
m1().m2(a).m3(b)

Note that the method calls with explicit parentheses could also take a number of arguments.
For instance, this is also a valid mixed command expression:

Code Block

m1 a m2(1, 2, 3) m3 b

Mailing-list discussions

JIRA issues

...