My favorites | Sign in
Google
                
Search
for
Updated Jun 26, 2009 by dswit...@gmail.com
CodingStyle  
How to write code that matches our style (please read)

The ZXing Coding Style

The ZXing project mostly adheres to Java coding style, with a few changes:

To be compatible with J2ME, everything in the core library must be written to Java 1.2. Please use Javadoc-style comments on all public methods.

Conventions

In addition, we have some requirements to make it easier for authors to understand each other's code.

2D coordinates

Please observe the following:

for (int y = 0; y < height; y++) {
  for (int x = 0; x < width; x++) {
    bitmap.get(x, y);
  }
}

Do not use i and j as loop counters or method parameters when dealing with images.

Performance

Because ZXing is primarily targeted at mobile applications:


Sign in to add a comment