4. Partie 1: Introduction Origines et principes de base
5.
6.
7.
8.
9. Anatomie d’un script // monScript.groovy // def maVariable = 3 def uneClosure = { it * it } println ‘Bonjour monde!’ L’instruction return est optionnelle Packages importés par défaut: groovy.lang.* groovy.util.* java.lang.* java.util.* java.io.* java.net.* Java.math.BigDecimal Java.math.BigInteger Le point virgule et les paranthèses sont optionnels System.out est implicite Ce script ne contient pas de classe: lors de l’exécution, il sera enrobé dans la méthode run() d’un objet de type Script
10. Partie 2: Qu’est-ce que Groovy? Survol du langage
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26. Partie 3: Que fait-on avec Groovy? Applications concrètes du langage
27.
28.
29.
30.
31.
32.
33. Services Web import groovyx.net.ws.WSClient def proxy = new WSClient("http://localhost:6980/MathService?wsdl", this.class.classLoader) def result = proxy.add(1.0 as double, 2.0 as double) import groovyx.net.ws.WSServer def server = new WSServer() server.setNode("MathService", "http://localhost:6980/MathService") Serveur Client
34.
35.
36. Partie 4: Conclusion La fin … vraiment? Ou seulement le début?