Updated documentation with @throws