Debugging. Added javadoc style documentation.