Re: [go-nuts] Re: is there a way to mirror a standard package while adding some functions to it?

2017-01-27 Thread Matt S
This definitely doesn't require you to modify net/http directly. Just create a library with custom handler types that satisfy the http.Handler interface. Many existing Go routing libraries & frameworks will get you 90% of the way there. On Fri, Jan 27, 2017 at 7:42 PM Marwan abdel moneim wrote:

Re: [go-nuts] Re: is there a way to mirror a standard package while adding some functions to it?

2017-01-27 Thread Matt S
This definitely doesn't require you to modify net/http directly. Just create a library with custom handler types that satisfy the http.Handler interface. Many existing Go routing libraries & frameworks will get you 90% of the way there. On Fri, Jan 27, 2017 at 7:42 PM Marwan abdel moneim wrote:

Re: [go-nuts] Re: is there a way to mirror a standard package while adding some functions to it?

2017-01-27 Thread Matt S
Which functions? What are you actually changing? A wrapper library doesn't have to wrap all the functions: just wrap the ones you need to and make it a small, composable library. On Fri, Jan 27, 2017 at 7:12 PM Marwan abdel moneim wrote: > do your changes require you to modify the package? >