added code-level documentation