Category Archives: Java

Beauty of Coding Standards

Elements of Java Style was an interesting book to read.  The book lists code styling conventions for Java and it should be a must-have for any programmers.  It contains 108 style rules to follow, which makes your code look standardized and easier to follow for external developers.  This book would be really help to start someone off in Java, not requiring new learners to adjust their coding style.

This week’s practice WOD (workout of the day) involved Scribble, repository found in GitHub, where we had to correct any styling errors.  For the software engineering class I am currently taking, we followed 108 rules found in Elements of Java Style and additional 19 rules used for this particular class.  We were given a custom checkstyle.xml which we used for CheckStyle in IntelliJ.  We did a similar practice WOD in class, so I was able to correct all errors within 17 minutes.  This time could be reduced if I could find a way to set the custom rules as default for the CheckStyle in IntelliJ.

I personally think this athletic software engineering approach is allowing me to quickly obtain skill sets introduced and master it in relatively quick pace.  And the fact that there is a time pressure allows me to work quickly, driving me to improve my results wherever I can.

Honestly, it will take me some time to memorize all the style rules for Java.  Without the custom rules provided in xml file, I wouldn’t have been able to finish the WOD in 17 minutes.  Maybe one day (very soon, hopefully) I will be able to write a code with 0 styling error.

Experiencing the Three Prime Directives of Software Engineering

Overview

is an open source Android library that provides developers the ability to easily create application sliding menu like the one found across Android applications published by Google.  This library is free to use for either commercial or private use given that the project is cited and license is included in the application.

Prime Directive #1: The system successfully accomplishes a useful task

The SlidingMenu satisfies the first prime directive of the software engineering.  This Android library allows developers to create sliding menus, inspired by applications such as Facebook and YouTube.  Sliding menu is intuitive in a user experience sense that end-users do not have to scroll the entire application to look for options they are seeking for.  Some of the popular Android applications such as Linkedin, 9GAG, Foursquare, and Rdio utilizes this library for their services.  Therefore, the first prime directive is satisfied.

Prime Directive #2: An external user can successfully install and use the system

Installation instruction can be found in README.  All that is needed is to import the SlidingMenu library then add it to project as one of the dependencies.  The README file also provides instructions on how to integrate into an existing project easily.  Therefore, the second prime directive is satisfied.

Image from SlidingMenu DemosPrime Directive #3: An external developer can successfully understand and enhance the system

The library does not contain extensive documentation to provide explanation for other developers to easily contribute to the project.  Only form of explanation of code was done through the comments within the code.  However, the project can be forked allowing other developers to enhance it for their own purposes.  As a result, the third prime directive is conditionally satisfied because external developers can successfully understand and enhance the project but with no documentation to aid the process.