updated documentation

NOW function documentation in Javadoc style