aboutsummaryrefslogtreecommitdiffstats
path: root/drive/types.go
diff options
context:
space:
mode:
authorPetter Rasmussen2016-01-17 21:13:46 +0100
committerPetter Rasmussen2016-01-17 21:13:46 +0100
commitf35fd0892688ff638b30dcd48fdd56b9e2627cf1 (patch)
tree18439804fdb5c87e4ba0f4cea4561db35bdd7868 /drive/types.go
parentf16b89b6f6bee6023c51b4f8120a3e4776128384 (diff)
downloadgdrive-f35fd0892688ff638b30dcd48fdd56b9e2627cf1.tar.bz2
One file per command
Diffstat (limited to 'drive/types.go')
-rw-r--r--drive/types.go90
1 files changed, 0 insertions, 90 deletions
diff --git a/drive/types.go b/drive/types.go
deleted file mode 100644
index f252dde..0000000
--- a/drive/types.go
+++ /dev/null
@@ -1,90 +0,0 @@
-package drive
-
-import (
- "net/http"
- "google.golang.org/api/drive/v3"
-)
-
-type Client interface {
- Service() *drive.Service
- Http() *http.Client
-}
-
-type Drive struct {
- service *drive.Service
- http *http.Client
-}
-
-func NewDrive(client Client) *Drive {
- return &Drive{
- service: client.Service(),
- http: client.Http(),
- }
-}
-
-type ListFilesArgs struct {
- MaxFiles int64
- NameWidth int64
- Query string
- SkipHeader bool
- SizeInBytes bool
-}
-
-type DownloadFileArgs struct {
- Id string
- Force bool
- NoProgress bool
- Stdout bool
-}
-
-type UploadFileArgs struct {
- Path string
- Name string
- Parent string
- Mime string
- Recursive bool
- Stdin bool
- Share bool
-}
-
-type FileInfoArgs struct {
- Id string
- SizeInBytes bool
-}
-
-type MkdirArgs struct {
- Name string
- Parent string
- Share bool
-}
-
-type ShareArgs struct {
- FileId string
- Role string
- Type string
- Email string
- Discoverable bool
- Revoke bool
-}
-
-type PrintFileListArgs struct {
- Files []*drive.File
- NameWidth int
- SkipHeader bool
- SizeInBytes bool
-}
-
-type PrintFileInfoArgs struct {
- File *drive.File
- SizeInBytes bool
-}
-
-type kv [2]string
-
-func (self kv) key() string {
- return self[0]
-}
-
-func (self kv) value() string {
- return self[1]
-}