1

Hi is there any plugin for IntelliJ, which can generate getter/setter, hashcode/equals, toString in one click?

nusmanov
  • 451
  • 4
  • 15
  • Possible duplicate of [Generate getter/setter, hashcode/equals, toString in one template in Intellij](https://stackoverflow.com/questions/30490265/generate-getter-setter-hashcode-equals-tostring-in-one-template-in-intellij) – Mykola Yashchenko Oct 10 '17 at 08:14
  • I use CMD+N (on mac) for showing generate menu where i can choose what to generate. See in Preferences and search for short cuts if this is is what you're looking for – hasan Oct 10 '17 at 08:28

2 Answers2

1

Why do you want one click?

You have the keybinding alt+insert and 'Getter/Setters' in the popup menu.

But, if you want an automatic setters and getters generation, you have the @data annotation on bean class from Lombok.

  • In some projects phrase you need several value object classes. Lombok is because of readbility and usability not an option in my case. – nusmanov Oct 19 '17 at 13:27
1

Found a plugin Generatable (Kirill Korgov): "Generate All: getters, equals and hashCode, toString, Constructor, Builder"

nusmanov
  • 451
  • 4
  • 15