Make Registry public

This change set exports a Registry interface implemented by the local
registry type. I added TODO comments along the way with improvements
that could be done to reduce the surface area of a Registry's behaviour
and to make the code more orthogonal overall. I'd be glad to contribute
these changes over time, if you like the direction I propose.

This has been done on top of the `standard-exports` branch.

All tests pass except for the Linux specifc `/proc` related tests. I
suggest that we add linux specific build tags to those files.
Nope. That's an oversight.

On Mon, Dec 15, 2014, 16:55 juliusv <notifications@github.com> wrote:

> In prometheus/registry.go
> <https://github.com/prometheus/client_golang/pull/38#discussion-diff-21834093>
> :
>
> > @@ -86,11 +89,157 @@ const (
> >  	acceptHeader         = "Accept"
> >  )
> >
> > +// Registry defines an interface for registering and unregistering Collectors.
> > +type Registry interface {
> > +	// Handler returns the HTTP handler for the global Prometheus registry. It is
>
> Should this still say "for the global Prometheus registry", given that
> there can now be multiple registries (haven't read everything yet)?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/prometheus/client_golang/pull/38/files#r21834093>.
>