There are not many technologies that can brag about staying relevant for more than 30 years. Java is one of those technologies that is not only staying relevant but also evolving with time. However, in Java, due to verbose and complexities in coding, developers started using different platforms and languages to counterfeit this downside.
Apache Groovy is the number one go-to language when it comes to knocking up quick scripts to automate drudge work and even for writing full-scale applications (using other frameworks such as Grails and Griffon). Groovy is predominantly seen today in Jenkins pipelines scripts and in Gradle build scripts, but this really underplays its power and versatility, as we’ll see in this course. You will learn many exciting features of Groovy and see how it reduces execution time with its lightweight syntaxes.
This course will teach you how to set up Groovy, install it, and create Groovy projects in the IDE. Then you’ll be exploring the Groovy toolset and using the Groovy console to execute Groovy code. Moving ahead, you’ll learn common Groovy operators that form the cornerstone of its powerful syntax. You will then learn how to use regular expressions and capture groups to parse and extract strings. You’ll also look at Groovy collections and the enhancements delivered by GDK (Groovy Development kit). Finally, you’ll be filtering and transforming collections in Groovy with Groovy’s powerful closure mechanism and much more.
By the end of this course, you will learn Groovy’s features and start using them in your day-to-day activities with ease.
What You Will Learn
- Install Groovy and create Groovy projects in the IDE
- Explore the Groovy toolset and use the Groovy console to execute Groovy code
- Learn common Groovy operators that form the cornerstone of its powerful syntax
- Use regular expressions and capture groups to parse and extract strings
- Look at Groovy collections and the enhancements delivered by the GDK
- Learn how to iterate and search through collections in Groovy
This course is best suited for the beginner- to intermediate-level Java developers who want to accelerate their existing Java coding tasks using Groovy.
Interested developers in other programming languages who want to write programs that can execute on the Java Virtual Machine, without having to use Java will also find this course useful.
Working knowledge of the Java programming language is assumed as a prerequisite, although the course can be used without this knowledge (but it will make more sense and be easier for a Java developer to understand).
About The Author
Matthew Speake: Matthew Speake is a Java technologist and trainer. He has over 20 years of experience working everywhere from small start-ups to large global corporations and is the principal trainer at Zention in the UK.
He started JavaEasily in 2018 to produce courses focused on teaching Java technology to students all around the world. Since then, JavaEasily has been busy creating and publishing courses and articles on different aspects of Java to help beginners and intermediate Java developers enhance their skills. JavaEasily helps you become a better Java developer by teaching you the core skills you need in order to succeed in your Java career.
Table of contents
- Chapter 1 : Getting Set Up
- Chapter 2 : Groovy Operators
- Chapter 3 : Groovy Strings
Chapter 4 : Collections in Groovy
- Section Introduction
- Creating Lists and Sets
- Creating Maps
- Composing Collections of Different Types
- Accessing Elements of a List
- Using Groovy Truthiness with Collections
- Creating and Accessing Composite Collections
- Processing Lists and Sets
- Processing Lists and Sets by Index
- Processing Maps by Key and Value
- Filtering Collections
- Finding the Matching Element in a Collection
- Testing Elements in Collections
- Collecting Elements to a List
- Collecting Entries to a Map
- Creating Aggregate Functions with Inject
Chapter 5 : Groovy Language Features
- Section Introduction
- Default Imports and Classes
- Main Methods in Groovy Applications
- Creating Classes and Instances in Groovy
- Adding methods and state to Groovy Classes
- Using Inheritance in Groovy
- Overriding Methods in Groovy
- POGOs and Groovy Property Generation
- Operator Overloading
- String Equality in Groovy
- Returning Multiple Values from a Method
- Autogenerating Equals and HashCode with Groovy AST Transformations
- Named Constructors
- Chapter 6 : Wrapping Up
- Title: Groovy Programming Fundamentals for Java Developers
- Release date: April 2021
- Publisher(s): Packt Publishing
- ISBN: 9781801074063
You might also like
Build a CI/CD Pipeline
Approximately 8 Hours of Video Instruction If your development team is still dealing with manual and …
SSL Complete Guide 2021: HTTP to HTTPS
This course is all about securing websites with SSL/TLS certificates. We start by exploring the basics …
The Complete Practical Docker Guide
Docker is a software framework for building, running, and managing containers on servers and the cloud. …
Full Stack Web Development Mastery Course - Novice to Expert
Full stack development refers to the development of both frontend (client-side) and backend (server-side) portions of …