added java doc comments for methods