I have a data class in my application. My application will never be used as a public API and I will be the only person developing code within my project.
I am trying to save every ounce of processor and memory power I can.
Is it a bad idea to make my data members in my data class to have public/protected/default protection so that I don't have to use a getter? Using a getter would require slightly more memory and creation of a stack and such...which I believe isn't necessary. The only reason I can see in using a getter is for protection/privacy, but if I'm the only coder and nobody else is going to be using my API, then is it a bad idea not to use the getters?
Please let me know if this is stupid.