Alright, I'm relatively new to Java, and looking for help making writing lengthy code faster.
I need to initialize a few hundred objects with different parameters in my main method, and no, they can't be made with a loop, they're irregular.
Is there a way to do something like
addPrefix"xxLongStupidNameHerexx.addobject.{
new thing(a,b,c);
new thing(p,l,o);
new thing(p,l,o);
}
and have the compiler read the code as
xxLongStupidNameHerexx.addobject(new thing(a,b,c));
xxLongStupidNameHerexx.addobject(new thing(a,c,x));
xxLongStupidNameHerexx.addobject(new thing(p,l,o));
Basically I want to avoid writing the same starting bit for a lot of code that can't be made with a loop. I know I've seen this done before in other people's work, but I can't find it on bae stackoverflow or google.