Wrote class docstrings.

MILESTONE: all classes now carry a docstring.