added javadoc

writing works 99% of the time depending on the server