Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Resources for Java coding style?

I find reading coding style guidelines to be the best way to get to know a language and its peculiarities. I've been trying to find a good document for Java, and get some questions answered immediately.

Firstly, what is the convention for very long lines? Writing in both Java and C/C++ leads me to have a great deal of confusion on this point.

Secondly, what is the guideline for creating custom exception classes? I typically end up throwing an existing exception rather than creating my own. Is custom exception creation typically enforced?

like image 402
alexgolec Avatar asked Dec 09 '22 11:12

alexgolec


1 Answers

Take a look at the official Code Conventions for the Java TM Programming Language.

like image 92
João Silva Avatar answered Dec 26 '22 09:12

João Silva