readd encode-object/encode-slots API with proper documentation

A previous commit removed these generic functions from the API
because of a lack of proper documentation.
We readd them with better documentation, achieved in particular
through the addition of an example showing their use.

Breaking change: ENCODE-SLOTS now has method combination PROGN
as the previous version claimed but did not implement.