-
Notifications
You must be signed in to change notification settings - Fork 5
Style Guideline
Jose Jimenez edited this page Jan 25, 2021
·
23 revisions
/**
*
* Jose Jimenez
* Brandon Cramer
*
* University of California, San Diego
* IEEE Micromouse Team 2020
*
* File Name: <Name>
* Description: <Short Description>
*/
Routine Headers will be in parallel with the Javadocs. Every header should have a short description of its role, a short description for all formal parameters, and what the function expects to return. An example is as follows:
/**
* Two pairs are equal if the content in the pair are equivalent order does
* not matter.
* @param o object of comparison.
* @return true if pairs have the same content.
*/
@Override
public boolean equals( Object o ) {
...
}
Two space indentation. (NOT tabs)
Use the following format:
if( condition ) {
/* <comment> */
...
}
For consistency make sure to leave whitespace on conditional clauses in between the parenthesis. Example:
if( condition ) {
...
}
Nested parenthesis clauses do not have to follow this rule. Example: this is ok
if( foo(a, b) ) {
...
}
The recommended maximum number of characters on a line is 81.
Welcome to the black box of every Micromouse