Sep 29, 2024
90 Views
Comments Off on Apex Intention Actions: The Next Frontier for Apex Completions
0 0

Apex Intention Actions: The Next Frontier for Apex Completions

Written by

Idea from IDEa

Recently, I needed to code a little tool in Java. The last time I coded something in Java was in high school, so it was a nice exercise for me to dust off my Java and get back up to speed on learning some new stuff, too. I used IntelliJ IDEa this time and found their so-called “intention actions” or “bulb actions” quite helpful. After coming back to developing in Salesforce I really missed some of them, because they really sped up my work. This lead me to take a look at Sublime’s Package Control, and when I found nothing similar there, I decided that maybe I’m not the only one who’d like to have those.

What are my intentions?

I thought – which actions do I do most often, and hence are good candidates for automation? I came up with this list:

– Add getter

– Add setter

– Add both getter and setter

– Add constructor parameter

– Add class constructor

– Add init method and call in each constructor

– Add 0-arg constructor and init method

– Add method overload

These are basic actions that you can do quickly with “Apex Intention Actions”.

How this works

The plugin analyses the first string you have your cursor on and suggests actions you can do quickly with it. It’s not automatic, so you need to call the plugin by tapping a hotkey.

You can also use hotkeys for all of the actions.

Future

The plugin is maintained, though I plan to migrate to VS Code for Salesforce development. So, soon Apex intention Actions will run on VS Code! 🙂

The project also has a wiki ( https://github.com/nchursin/ApexIntentionActions/wiki ), so you can find more info there.

Try it yourself – https://packagecontrol.io/packages/Apex%20Intention%20Actions

Article Categories:
Salesforce
https://thestarbiznews.com/

Expertise: Global Macroeconomics, Business Strategy, Emerging Markets Bio: Rajeev Sharma is a seasoned investment strategist with over two decades of experience navigating the ever-evolving global market landscape. A veteran of Wall Street and a sought-after advisor to Fortune 500 companies, Rajeev brings a wealth of knowledge and expertise to TheStarBizNews. His insightful analyses of global economic trends, coupled with his keen understanding of regional specificities, provide invaluable guidance for businesses and investors alike. Fluent in four languages and a frequent speaker at international conferences, Rajeev brings a cosmopolitan flair to his writing, drawing connections between seemingly disparate events to paint a clear picture of the interconnected world we live in.