Fixed some signatures.
Added JavaDoc.