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



title
5.6.1.10.3 Parameter Declarations

Align parameter declarations

Align parameter declarations

Controls whether parameter declarations are aligned within one source code chunk or not.
Please note: This feature is only available if parameter's line wrapping settings are set to always.

Align parameter declarations:

void calculate(                         
    
int    value1,                      
    
int    value2,                      
    
String message                      
) {                                     
    
// ...                              
}                                       


Do not align parameter declarations:

void calculate(                         
    
int value1,                         
    
int value2,                         
    
String message                      
) {                                     
    
// ...                              
}                                       

See also... See also: Jindent - Settings - Formatter - Java / SQLJ - Alignments - Chunks




Align parameter declarations exceeding max. line length

Align parameter declarations exceeding max. line length

Controls whether parameter delcarations which exceed maximal line length are aligned with other declarations or not.


Align exceeding parameter declarations:

void calculate(                                             |
    
int    value1,                                          |
    
int    value2,                                          |
    
String message   // some very long comment which exceeds maximal line length
) {                                                         |
    
// ...                                                  |
}                                                           |

Even if declaration of parameter message exceeds the specified maximal line length it will be aligned.


Do not align exceeding parameter declarations:

void calculate(                                             |
    
int   value1,                                           |
    
int   value2,                                           |
    
String message   // some very long comment which exceeds maximal line length
) {                                                         |
    
// ...                                                  |
}                                                           |

Declaration of field message exceeds the specified maximal line length. Therefore it will be not aligned.



Indent parameter declarations by tab stops

Indent parameter declarations by tab stops

Controls whether parameter declarations are indented by spaces or tabulator stops.


Indent declarations by tabulator stops:

void calculate(                         
    
int>--->value1,                     
    
int  -->value2,                     
    
String->message                     
) {                                     
    
// ...                              
}                                       


Do not indent parameter declarations by tabulator stops, rather use white spaces:

void·calculate(                         
····int····value1,                      
····int····value2,                      
····String·message                      
)
·{                                     
····//·...··                            
}····