Documentation ¶
Index ¶
- func AuthHelper(redirectPath string, redirectPort int, conf *Config) error
- func RefreshAccessToken(conf *Config) (*oauth2.Token, error)
- func SaveToken(path string, token *oauth2.Token) error
- type Config
- type DriveClient
- func (c *DriveClient) CreateFile(filename, parentFolderID string, r io.Reader, modTime time.Time) (string, error)
- func (c *DriveClient) GetAndCreateFileIDIfNotExist(filename, parentFolderID string, r io.Reader, modTime time.Time) (bool, string, error)
- func (c *DriveClient) GetFile(fileID string) (io.ReadCloser, error)
- func (c *DriveClient) GetFileID(filename, parentFolderID string) (string, string, error)
- func (c *DriveClient) ListFiles(folderID string) ([]*types.DirInfo, []*types.FileInfo, error)
- func (c *DriveClient) UpdateFileMetadata(fileID string, metadata map[string]string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DriveClient ¶
type DriveClient struct {
// contains filtered or unexported fields
}
func CreateDriveClient ¶
func CreateDriveClient(conf *Config) (*DriveClient, error)
func (*DriveClient) CreateFile ¶
func (*DriveClient) GetAndCreateFileIDIfNotExist ¶
func (*DriveClient) GetFile ¶
func (c *DriveClient) GetFile(fileID string) (io.ReadCloser, error)
func (*DriveClient) GetFileID ¶
func (c *DriveClient) GetFileID(filename, parentFolderID string) (string, string, error)
func (*DriveClient) UpdateFileMetadata ¶
func (c *DriveClient) UpdateFileMetadata(fileID string, metadata map[string]string) error
Click to show internal directories.
Click to hide internal directories.