INTEGRANDO GROOVY &
GRAILS AL DESARROLLO DE
        SOFTWARE
        José Juan Reyes Zuñiga
   @neodevelop - @synergyj - @joedayz
AGENDA

• Qué   es Groovy?

• Como    lo integro a la JVM?

• Qué   es Grails?

• Como    desarrollo aplicaciones en Grails para Java?

• Conclusiones
¿QUÉ ES GROOVY?


• “Groovy  is like a super version of Java. It can leverage Java's
 enterprise capabilities but also has cool productivity features
 like closures, builders and dynamic typing. If you are a
 developer, tester or script guru, you have to love Groovy."
¿QUÉ PODEMOS HACER CON
        GROOVY?
• Lo   mismo que en Java pero...

 • Más    fácil

 • Más    simple

 • Más    rápido

• Mucho    más...

 • Innovar

 • Inventar
¿QUÉ PODEMOS
     ENCONTRAR EN GROOVY?
•   Totalmente Orientado a objetos
•   Perfecta integración con Java
•   Closures
•   Convención de JavaBeans
•   Esencia vs. Ceremonia
•   Aritmética con BigDecimal por default para la operación de punto
    flotante
•   API’s amigables y prácticas
•   XML, JDBC, JMX, Swing
•   DSL(Domain Specific Language)
•   Builders
•   Sobrecarga de operadores
•   GDK
AZÚCAR SINTÁCTICA

• Listas
  • def numeros = [1,2,3,4,5]
• Mapas
  • def mapa = [DF:'Distrito Federal',MTY:'Monterrey']
• Rangos
  • def rangos = 199..299
• Asignación Múltiple
  • def (a,b) = [10,20]
• Return Opcional
  • def metodo(bool) { if(bool) 1 else 0 }
GROOVY EN PROFUNDIDAD

• Meta-programación
  • La habilidad de un lenguaje para   modificarse a sí mismo
• Transformaciones AST
  • @Singleton
  • @Inmutable, @Lazy, @Delegate
  • @Newify
  • @Category & @Mixin
  • @PackageScope
  • @Bindable & @Vetoable
  • @Grab
QUÉ + HAY EN GRAILS?

• MVC                        • URL Mappings
• GORM                       • Flows
  • Hibernate                • Templates
  • Sin configuración         • i18n
  • Se pueden hacer mapeos   • Diseños gráficos
  • Dynamic finders           • Testing
  • Queries                  • Uso de componentes   Spring
• Constraints                • Plugin’s
• Services                   • Más....
• GSP para la vista
• Taglibs
GRAILS + PLUGINS
LET’S CODE
¿QUIERES SER
  GROOVY?
   Conclusiones
¡¡¡GRACIAS!!!
     José Juan Reyes Zuñiga
@neodevelop - @synergyj - @joedayz

Integrando Groovy & Grails en el proceso de desarrollo

  • 1.
    INTEGRANDO GROOVY & GRAILSAL DESARROLLO DE SOFTWARE José Juan Reyes Zuñiga @neodevelop - @synergyj - @joedayz
  • 2.
    AGENDA • Qué es Groovy? • Como lo integro a la JVM? • Qué es Grails? • Como desarrollo aplicaciones en Grails para Java? • Conclusiones
  • 3.
    ¿QUÉ ES GROOVY? •“Groovy is like a super version of Java. It can leverage Java's enterprise capabilities but also has cool productivity features like closures, builders and dynamic typing. If you are a developer, tester or script guru, you have to love Groovy."
  • 4.
    ¿QUÉ PODEMOS HACERCON GROOVY? • Lo mismo que en Java pero... • Más fácil • Más simple • Más rápido • Mucho más... • Innovar • Inventar
  • 5.
    ¿QUÉ PODEMOS ENCONTRAR EN GROOVY? • Totalmente Orientado a objetos • Perfecta integración con Java • Closures • Convención de JavaBeans • Esencia vs. Ceremonia • Aritmética con BigDecimal por default para la operación de punto flotante • API’s amigables y prácticas • XML, JDBC, JMX, Swing • DSL(Domain Specific Language) • Builders • Sobrecarga de operadores • GDK
  • 6.
    AZÚCAR SINTÁCTICA • Listas • def numeros = [1,2,3,4,5] • Mapas • def mapa = [DF:'Distrito Federal',MTY:'Monterrey'] • Rangos • def rangos = 199..299 • Asignación Múltiple • def (a,b) = [10,20] • Return Opcional • def metodo(bool) { if(bool) 1 else 0 }
  • 7.
    GROOVY EN PROFUNDIDAD •Meta-programación • La habilidad de un lenguaje para modificarse a sí mismo • Transformaciones AST • @Singleton • @Inmutable, @Lazy, @Delegate • @Newify • @Category & @Mixin • @PackageScope • @Bindable & @Vetoable • @Grab
  • 10.
    QUÉ + HAYEN GRAILS? • MVC • URL Mappings • GORM • Flows • Hibernate • Templates • Sin configuración • i18n • Se pueden hacer mapeos • Diseños gráficos • Dynamic finders • Testing • Queries • Uso de componentes Spring • Constraints • Plugin’s • Services • Más.... • GSP para la vista • Taglibs
  • 11.
  • 12.
  • 13.
    ¿QUIERES SER GROOVY? Conclusiones
  • 14.
    ¡¡¡GRACIAS!!! José Juan Reyes Zuñiga @neodevelop - @synergyj - @joedayz