Adjusted visibility of various components.

Also added some documentation.