code: func NewRESTClient(baseURL *url.URL, versionedAPIPath string, config ContentConfig, maxQPS float32, maxBurst int, client *http.Client) *RESTClient {
  	base := *baseURL
  	if !strings.HasSuffix(base.Path, "/") {
  		base.Path += "/"
  	}
  	base.RawQuery = ""
  	base.Fragment = ""
  
  	if config.GroupVersion == nil {
  		config.GroupVersion = &unversioned.GroupVersion{}
  	}
  	if len(config.ContentType) == 0 {
  		config.ContentType = "application/json"
  	}
  
  	var throttle util.RateLimiter
  	if maxQPS > 0 {
  		throttle = util.NewTokenBucketRateLimiter(maxQPS, maxBurst)
  	}
  	return &RESTClient{
  		base:             &base,
  		versionedAPIPath: versionedAPIPath,
  		contentConfig:    config,
  		Throttle:         throttle,
  		Client:           client,
  	}
  }
docs: // NewRESTClient creates a new RESTClient. This client performs generic REST functions
  // such as Get, Put, Post, and Delete on specified paths.  Codec controls encoding and
  // decoding of responses from the server.