Added JavaDocs and fixed tab sizes.