Did you notice anything unusual? And this [show the rest of the catalog entity classes]
Yes, you’re right, we didn’t create any getter or setter, we don’t have any equals or hashcode methods as well.
But take a look at this, expand the Eclipse Outline view. [show the class outline]
Why do we have a no-arg constructor and getters and setters here? [open businessEntity class] here as well. That is the power of Lombok. It’s a Java library that we can plug into our Spring tool suite editor. And it does a number of things like providing an automatic getter and seller methods. toString, no-arg constructor, and more.
For a full list of features go to https://projectlombok.org/features/all
How to install the plugin? Download the jar from Lombok, execute and select your IDE. Instruction can be found here: https://projectlombok.org/setup/eclipse.
I hope this plugin helps you as much as it did to me.
- Database Initialization Using Script
Slack Discussion Repositories https://github.com/terawarehouse/terawarehouse-cataloghttps://github.com/terawarehouse/terawarehouse-reactThere are times when we want to use a SQL script to generate the schema and populate the database. Personally, I use...
- Working With Spring Data Repositories
Slack Discussion Repositories https://github.com/terawarehouse/terawarehouse-cataloghttps://github.com/terawarehouse/terawarehouse-reactJust like what we did with the entities the same approach can be used when creating the repository classes. And that...
- Database Modelling And Tools
Slack Discussion Repositories https://github.com/terawarehouse/terawarehouse-cataloghttps://github.com/terawarehouse/terawarehouse-reactIn this part, we will discuss the tools that we can use in designing our database. We will also create a database schema...
- Create A Restful Web Service In Spring
Slack Discussion Repositories https://github.com/terawarehouse/terawarehouse-cataloghttps://github.com/terawarehouse/terawarehouse-reactTo prepare the project from future development, we will be creating a multi-maven project layout. Unfortunately,...
- Spring Development Environment
Slack Discussion Repositories https://github.com/terawarehouse/terawarehouse-cataloghttps://github.com/terawarehouse/terawarehouse-reactBefore we can begin coding, we must first download and configure Spring Tools 4, which is the latest available Spring...