1.i can’t understand which task(*) method invoked when i write the block script “task myTask(type: SomeType) { configure closure }”.is it groovy syntax?
2.ext{ } has the same doubt,is it Project object block script? and in Project api don’t find ext.
please help me answer the questions.and i want to know some source code execute details.
The last two take advantage of a Groovy feature (which give you something like named parameters). You can see an example here.
ext is a built-in extension called ExtraPropertiesExtension. A lot of types have this extension built-in. ext and property look-up in general are described in the DSL guide for Project. It relies on some of the dynamic properties of Groovy (methodMissing or propertyMissing methods) to look-up things properly.