-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Cleaned DashboardLogic commenting - Refactored all variables for AuroraCoreUI - Removed unnecessarily commented stuff in AuroraCoreUI - Added some comments to varibles of AuroraCoreUI - Added CONTRIBUTING markup doc for coding style documentation
- Loading branch information
1 parent
132312b
commit ffb3c3d
Showing
4 changed files
with
515 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
# Official Aurora Coding Style Guide | ||
|
||
This style of coding applies to all Aurora Engine based Java applications. <br> | ||
This is currently a draft being put together for the first time. | ||
|
||
|
||
*** | ||
|
||
## 1. Top of Class commenting: | ||
|
||
* *Title* is the **Name of the Class** | ||
* *Description* of the entire class, what it does, how it interacts with other classes etc. | ||
* Below *dotted lines* add **name of contributors** to project. | ||
|
||
/** | ||
* .------------------------------------------------------------------------. | ||
* | DashboardLogic | ||
* .------------------------------------------------------------------------. | ||
* | | ||
* | | ||
* | This Class is the Logic component of the Dashboard Screen. Its instanced | ||
* | In DashboardUI. | ||
* | | ||
* | This class is supposed to handle all of the Long Processing of UI or | ||
* | Actions generated by the Handler. Reusable processing and long logic | ||
* | methods should go here. | ||
* | | ||
* ......................................................................... | ||
* | ||
* @author Sammy Guergachi <sguergachi at gmail.com> | ||
* | ||
*/ | ||
|
||
## 2. Commenting Class Variables | ||
|
||
Make a multiline comment above each variable decleration <br> | ||
Just one simple sentence explaining what the variable is used for. <br> | ||
**Note**: Only **1** space in between each variable and the attached comment. | ||
|
||
/** | ||
* Size Constant. | ||
*/ | ||
private int infoFeedHeight; | ||
|
||
/** | ||
* Size Constant. | ||
*/ | ||
private int bottomPaneHeightAdjust; | ||
|
||
/** | ||
* Size Constant. | ||
*/ | ||
private int topPaneHeighAdjust; | ||
|
||
/** | ||
* Size Constant. | ||
*/ | ||
private int topHeight; | ||
|
||
|
||
## 3. Constructors | ||
|
||
* *Title* is **Class name** with parameter **Type** in paranthesis | ||
* *Description* includes what parameters are needed and what the constructor initializes | ||
* Bellow *dotted lines* add the **parameter** name and Type | ||
|
||
|
||
/** | ||
* .-----------------------------------------------------------------------. | ||
* | DashboardLogic(DashboardUI) | ||
* .-----------------------------------------------------------------------. | ||
* | | ||
* | This is the Constructor of the Dashboard Logic class. | ||
* | | ||
* | The DashboardUI is required to make adjustments to the UI from the | ||
* | logic. | ||
* | The storage will be extracted from DashboardUI and initialized | ||
* | here. | ||
* | CoreUI will also be internally initialized here and extracted | ||
* | from DashboardUI. | ||
* | | ||
* | NOTE: for Logic to work you must use the set(HandlerDashboardHandler) | ||
* | method for the logic to be able to attach some handlers to UI | ||
* | elements | ||
* ......................................................................... | ||
* | ||
* @param dashboardUi DashboardUI | ||
* | ||
*/ | ||
|
||
## 4. Inline commenting | ||
|
||
For imporant comments regarding code behaviour use | ||
|
||
/* Code Comment Here */ | ||
|
||
For unimportant side notes use | ||
|
||
// Not important code here | ||
|
||
|
||
## 5. Code Segmenting | ||
|
||
To split code visually into sections use the following method.<br> | ||
|
||
**Note**: must be cappital, must have 3 bars at the end, not 2 not 4. <br> | ||
**Note**: must be **2** blank line after each section and at least **1** inbetween each section seperator | ||
|
||
//----------------------------SECTION NAME--------------------------------// | ||
|
||
/* Start typing code here */ | ||
|
||
//---------------------------------|||------------------------------------// | ||
|
||
|
||
//---------------------------SECTION 2 NAME-------------------------------// | ||
/* Etc. */ | ||
|
||
//---------------------------------|||------------------------------------// | ||
|
||
|
Oops, something went wrong.