Is there a way in IntelliJ Idea to force this. to be automatically placed into code on a format or save or at the very least show an error if it should be in there?
In new versions of IntelliJ when committing code or selecting a warning you can choose the option Cleanup, which will add this. to the member variables in your code.