2
2
mirror of https://github.com/octoleo/restic.git synced 2024-12-02 18:08:28 +00:00
restic/vendor/google.golang.org/api/ml/v1beta1/ml-gen.go

66 lines
1.4 KiB
Go
Raw Normal View History

2017-09-13 12:09:48 +00:00
// Package ml provides access to the .
2017-08-05 18:17:15 +00:00
//
// Usage example:
//
// import "google.golang.org/api/ml/v1beta1"
// ...
// mlService, err := ml.New(oauthHttpClient)
package ml // import "google.golang.org/api/ml/v1beta1"
import (
"bytes"
"encoding/json"
"errors"
"fmt"
context "golang.org/x/net/context"
ctxhttp "golang.org/x/net/context/ctxhttp"
gensupport "google.golang.org/api/gensupport"
googleapi "google.golang.org/api/googleapi"
"io"
"net/http"
"net/url"
"strconv"
"strings"
)
// Always reference these packages, just in case the auto-generated code
// below doesn't.
var _ = bytes.NewBuffer
var _ = strconv.Itoa
var _ = fmt.Sprintf
var _ = json.NewDecoder
var _ = io.Copy
var _ = url.Parse
var _ = gensupport.MarshalJSON
var _ = googleapi.Version
var _ = errors.New
var _ = strings.Replace
var _ = context.Canceled
var _ = ctxhttp.Do
2017-09-13 12:09:48 +00:00
const apiId = ""
const apiName = ""
const apiVersion = ""
const basePath = "https://www.googleapis.com/discovery/v1/apis"
2017-08-05 18:17:15 +00:00
func New(client *http.Client) (*Service, error) {
if client == nil {
return nil, errors.New("client is nil")
}
s := &Service{client: client, BasePath: basePath}
return s, nil
}
type Service struct {
client *http.Client
BasePath string // API endpoint base URL
UserAgent string // optional additional User-Agent fragment
}
func (s *Service) userAgent() string {
if s.UserAgent == "" {
return googleapi.UserAgent
}
return googleapi.UserAgent + " " + s.UserAgent
}