code: func (encoder *HTTPEncoder) Register(f EncoderFunc, contentTypes ...string) {
  	p := newEncodePool(f)
  	for _, contentType := range contentTypes {
  		mediaType, _, err := mime.ParseMediaType(contentType)
  		if err != nil {
  			mediaType = contentType
  		}
  		encoder.pools[mediaType] = p
  	}
  
  	// Rebuild a unique index of registered content encoders to be used in EncodeResponse
  	encoder.contentTypes = make([]string, 0, len(encoder.pools))
  	for contentType := range encoder.pools {
  		encoder.contentTypes = append(encoder.contentTypes, contentType)
  	}
  }
docs: // Register sets a specific encoder to be used for the specified content types. If an encoder is
  // already registered, it is overwritten.