Jindent - Java Source Code Formatter http://www.jindent.com
 



title
5.6.1.7.3 Braces

Padding braces of initializers

Padding braces of initializers

Controls whether white spaces are inserted after left and before right braces or not.


Use padding:

enum·Nummer·{·EINS(1),·ZWEI(2),·DREI(3),·VIER(4)·}
                                        
int[]·intArray={·1,·2,·3·}              


Do not use padding:

enum·Nummer·{EINS(1),·ZWEI(2),·DREI(3),·VIER(4)}
                                        
int[]·intArray={1,·2,·3}                



No padding of empty braces in initializers

No padding of empty braces in initializers

Controls whether white spaces are inserted between empty braces or not.


We assume the settings "Padding braces of initializers" is in use and padding of empty braces is allowed:

int·[]·intArray·=·{·};                  


The same example as above, but now we do not allow padding of empty braces:

int·[]·intArray·=·{};                   



Space before left braces of array initializers

Space before left braces of array initializers

Controls whether a white space is inserted before left brackets in types or not.


Insert a white space before:

int·intArray·[];                        


Do not insert a white space before:

int·intArray[];