|
|
|
|
|
by zek
4504 days ago
|
|
you have to get used to get go's backwards type declaration. This is defining a method on h which is a byteHandler struct called serve which takes a http.ResponseWriter and Request and returns nothing. This is from the http.Handler interface, so defining this method causes byteHandler to conform to the http.Handler interface. |
|
There is no struct involved here and there doesn't need to be which is nice.