Documentation ¶
Overview ¶
Package drive provides access to the Drive API.
See https://developers.google.com/drive/
Usage example:
import "google.golang.org/api/drive/v3" ... driveService, err := drive.New(oauthHttpClient)
Index ¶
- Constants
- type About
- type AboutGetCall
- func (c *AboutGetCall) Context(ctx context.Context) *AboutGetCall
- func (c *AboutGetCall) Do() (*About, error)
- func (c *AboutGetCall) Fields(s ...googleapi.Field) *AboutGetCall
- func (c *AboutGetCall) IfNoneMatch(entityTag string) *AboutGetCall
- func (c *AboutGetCall) QuotaUser(quotaUser string) *AboutGetCall
- func (c *AboutGetCall) UserIP(userIP string) *AboutGetCall
- type AboutService
- type AboutStorageQuota
- type Change
- type ChangeList
- type ChangesGetStartPageTokenCall
- func (c *ChangesGetStartPageTokenCall) Context(ctx context.Context) *ChangesGetStartPageTokenCall
- func (c *ChangesGetStartPageTokenCall) Do() (*StartPageToken, error)
- func (c *ChangesGetStartPageTokenCall) Fields(s ...googleapi.Field) *ChangesGetStartPageTokenCall
- func (c *ChangesGetStartPageTokenCall) IfNoneMatch(entityTag string) *ChangesGetStartPageTokenCall
- func (c *ChangesGetStartPageTokenCall) QuotaUser(quotaUser string) *ChangesGetStartPageTokenCall
- func (c *ChangesGetStartPageTokenCall) UserIP(userIP string) *ChangesGetStartPageTokenCall
- type ChangesListCall
- func (c *ChangesListCall) Context(ctx context.Context) *ChangesListCall
- func (c *ChangesListCall) Do() (*ChangeList, error)
- func (c *ChangesListCall) Fields(s ...googleapi.Field) *ChangesListCall
- func (c *ChangesListCall) IfNoneMatch(entityTag string) *ChangesListCall
- func (c *ChangesListCall) IncludeRemoved(includeRemoved bool) *ChangesListCall
- func (c *ChangesListCall) PageSize(pageSize int64) *ChangesListCall
- func (c *ChangesListCall) QuotaUser(quotaUser string) *ChangesListCall
- func (c *ChangesListCall) RestrictToMyDrive(restrictToMyDrive bool) *ChangesListCall
- func (c *ChangesListCall) Spaces(spaces string) *ChangesListCall
- func (c *ChangesListCall) UserIP(userIP string) *ChangesListCall
- type ChangesService
- type ChangesWatchCall
- func (c *ChangesWatchCall) Context(ctx context.Context) *ChangesWatchCall
- func (c *ChangesWatchCall) Do() (*Channel, error)
- func (c *ChangesWatchCall) Fields(s ...googleapi.Field) *ChangesWatchCall
- func (c *ChangesWatchCall) IncludeRemoved(includeRemoved bool) *ChangesWatchCall
- func (c *ChangesWatchCall) PageSize(pageSize int64) *ChangesWatchCall
- func (c *ChangesWatchCall) QuotaUser(quotaUser string) *ChangesWatchCall
- func (c *ChangesWatchCall) RestrictToMyDrive(restrictToMyDrive bool) *ChangesWatchCall
- func (c *ChangesWatchCall) Spaces(spaces string) *ChangesWatchCall
- func (c *ChangesWatchCall) UserIP(userIP string) *ChangesWatchCall
- type Channel
- type ChannelsService
- type ChannelsStopCall
- func (c *ChannelsStopCall) Context(ctx context.Context) *ChannelsStopCall
- func (c *ChannelsStopCall) Do() error
- func (c *ChannelsStopCall) Fields(s ...googleapi.Field) *ChannelsStopCall
- func (c *ChannelsStopCall) QuotaUser(quotaUser string) *ChannelsStopCall
- func (c *ChannelsStopCall) UserIP(userIP string) *ChannelsStopCall
- type Comment
- type CommentList
- type CommentQuotedFileContent
- type CommentsCreateCall
- func (c *CommentsCreateCall) Context(ctx context.Context) *CommentsCreateCall
- func (c *CommentsCreateCall) Do() (*Comment, error)
- func (c *CommentsCreateCall) Fields(s ...googleapi.Field) *CommentsCreateCall
- func (c *CommentsCreateCall) QuotaUser(quotaUser string) *CommentsCreateCall
- func (c *CommentsCreateCall) UserIP(userIP string) *CommentsCreateCall
- type CommentsDeleteCall
- func (c *CommentsDeleteCall) Context(ctx context.Context) *CommentsDeleteCall
- func (c *CommentsDeleteCall) Do() error
- func (c *CommentsDeleteCall) Fields(s ...googleapi.Field) *CommentsDeleteCall
- func (c *CommentsDeleteCall) QuotaUser(quotaUser string) *CommentsDeleteCall
- func (c *CommentsDeleteCall) UserIP(userIP string) *CommentsDeleteCall
- type CommentsGetCall
- func (c *CommentsGetCall) Context(ctx context.Context) *CommentsGetCall
- func (c *CommentsGetCall) Do() (*Comment, error)
- func (c *CommentsGetCall) Fields(s ...googleapi.Field) *CommentsGetCall
- func (c *CommentsGetCall) IfNoneMatch(entityTag string) *CommentsGetCall
- func (c *CommentsGetCall) IncludeDeleted(includeDeleted bool) *CommentsGetCall
- func (c *CommentsGetCall) QuotaUser(quotaUser string) *CommentsGetCall
- func (c *CommentsGetCall) UserIP(userIP string) *CommentsGetCall
- type CommentsListCall
- func (c *CommentsListCall) Context(ctx context.Context) *CommentsListCall
- func (c *CommentsListCall) Do() (*CommentList, error)
- func (c *CommentsListCall) Fields(s ...googleapi.Field) *CommentsListCall
- func (c *CommentsListCall) IfNoneMatch(entityTag string) *CommentsListCall
- func (c *CommentsListCall) IncludeDeleted(includeDeleted bool) *CommentsListCall
- func (c *CommentsListCall) PageSize(pageSize int64) *CommentsListCall
- func (c *CommentsListCall) PageToken(pageToken string) *CommentsListCall
- func (c *CommentsListCall) QuotaUser(quotaUser string) *CommentsListCall
- func (c *CommentsListCall) StartModifiedTime(startModifiedTime string) *CommentsListCall
- func (c *CommentsListCall) UserIP(userIP string) *CommentsListCall
- type CommentsService
- func (r *CommentsService) Create(fileId string, comment *Comment) *CommentsCreateCall
- func (r *CommentsService) Delete(fileId string, commentId string) *CommentsDeleteCall
- func (r *CommentsService) Get(fileId string, commentId string) *CommentsGetCall
- func (r *CommentsService) List(fileId string) *CommentsListCall
- func (r *CommentsService) Update(fileId string, commentId string, comment *Comment) *CommentsUpdateCall
- type CommentsUpdateCall
- func (c *CommentsUpdateCall) Context(ctx context.Context) *CommentsUpdateCall
- func (c *CommentsUpdateCall) Do() (*Comment, error)
- func (c *CommentsUpdateCall) Fields(s ...googleapi.Field) *CommentsUpdateCall
- func (c *CommentsUpdateCall) QuotaUser(quotaUser string) *CommentsUpdateCall
- func (c *CommentsUpdateCall) UserIP(userIP string) *CommentsUpdateCall
- type File
- type FileCapabilities
- type FileContentHints
- type FileContentHintsThumbnail
- type FileImageMediaMetadata
- type FileImageMediaMetadataLocation
- type FileList
- type FileVideoMediaMetadata
- type FilesCopyCall
- func (c *FilesCopyCall) Context(ctx context.Context) *FilesCopyCall
- func (c *FilesCopyCall) Do() (*File, error)
- func (c *FilesCopyCall) Fields(s ...googleapi.Field) *FilesCopyCall
- func (c *FilesCopyCall) IgnoreDefaultVisibility(ignoreDefaultVisibility bool) *FilesCopyCall
- func (c *FilesCopyCall) KeepRevisionForever(keepRevisionForever bool) *FilesCopyCall
- func (c *FilesCopyCall) OcrLanguage(ocrLanguage string) *FilesCopyCall
- func (c *FilesCopyCall) QuotaUser(quotaUser string) *FilesCopyCall
- func (c *FilesCopyCall) UserIP(userIP string) *FilesCopyCall
- type FilesCreateCall
- func (c *FilesCreateCall) Context(ctx context.Context) *FilesCreateCall
- func (c *FilesCreateCall) Do() (*File, error)
- func (c *FilesCreateCall) Fields(s ...googleapi.Field) *FilesCreateCall
- func (c *FilesCreateCall) IgnoreDefaultVisibility(ignoreDefaultVisibility bool) *FilesCreateCall
- func (c *FilesCreateCall) KeepRevisionForever(keepRevisionForever bool) *FilesCreateCall
- func (c *FilesCreateCall) Media(r io.Reader) *FilesCreateCall
- func (c *FilesCreateCall) OcrLanguage(ocrLanguage string) *FilesCreateCall
- func (c *FilesCreateCall) ProgressUpdater(pu googleapi.ProgressUpdater) *FilesCreateCall
- func (c *FilesCreateCall) QuotaUser(quotaUser string) *FilesCreateCall
- func (c *FilesCreateCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *FilesCreateCall
- func (c *FilesCreateCall) UseContentAsIndexableText(useContentAsIndexableText bool) *FilesCreateCall
- func (c *FilesCreateCall) UserIP(userIP string) *FilesCreateCall
- type FilesDeleteCall
- func (c *FilesDeleteCall) Context(ctx context.Context) *FilesDeleteCall
- func (c *FilesDeleteCall) Do() error
- func (c *FilesDeleteCall) Fields(s ...googleapi.Field) *FilesDeleteCall
- func (c *FilesDeleteCall) QuotaUser(quotaUser string) *FilesDeleteCall
- func (c *FilesDeleteCall) UserIP(userIP string) *FilesDeleteCall
- type FilesEmptyTrashCall
- func (c *FilesEmptyTrashCall) Context(ctx context.Context) *FilesEmptyTrashCall
- func (c *FilesEmptyTrashCall) Do() error
- func (c *FilesEmptyTrashCall) Fields(s ...googleapi.Field) *FilesEmptyTrashCall
- func (c *FilesEmptyTrashCall) QuotaUser(quotaUser string) *FilesEmptyTrashCall
- func (c *FilesEmptyTrashCall) UserIP(userIP string) *FilesEmptyTrashCall
- type FilesExportCall
- func (c *FilesExportCall) Context(ctx context.Context) *FilesExportCall
- func (c *FilesExportCall) Do() error
- func (c *FilesExportCall) Download() (*http.Response, error)
- func (c *FilesExportCall) Fields(s ...googleapi.Field) *FilesExportCall
- func (c *FilesExportCall) IfNoneMatch(entityTag string) *FilesExportCall
- func (c *FilesExportCall) QuotaUser(quotaUser string) *FilesExportCall
- func (c *FilesExportCall) UserIP(userIP string) *FilesExportCall
- type FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) Context(ctx context.Context) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) Count(count int64) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) Do() (*GeneratedIds, error)
- func (c *FilesGenerateIdsCall) Fields(s ...googleapi.Field) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) IfNoneMatch(entityTag string) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) QuotaUser(quotaUser string) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) Space(space string) *FilesGenerateIdsCall
- func (c *FilesGenerateIdsCall) UserIP(userIP string) *FilesGenerateIdsCall
- type FilesGetCall
- func (c *FilesGetCall) AcknowledgeAbuse(acknowledgeAbuse bool) *FilesGetCall
- func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall
- func (c *FilesGetCall) Do() (*File, error)
- func (c *FilesGetCall) Download() (*http.Response, error)
- func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall
- func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall
- func (c *FilesGetCall) QuotaUser(quotaUser string) *FilesGetCall
- func (c *FilesGetCall) UserIP(userIP string) *FilesGetCall
- type FilesListCall
- func (c *FilesListCall) Context(ctx context.Context) *FilesListCall
- func (c *FilesListCall) Corpus(corpus string) *FilesListCall
- func (c *FilesListCall) Do() (*FileList, error)
- func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall
- func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall
- func (c *FilesListCall) OrderBy(orderBy string) *FilesListCall
- func (c *FilesListCall) PageSize(pageSize int64) *FilesListCall
- func (c *FilesListCall) PageToken(pageToken string) *FilesListCall
- func (c *FilesListCall) Q(q string) *FilesListCall
- func (c *FilesListCall) QuotaUser(quotaUser string) *FilesListCall
- func (c *FilesListCall) Spaces(spaces string) *FilesListCall
- func (c *FilesListCall) UserIP(userIP string) *FilesListCall
- type FilesService
- func (r *FilesService) Copy(fileId string, file *File) *FilesCopyCall
- func (r *FilesService) Create(file *File) *FilesCreateCall
- func (r *FilesService) Delete(fileId string) *FilesDeleteCall
- func (r *FilesService) EmptyTrash() *FilesEmptyTrashCall
- func (r *FilesService) Export(fileId string, mimeType string) *FilesExportCall
- func (r *FilesService) GenerateIds() *FilesGenerateIdsCall
- func (r *FilesService) Get(fileId string) *FilesGetCall
- func (r *FilesService) List() *FilesListCall
- func (r *FilesService) Update(fileId string, file *File) *FilesUpdateCall
- func (r *FilesService) Watch(fileId string, channel *Channel) *FilesWatchCall
- type FilesUpdateCall
- func (c *FilesUpdateCall) AddParents(addParents string) *FilesUpdateCall
- func (c *FilesUpdateCall) Context(ctx context.Context) *FilesUpdateCall
- func (c *FilesUpdateCall) Do() (*File, error)
- func (c *FilesUpdateCall) Fields(s ...googleapi.Field) *FilesUpdateCall
- func (c *FilesUpdateCall) KeepRevisionForever(keepRevisionForever bool) *FilesUpdateCall
- func (c *FilesUpdateCall) Media(r io.Reader) *FilesUpdateCall
- func (c *FilesUpdateCall) OcrLanguage(ocrLanguage string) *FilesUpdateCall
- func (c *FilesUpdateCall) ProgressUpdater(pu googleapi.ProgressUpdater) *FilesUpdateCall
- func (c *FilesUpdateCall) QuotaUser(quotaUser string) *FilesUpdateCall
- func (c *FilesUpdateCall) RemoveParents(removeParents string) *FilesUpdateCall
- func (c *FilesUpdateCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *FilesUpdateCall
- func (c *FilesUpdateCall) UseContentAsIndexableText(useContentAsIndexableText bool) *FilesUpdateCall
- func (c *FilesUpdateCall) UserIP(userIP string) *FilesUpdateCall
- type FilesWatchCall
- func (c *FilesWatchCall) AcknowledgeAbuse(acknowledgeAbuse bool) *FilesWatchCall
- func (c *FilesWatchCall) Context(ctx context.Context) *FilesWatchCall
- func (c *FilesWatchCall) Do() (*Channel, error)
- func (c *FilesWatchCall) Download() (*http.Response, error)
- func (c *FilesWatchCall) Fields(s ...googleapi.Field) *FilesWatchCall
- func (c *FilesWatchCall) QuotaUser(quotaUser string) *FilesWatchCall
- func (c *FilesWatchCall) UserIP(userIP string) *FilesWatchCall
- type GeneratedIds
- type Permission
- type PermissionList
- type PermissionsCreateCall
- func (c *PermissionsCreateCall) Context(ctx context.Context) *PermissionsCreateCall
- func (c *PermissionsCreateCall) Do() (*Permission, error)
- func (c *PermissionsCreateCall) EmailMessage(emailMessage string) *PermissionsCreateCall
- func (c *PermissionsCreateCall) Fields(s ...googleapi.Field) *PermissionsCreateCall
- func (c *PermissionsCreateCall) QuotaUser(quotaUser string) *PermissionsCreateCall
- func (c *PermissionsCreateCall) SendNotificationEmail(sendNotificationEmail bool) *PermissionsCreateCall
- func (c *PermissionsCreateCall) TransferOwnership(transferOwnership bool) *PermissionsCreateCall
- func (c *PermissionsCreateCall) UserIP(userIP string) *PermissionsCreateCall
- type PermissionsDeleteCall
- func (c *PermissionsDeleteCall) Context(ctx context.Context) *PermissionsDeleteCall
- func (c *PermissionsDeleteCall) Do() error
- func (c *PermissionsDeleteCall) Fields(s ...googleapi.Field) *PermissionsDeleteCall
- func (c *PermissionsDeleteCall) QuotaUser(quotaUser string) *PermissionsDeleteCall
- func (c *PermissionsDeleteCall) UserIP(userIP string) *PermissionsDeleteCall
- type PermissionsGetCall
- func (c *PermissionsGetCall) Context(ctx context.Context) *PermissionsGetCall
- func (c *PermissionsGetCall) Do() (*Permission, error)
- func (c *PermissionsGetCall) Fields(s ...googleapi.Field) *PermissionsGetCall
- func (c *PermissionsGetCall) IfNoneMatch(entityTag string) *PermissionsGetCall
- func (c *PermissionsGetCall) QuotaUser(quotaUser string) *PermissionsGetCall
- func (c *PermissionsGetCall) UserIP(userIP string) *PermissionsGetCall
- type PermissionsListCall
- func (c *PermissionsListCall) Context(ctx context.Context) *PermissionsListCall
- func (c *PermissionsListCall) Do() (*PermissionList, error)
- func (c *PermissionsListCall) Fields(s ...googleapi.Field) *PermissionsListCall
- func (c *PermissionsListCall) IfNoneMatch(entityTag string) *PermissionsListCall
- func (c *PermissionsListCall) QuotaUser(quotaUser string) *PermissionsListCall
- func (c *PermissionsListCall) UserIP(userIP string) *PermissionsListCall
- type PermissionsService
- func (r *PermissionsService) Create(fileId string, permission *Permission) *PermissionsCreateCall
- func (r *PermissionsService) Delete(fileId string, permissionId string) *PermissionsDeleteCall
- func (r *PermissionsService) Get(fileId string, permissionId string) *PermissionsGetCall
- func (r *PermissionsService) List(fileId string) *PermissionsListCall
- func (r *PermissionsService) Update(fileId string, permissionId string, permission *Permission) *PermissionsUpdateCall
- type PermissionsUpdateCall
- func (c *PermissionsUpdateCall) Context(ctx context.Context) *PermissionsUpdateCall
- func (c *PermissionsUpdateCall) Do() (*Permission, error)
- func (c *PermissionsUpdateCall) Fields(s ...googleapi.Field) *PermissionsUpdateCall
- func (c *PermissionsUpdateCall) QuotaUser(quotaUser string) *PermissionsUpdateCall
- func (c *PermissionsUpdateCall) TransferOwnership(transferOwnership bool) *PermissionsUpdateCall
- func (c *PermissionsUpdateCall) UserIP(userIP string) *PermissionsUpdateCall
- type RepliesCreateCall
- func (c *RepliesCreateCall) Context(ctx context.Context) *RepliesCreateCall
- func (c *RepliesCreateCall) Do() (*Reply, error)
- func (c *RepliesCreateCall) Fields(s ...googleapi.Field) *RepliesCreateCall
- func (c *RepliesCreateCall) QuotaUser(quotaUser string) *RepliesCreateCall
- func (c *RepliesCreateCall) UserIP(userIP string) *RepliesCreateCall
- type RepliesDeleteCall
- func (c *RepliesDeleteCall) Context(ctx context.Context) *RepliesDeleteCall
- func (c *RepliesDeleteCall) Do() error
- func (c *RepliesDeleteCall) Fields(s ...googleapi.Field) *RepliesDeleteCall
- func (c *RepliesDeleteCall) QuotaUser(quotaUser string) *RepliesDeleteCall
- func (c *RepliesDeleteCall) UserIP(userIP string) *RepliesDeleteCall
- type RepliesGetCall
- func (c *RepliesGetCall) Context(ctx context.Context) *RepliesGetCall
- func (c *RepliesGetCall) Do() (*Reply, error)
- func (c *RepliesGetCall) Fields(s ...googleapi.Field) *RepliesGetCall
- func (c *RepliesGetCall) IfNoneMatch(entityTag string) *RepliesGetCall
- func (c *RepliesGetCall) IncludeDeleted(includeDeleted bool) *RepliesGetCall
- func (c *RepliesGetCall) QuotaUser(quotaUser string) *RepliesGetCall
- func (c *RepliesGetCall) UserIP(userIP string) *RepliesGetCall
- type RepliesListCall
- func (c *RepliesListCall) Context(ctx context.Context) *RepliesListCall
- func (c *RepliesListCall) Do() (*ReplyList, error)
- func (c *RepliesListCall) Fields(s ...googleapi.Field) *RepliesListCall
- func (c *RepliesListCall) IfNoneMatch(entityTag string) *RepliesListCall
- func (c *RepliesListCall) IncludeDeleted(includeDeleted bool) *RepliesListCall
- func (c *RepliesListCall) PageSize(pageSize int64) *RepliesListCall
- func (c *RepliesListCall) PageToken(pageToken string) *RepliesListCall
- func (c *RepliesListCall) QuotaUser(quotaUser string) *RepliesListCall
- func (c *RepliesListCall) UserIP(userIP string) *RepliesListCall
- type RepliesService
- func (r *RepliesService) Create(fileId string, commentId string, reply *Reply) *RepliesCreateCall
- func (r *RepliesService) Delete(fileId string, commentId string, replyId string) *RepliesDeleteCall
- func (r *RepliesService) Get(fileId string, commentId string, replyId string) *RepliesGetCall
- func (r *RepliesService) List(fileId string, commentId string) *RepliesListCall
- func (r *RepliesService) Update(fileId string, commentId string, replyId string, reply *Reply) *RepliesUpdateCall
- type RepliesUpdateCall
- func (c *RepliesUpdateCall) Context(ctx context.Context) *RepliesUpdateCall
- func (c *RepliesUpdateCall) Do() (*Reply, error)
- func (c *RepliesUpdateCall) Fields(s ...googleapi.Field) *RepliesUpdateCall
- func (c *RepliesUpdateCall) QuotaUser(quotaUser string) *RepliesUpdateCall
- func (c *RepliesUpdateCall) UserIP(userIP string) *RepliesUpdateCall
- type Reply
- type ReplyList
- type Revision
- type RevisionList
- type RevisionsDeleteCall
- func (c *RevisionsDeleteCall) Context(ctx context.Context) *RevisionsDeleteCall
- func (c *RevisionsDeleteCall) Do() error
- func (c *RevisionsDeleteCall) Fields(s ...googleapi.Field) *RevisionsDeleteCall
- func (c *RevisionsDeleteCall) QuotaUser(quotaUser string) *RevisionsDeleteCall
- func (c *RevisionsDeleteCall) UserIP(userIP string) *RevisionsDeleteCall
- type RevisionsGetCall
- func (c *RevisionsGetCall) AcknowledgeAbuse(acknowledgeAbuse bool) *RevisionsGetCall
- func (c *RevisionsGetCall) Context(ctx context.Context) *RevisionsGetCall
- func (c *RevisionsGetCall) Do() (*Revision, error)
- func (c *RevisionsGetCall) Download() (*http.Response, error)
- func (c *RevisionsGetCall) Fields(s ...googleapi.Field) *RevisionsGetCall
- func (c *RevisionsGetCall) IfNoneMatch(entityTag string) *RevisionsGetCall
- func (c *RevisionsGetCall) QuotaUser(quotaUser string) *RevisionsGetCall
- func (c *RevisionsGetCall) UserIP(userIP string) *RevisionsGetCall
- type RevisionsListCall
- func (c *RevisionsListCall) Context(ctx context.Context) *RevisionsListCall
- func (c *RevisionsListCall) Do() (*RevisionList, error)
- func (c *RevisionsListCall) Fields(s ...googleapi.Field) *RevisionsListCall
- func (c *RevisionsListCall) IfNoneMatch(entityTag string) *RevisionsListCall
- func (c *RevisionsListCall) QuotaUser(quotaUser string) *RevisionsListCall
- func (c *RevisionsListCall) UserIP(userIP string) *RevisionsListCall
- type RevisionsService
- func (r *RevisionsService) Delete(fileId string, revisionId string) *RevisionsDeleteCall
- func (r *RevisionsService) Get(fileId string, revisionId string) *RevisionsGetCall
- func (r *RevisionsService) List(fileId string) *RevisionsListCall
- func (r *RevisionsService) Update(fileId string, revisionId string, revision *Revision) *RevisionsUpdateCall
- type RevisionsUpdateCall
- func (c *RevisionsUpdateCall) Context(ctx context.Context) *RevisionsUpdateCall
- func (c *RevisionsUpdateCall) Do() (*Revision, error)
- func (c *RevisionsUpdateCall) Fields(s ...googleapi.Field) *RevisionsUpdateCall
- func (c *RevisionsUpdateCall) QuotaUser(quotaUser string) *RevisionsUpdateCall
- func (c *RevisionsUpdateCall) UserIP(userIP string) *RevisionsUpdateCall
- type Service
- type StartPageToken
- type User
Constants ¶
const ( // View and manage the files in your Google Drive DriveScope = "https://www.googleapis.com/auth/drive" // View and manage its own configuration data in your Google Drive DriveAppdataScope = "https://www.googleapis.com/auth/drive.appdata" // View and manage Google Drive files and folders that you have opened // or created with this app DriveFileScope = "https://www.googleapis.com/auth/drive.file" // View and manage metadata of files in your Google Drive DriveMetadataScope = "https://www.googleapis.com/auth/drive.metadata" // View metadata for files in your Google Drive DriveMetadataReadonlyScope = "https://www.googleapis.com/auth/drive.metadata.readonly" // View the photos, videos and albums in your Google Photos DrivePhotosReadonlyScope = "https://www.googleapis.com/auth/drive.photos.readonly" // View the files in your Google Drive DriveReadonlyScope = "https://www.googleapis.com/auth/drive.readonly" // Modify your Google Apps Script scripts' behavior DriveScriptsScope = "https://www.googleapis.com/auth/drive.scripts" )
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type About ¶
type About struct { // AppInstalled: Whether the user has installed the requesting app. AppInstalled bool `json:"appInstalled,omitempty"` // ExportFormats: A map of source MIME type to possible targets for all // supported exports. ExportFormats map[string][]string `json:"exportFormats,omitempty"` // FolderColorPalette: The currently supported folder colors as RGB hex // strings. FolderColorPalette []string `json:"folderColorPalette,omitempty"` // ImportFormats: A map of source MIME type to possible targets for all // supported imports. ImportFormats map[string][]string `json:"importFormats,omitempty"` // Kind: This is always drive#about. Kind string `json:"kind,omitempty"` // MaxImportSizes: A map of maximum import sizes by MIME type, in bytes. MaxImportSizes map[string]string `json:"maxImportSizes,omitempty"` // MaxUploadSize: The maximum upload size in bytes. MaxUploadSize int64 `json:"maxUploadSize,omitempty,string"` // StorageQuota: The user's storage quota limits and usage. All fields // are measured in bytes. StorageQuota *AboutStorageQuota `json:"storageQuota,omitempty"` // User: The authenticated user. User *User `json:"user,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "AppInstalled") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
About: Information about the user, the user's Drive, and system capabilities.
func (*About) MarshalJSON ¶
type AboutGetCall ¶
type AboutGetCall struct {
// contains filtered or unexported fields
}
func (*AboutGetCall) Context ¶
func (c *AboutGetCall) Context(ctx context.Context) *AboutGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*AboutGetCall) Do ¶
func (c *AboutGetCall) Do() (*About, error)
Do executes the "drive.about.get" call. Exactly one of *About or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *About.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*AboutGetCall) Fields ¶
func (c *AboutGetCall) Fields(s ...googleapi.Field) *AboutGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*AboutGetCall) IfNoneMatch ¶
func (c *AboutGetCall) IfNoneMatch(entityTag string) *AboutGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*AboutGetCall) QuotaUser ¶
func (c *AboutGetCall) QuotaUser(quotaUser string) *AboutGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*AboutGetCall) UserIP ¶
func (c *AboutGetCall) UserIP(userIP string) *AboutGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type AboutService ¶
type AboutService struct {
// contains filtered or unexported fields
}
func NewAboutService ¶
func NewAboutService(s *Service) *AboutService
func (*AboutService) Get ¶
func (r *AboutService) Get() *AboutGetCall
Get: Gets information about the user, the user's Drive, and system capabilities.
type AboutStorageQuota ¶
type AboutStorageQuota struct { // Limit: The usage limit, if applicable. This will not be present if // the user has unlimited storage. Limit int64 `json:"limit,omitempty,string"` // Usage: The total usage across all services. Usage int64 `json:"usage,omitempty,string"` // UsageInDrive: The usage by all files in Google Drive. UsageInDrive int64 `json:"usageInDrive,omitempty,string"` // UsageInDriveTrash: The usage by trashed files in Google Drive. UsageInDriveTrash int64 `json:"usageInDriveTrash,omitempty,string"` // ForceSendFields is a list of field names (e.g. "Limit") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
AboutStorageQuota: The user's storage quota limits and usage. All fields are measured in bytes.
func (*AboutStorageQuota) MarshalJSON ¶
func (s *AboutStorageQuota) MarshalJSON() ([]byte, error)
type Change ¶
type Change struct { // File: The updated state of the file. Present if the file has not been // removed. File *File `json:"file,omitempty"` // FileId: The ID of the file which has changed. FileId string `json:"fileId,omitempty"` // Kind: This is always drive#change. Kind string `json:"kind,omitempty"` // Removed: Whether the file has been removed from the view of the // changes list, for example by deletion or lost access. Removed bool `json:"removed,omitempty"` // Time: The time of this change (RFC 3339 date-time). Time string `json:"time,omitempty"` // ForceSendFields is a list of field names (e.g. "File") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Change: A change to a file.
func (*Change) MarshalJSON ¶
type ChangeList ¶
type ChangeList struct { // Changes: The page of changes. Changes []*Change `json:"changes,omitempty"` // Kind: This is always drive#changeList. Kind string `json:"kind,omitempty"` // NewStartPageToken: The starting page token for future changes. This // will be present only if the end of the current changes list has been // reached. NewStartPageToken string `json:"newStartPageToken,omitempty"` // NextPageToken: The page token for the next page of changes. This will // be absent if the end of the current changes list has been reached. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Changes") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
ChangeList: A list of changes for a user.
func (*ChangeList) MarshalJSON ¶
func (s *ChangeList) MarshalJSON() ([]byte, error)
type ChangesGetStartPageTokenCall ¶
type ChangesGetStartPageTokenCall struct {
// contains filtered or unexported fields
}
func (*ChangesGetStartPageTokenCall) Context ¶
func (c *ChangesGetStartPageTokenCall) Context(ctx context.Context) *ChangesGetStartPageTokenCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ChangesGetStartPageTokenCall) Do ¶
func (c *ChangesGetStartPageTokenCall) Do() (*StartPageToken, error)
Do executes the "drive.changes.getStartPageToken" call. Exactly one of *StartPageToken or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *StartPageToken.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ChangesGetStartPageTokenCall) Fields ¶
func (c *ChangesGetStartPageTokenCall) Fields(s ...googleapi.Field) *ChangesGetStartPageTokenCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ChangesGetStartPageTokenCall) IfNoneMatch ¶
func (c *ChangesGetStartPageTokenCall) IfNoneMatch(entityTag string) *ChangesGetStartPageTokenCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ChangesGetStartPageTokenCall) QuotaUser ¶
func (c *ChangesGetStartPageTokenCall) QuotaUser(quotaUser string) *ChangesGetStartPageTokenCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*ChangesGetStartPageTokenCall) UserIP ¶
func (c *ChangesGetStartPageTokenCall) UserIP(userIP string) *ChangesGetStartPageTokenCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type ChangesListCall ¶
type ChangesListCall struct {
// contains filtered or unexported fields
}
func (*ChangesListCall) Context ¶
func (c *ChangesListCall) Context(ctx context.Context) *ChangesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ChangesListCall) Do ¶
func (c *ChangesListCall) Do() (*ChangeList, error)
Do executes the "drive.changes.list" call. Exactly one of *ChangeList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ChangeList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ChangesListCall) Fields ¶
func (c *ChangesListCall) Fields(s ...googleapi.Field) *ChangesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ChangesListCall) IfNoneMatch ¶
func (c *ChangesListCall) IfNoneMatch(entityTag string) *ChangesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ChangesListCall) IncludeRemoved ¶
func (c *ChangesListCall) IncludeRemoved(includeRemoved bool) *ChangesListCall
IncludeRemoved sets the optional parameter "includeRemoved": Whether to include changes indicating that items have left the view of the changes list, for example by deletion or lost access.
func (*ChangesListCall) PageSize ¶
func (c *ChangesListCall) PageSize(pageSize int64) *ChangesListCall
PageSize sets the optional parameter "pageSize": The maximum number of changes to return per page.
func (*ChangesListCall) QuotaUser ¶
func (c *ChangesListCall) QuotaUser(quotaUser string) *ChangesListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*ChangesListCall) RestrictToMyDrive ¶
func (c *ChangesListCall) RestrictToMyDrive(restrictToMyDrive bool) *ChangesListCall
RestrictToMyDrive sets the optional parameter "restrictToMyDrive": Whether to restrict the results to changes inside the My Drive hierarchy. This omits changes to files such as those in the Application Data folder or shared files which have not been added to My Drive.
func (*ChangesListCall) Spaces ¶
func (c *ChangesListCall) Spaces(spaces string) *ChangesListCall
Spaces sets the optional parameter "spaces": A comma-separated list of spaces to query within the user corpus. Supported values are 'drive', 'appDataFolder' and 'photos'.
func (*ChangesListCall) UserIP ¶
func (c *ChangesListCall) UserIP(userIP string) *ChangesListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type ChangesService ¶
type ChangesService struct {
// contains filtered or unexported fields
}
func NewChangesService ¶
func NewChangesService(s *Service) *ChangesService
func (*ChangesService) GetStartPageToken ¶
func (r *ChangesService) GetStartPageToken() *ChangesGetStartPageTokenCall
GetStartPageToken: Gets the starting pageToken for listing future changes.
func (*ChangesService) List ¶
func (r *ChangesService) List(pageToken string) *ChangesListCall
List: Lists changes for a user.
func (*ChangesService) Watch ¶
func (r *ChangesService) Watch(pageToken string, channel *Channel) *ChangesWatchCall
Watch: Subscribes to changes for a user.
type ChangesWatchCall ¶
type ChangesWatchCall struct {
// contains filtered or unexported fields
}
func (*ChangesWatchCall) Context ¶
func (c *ChangesWatchCall) Context(ctx context.Context) *ChangesWatchCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ChangesWatchCall) Do ¶
func (c *ChangesWatchCall) Do() (*Channel, error)
Do executes the "drive.changes.watch" call. Exactly one of *Channel or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Channel.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ChangesWatchCall) Fields ¶
func (c *ChangesWatchCall) Fields(s ...googleapi.Field) *ChangesWatchCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ChangesWatchCall) IncludeRemoved ¶
func (c *ChangesWatchCall) IncludeRemoved(includeRemoved bool) *ChangesWatchCall
IncludeRemoved sets the optional parameter "includeRemoved": Whether to include changes indicating that items have left the view of the changes list, for example by deletion or lost access.
func (*ChangesWatchCall) PageSize ¶
func (c *ChangesWatchCall) PageSize(pageSize int64) *ChangesWatchCall
PageSize sets the optional parameter "pageSize": The maximum number of changes to return per page.
func (*ChangesWatchCall) QuotaUser ¶
func (c *ChangesWatchCall) QuotaUser(quotaUser string) *ChangesWatchCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*ChangesWatchCall) RestrictToMyDrive ¶
func (c *ChangesWatchCall) RestrictToMyDrive(restrictToMyDrive bool) *ChangesWatchCall
RestrictToMyDrive sets the optional parameter "restrictToMyDrive": Whether to restrict the results to changes inside the My Drive hierarchy. This omits changes to files such as those in the Application Data folder or shared files which have not been added to My Drive.
func (*ChangesWatchCall) Spaces ¶
func (c *ChangesWatchCall) Spaces(spaces string) *ChangesWatchCall
Spaces sets the optional parameter "spaces": A comma-separated list of spaces to query within the user corpus. Supported values are 'drive', 'appDataFolder' and 'photos'.
func (*ChangesWatchCall) UserIP ¶
func (c *ChangesWatchCall) UserIP(userIP string) *ChangesWatchCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type Channel ¶
type Channel struct { // Address: The address where notifications are delivered for this // channel. Address string `json:"address,omitempty"` // Expiration: Date and time of notification channel expiration, // expressed as a Unix timestamp, in milliseconds. Optional. Expiration int64 `json:"expiration,omitempty,string"` // Id: A UUID or similar unique string that identifies this channel. Id string `json:"id,omitempty"` // Kind: Identifies this as a notification channel used to watch for // changes to a resource. Value: the fixed string "api#channel". Kind string `json:"kind,omitempty"` // Params: Additional parameters controlling delivery channel behavior. // Optional. Params map[string]string `json:"params,omitempty"` // Payload: A Boolean value to indicate whether payload is wanted. // Optional. Payload bool `json:"payload,omitempty"` // ResourceId: An opaque ID that identifies the resource being watched // on this channel. Stable across different API versions. ResourceId string `json:"resourceId,omitempty"` // ResourceUri: A version-specific identifier for the watched resource. ResourceUri string `json:"resourceUri,omitempty"` // Token: An arbitrary string delivered to the target address with each // notification delivered over this channel. Optional. Token string `json:"token,omitempty"` // Type: The type of delivery mechanism used for this channel. Type string `json:"type,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Address") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Channel: An notification channel used to watch for resource changes.
func (*Channel) MarshalJSON ¶
type ChannelsService ¶
type ChannelsService struct {
// contains filtered or unexported fields
}
func NewChannelsService ¶
func NewChannelsService(s *Service) *ChannelsService
func (*ChannelsService) Stop ¶
func (r *ChannelsService) Stop(channel *Channel) *ChannelsStopCall
Stop: Stop watching resources through this channel
type ChannelsStopCall ¶
type ChannelsStopCall struct {
// contains filtered or unexported fields
}
func (*ChannelsStopCall) Context ¶
func (c *ChannelsStopCall) Context(ctx context.Context) *ChannelsStopCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ChannelsStopCall) Do ¶
func (c *ChannelsStopCall) Do() error
Do executes the "drive.channels.stop" call.
func (*ChannelsStopCall) Fields ¶
func (c *ChannelsStopCall) Fields(s ...googleapi.Field) *ChannelsStopCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ChannelsStopCall) QuotaUser ¶
func (c *ChannelsStopCall) QuotaUser(quotaUser string) *ChannelsStopCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*ChannelsStopCall) UserIP ¶
func (c *ChannelsStopCall) UserIP(userIP string) *ChannelsStopCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type Comment ¶
type Comment struct { // Anchor: A region of the document represented as a JSON string. See // anchor documentation for details on how to define and interpret // anchor properties. Anchor string `json:"anchor,omitempty"` // Author: The user who created the comment. Author *User `json:"author,omitempty"` // Content: The plain text content of the comment. This field is used // for setting the content, while htmlContent should be displayed. Content string `json:"content,omitempty"` // CreatedTime: The time at which the comment was created (RFC 3339 // date-time). CreatedTime string `json:"createdTime,omitempty"` // Deleted: Whether the comment has been deleted. A deleted comment has // no content. Deleted bool `json:"deleted,omitempty"` // HtmlContent: The content of the comment with HTML formatting. HtmlContent string `json:"htmlContent,omitempty"` // Id: The ID of the comment. Id string `json:"id,omitempty"` // Kind: This is always drive#comment. Kind string `json:"kind,omitempty"` // ModifiedTime: The last time the comment or any of its replies was // modified (RFC 3339 date-time). ModifiedTime string `json:"modifiedTime,omitempty"` // QuotedFileContent: The file content to which the comment refers, // typically within the anchor region. For a text file, for example, // this would be the text at the location of the comment. QuotedFileContent *CommentQuotedFileContent `json:"quotedFileContent,omitempty"` // Replies: The full list of replies to the comment in chronological // order. Replies []*Reply `json:"replies,omitempty"` // Resolved: Whether the comment has been resolved by one of its // replies. Resolved bool `json:"resolved,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Anchor") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Comment: A comment on a file.
func (*Comment) MarshalJSON ¶
type CommentList ¶
type CommentList struct { // Comments: The page of comments. Comments []*Comment `json:"comments,omitempty"` // Kind: This is always drive#commentList. Kind string `json:"kind,omitempty"` // NextPageToken: The page token for the next page of comments. This // will be absent if the end of the comments list has been reached. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Comments") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
CommentList: A list of comments on a file.
func (*CommentList) MarshalJSON ¶
func (s *CommentList) MarshalJSON() ([]byte, error)
type CommentQuotedFileContent ¶
type CommentQuotedFileContent struct { // MimeType: The MIME type of the quoted content. MimeType string `json:"mimeType,omitempty"` // Value: The quoted content itself. This is interpreted as plain text // if set through the API. Value string `json:"value,omitempty"` // ForceSendFields is a list of field names (e.g. "MimeType") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
CommentQuotedFileContent: The file content to which the comment refers, typically within the anchor region. For a text file, for example, this would be the text at the location of the comment.
func (*CommentQuotedFileContent) MarshalJSON ¶
func (s *CommentQuotedFileContent) MarshalJSON() ([]byte, error)
type CommentsCreateCall ¶
type CommentsCreateCall struct {
// contains filtered or unexported fields
}
func (*CommentsCreateCall) Context ¶
func (c *CommentsCreateCall) Context(ctx context.Context) *CommentsCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*CommentsCreateCall) Do ¶
func (c *CommentsCreateCall) Do() (*Comment, error)
Do executes the "drive.comments.create" call. Exactly one of *Comment or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Comment.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*CommentsCreateCall) Fields ¶
func (c *CommentsCreateCall) Fields(s ...googleapi.Field) *CommentsCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CommentsCreateCall) QuotaUser ¶
func (c *CommentsCreateCall) QuotaUser(quotaUser string) *CommentsCreateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*CommentsCreateCall) UserIP ¶
func (c *CommentsCreateCall) UserIP(userIP string) *CommentsCreateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type CommentsDeleteCall ¶
type CommentsDeleteCall struct {
// contains filtered or unexported fields
}
func (*CommentsDeleteCall) Context ¶
func (c *CommentsDeleteCall) Context(ctx context.Context) *CommentsDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*CommentsDeleteCall) Do ¶
func (c *CommentsDeleteCall) Do() error
Do executes the "drive.comments.delete" call.
func (*CommentsDeleteCall) Fields ¶
func (c *CommentsDeleteCall) Fields(s ...googleapi.Field) *CommentsDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CommentsDeleteCall) QuotaUser ¶
func (c *CommentsDeleteCall) QuotaUser(quotaUser string) *CommentsDeleteCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*CommentsDeleteCall) UserIP ¶
func (c *CommentsDeleteCall) UserIP(userIP string) *CommentsDeleteCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type CommentsGetCall ¶
type CommentsGetCall struct {
// contains filtered or unexported fields
}
func (*CommentsGetCall) Context ¶
func (c *CommentsGetCall) Context(ctx context.Context) *CommentsGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*CommentsGetCall) Do ¶
func (c *CommentsGetCall) Do() (*Comment, error)
Do executes the "drive.comments.get" call. Exactly one of *Comment or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Comment.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*CommentsGetCall) Fields ¶
func (c *CommentsGetCall) Fields(s ...googleapi.Field) *CommentsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CommentsGetCall) IfNoneMatch ¶
func (c *CommentsGetCall) IfNoneMatch(entityTag string) *CommentsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*CommentsGetCall) IncludeDeleted ¶
func (c *CommentsGetCall) IncludeDeleted(includeDeleted bool) *CommentsGetCall
IncludeDeleted sets the optional parameter "includeDeleted": Whether to return deleted comments. Deleted comments will not include their original content.
func (*CommentsGetCall) QuotaUser ¶
func (c *CommentsGetCall) QuotaUser(quotaUser string) *CommentsGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*CommentsGetCall) UserIP ¶
func (c *CommentsGetCall) UserIP(userIP string) *CommentsGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type CommentsListCall ¶
type CommentsListCall struct {
// contains filtered or unexported fields
}
func (*CommentsListCall) Context ¶
func (c *CommentsListCall) Context(ctx context.Context) *CommentsListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*CommentsListCall) Do ¶
func (c *CommentsListCall) Do() (*CommentList, error)
Do executes the "drive.comments.list" call. Exactly one of *CommentList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *CommentList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*CommentsListCall) Fields ¶
func (c *CommentsListCall) Fields(s ...googleapi.Field) *CommentsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CommentsListCall) IfNoneMatch ¶
func (c *CommentsListCall) IfNoneMatch(entityTag string) *CommentsListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*CommentsListCall) IncludeDeleted ¶
func (c *CommentsListCall) IncludeDeleted(includeDeleted bool) *CommentsListCall
IncludeDeleted sets the optional parameter "includeDeleted": Whether to include deleted comments. Deleted comments will not include their original content.
func (*CommentsListCall) PageSize ¶
func (c *CommentsListCall) PageSize(pageSize int64) *CommentsListCall
PageSize sets the optional parameter "pageSize": The maximum number of comments to return per page.
func (*CommentsListCall) PageToken ¶
func (c *CommentsListCall) PageToken(pageToken string) *CommentsListCall
PageToken sets the optional parameter "pageToken": The token for continuing a previous list request on the next page. This should be set to the value of 'nextPageToken' from the previous response.
func (*CommentsListCall) QuotaUser ¶
func (c *CommentsListCall) QuotaUser(quotaUser string) *CommentsListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*CommentsListCall) StartModifiedTime ¶
func (c *CommentsListCall) StartModifiedTime(startModifiedTime string) *CommentsListCall
StartModifiedTime sets the optional parameter "startModifiedTime": The minimum value of 'modifiedTime' for the result comments (RFC 3339 date-time).
func (*CommentsListCall) UserIP ¶
func (c *CommentsListCall) UserIP(userIP string) *CommentsListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type CommentsService ¶
type CommentsService struct {
// contains filtered or unexported fields
}
func NewCommentsService ¶
func NewCommentsService(s *Service) *CommentsService
func (*CommentsService) Create ¶
func (r *CommentsService) Create(fileId string, comment *Comment) *CommentsCreateCall
Create: Creates a new comment on a file.
func (*CommentsService) Delete ¶
func (r *CommentsService) Delete(fileId string, commentId string) *CommentsDeleteCall
Delete: Deletes a comment.
func (*CommentsService) Get ¶
func (r *CommentsService) Get(fileId string, commentId string) *CommentsGetCall
Get: Gets a comment by ID.
func (*CommentsService) List ¶
func (r *CommentsService) List(fileId string) *CommentsListCall
List: Lists a file's comments.
func (*CommentsService) Update ¶
func (r *CommentsService) Update(fileId string, commentId string, comment *Comment) *CommentsUpdateCall
Update: Updates a comment with patch semantics.
type CommentsUpdateCall ¶
type CommentsUpdateCall struct {
// contains filtered or unexported fields
}
func (*CommentsUpdateCall) Context ¶
func (c *CommentsUpdateCall) Context(ctx context.Context) *CommentsUpdateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*CommentsUpdateCall) Do ¶
func (c *CommentsUpdateCall) Do() (*Comment, error)
Do executes the "drive.comments.update" call. Exactly one of *Comment or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Comment.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*CommentsUpdateCall) Fields ¶
func (c *CommentsUpdateCall) Fields(s ...googleapi.Field) *CommentsUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*CommentsUpdateCall) QuotaUser ¶
func (c *CommentsUpdateCall) QuotaUser(quotaUser string) *CommentsUpdateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*CommentsUpdateCall) UserIP ¶
func (c *CommentsUpdateCall) UserIP(userIP string) *CommentsUpdateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type File ¶
type File struct { // AppProperties: A collection of arbitrary key-value pairs which are // private to the requesting app. // Entries with null values are cleared in update and copy requests. AppProperties map[string]string `json:"appProperties,omitempty"` // Capabilities: Capabilities the current user has on the file. Capabilities *FileCapabilities `json:"capabilities,omitempty"` // ContentHints: Additional information about the content of the file. // These fields are never populated in responses. ContentHints *FileContentHints `json:"contentHints,omitempty"` // CreatedTime: The time at which the file was created (RFC 3339 // date-time). CreatedTime string `json:"createdTime,omitempty"` // Description: A short description of the file. Description string `json:"description,omitempty"` // ExplicitlyTrashed: Whether the file has been explicitly trashed, as // opposed to recursively trashed from a parent folder. ExplicitlyTrashed bool `json:"explicitlyTrashed,omitempty"` // FileExtension: The final component of fullFileExtension. This is only // available for files with binary content in Drive. FileExtension string `json:"fileExtension,omitempty"` // FolderColorRgb: The color for a folder as an RGB hex string. The // supported colors are published in the folderColorPalette field of the // About resource. // If an unsupported color is specified, the closest color in the // palette will be used instead. FolderColorRgb string `json:"folderColorRgb,omitempty"` // FullFileExtension: The full file extension extracted from the name // field. May contain multiple concatenated extensions, such as // "tar.gz". This is only available for files with binary content in // Drive. // This is automatically updated when the name field changes, however it // is not cleared if the new name does not contain a valid extension. FullFileExtension string `json:"fullFileExtension,omitempty"` // HeadRevisionId: The ID of the file's head revision. This is currently // only available for files with binary content in Drive. HeadRevisionId string `json:"headRevisionId,omitempty"` // IconLink: A static, unauthenticated link to the file's icon. IconLink string `json:"iconLink,omitempty"` // Id: The ID of the file. Id string `json:"id,omitempty"` // ImageMediaMetadata: Additional metadata about image media, if // available. ImageMediaMetadata *FileImageMediaMetadata `json:"imageMediaMetadata,omitempty"` // Kind: This is always drive#file. Kind string `json:"kind,omitempty"` // LastModifyingUser: The last user to modify the file. LastModifyingUser *User `json:"lastModifyingUser,omitempty"` // Md5Checksum: The MD5 checksum for the content of the file. This is // only applicable to files with binary content in Drive. Md5Checksum string `json:"md5Checksum,omitempty"` // MimeType: The MIME type of the file. // Drive will attempt to automatically detect an appropriate value from // uploaded content if no value is provided. The value cannot be changed // unless a new revision is uploaded. // If a file is created with a Google Doc MIME type, the uploaded // content will be imported if possible. The supported import formats // are published in the About resource. MimeType string `json:"mimeType,omitempty"` // ModifiedByMeTime: The last time the file was modified by the user // (RFC 3339 date-time). ModifiedByMeTime string `json:"modifiedByMeTime,omitempty"` // ModifiedTime: The last time the file was modified by anyone (RFC 3339 // date-time). // Note that setting modifiedTime will also update modifiedByMeTime for // the user. ModifiedTime string `json:"modifiedTime,omitempty"` // Name: The name of the file. This is not necessarily unique within a // folder. Name string `json:"name,omitempty"` // OriginalFilename: The original filename of the uploaded content if // available, or else the original value of the name field. This is only // available for files with binary content in Drive. OriginalFilename string `json:"originalFilename,omitempty"` // OwnedByMe: Whether the user owns the file. OwnedByMe bool `json:"ownedByMe,omitempty"` // Owners: The owners of the file. Currently, only certain legacy files // may have more than one owner. Owners []*User `json:"owners,omitempty"` // Parents: The IDs of the parent folders which contain the file. // If not specified as part of a create request, the file will be placed // directly in the My Drive folder. Update requests must use the // addParents and removeParents parameters to modify the values. Parents []string `json:"parents,omitempty"` // Permissions: The full list of permissions for the file. This is only // available if the requesting user can share the file. Permissions []*Permission `json:"permissions,omitempty"` // Properties: A collection of arbitrary key-value pairs which are // visible to all apps. // Entries with null values are cleared in update and copy requests. Properties map[string]string `json:"properties,omitempty"` // QuotaBytesUsed: The number of storage quota bytes used by the file. // This includes the head revision as well as previous revisions with // keepForever enabled. QuotaBytesUsed int64 `json:"quotaBytesUsed,omitempty,string"` Shared bool `json:"shared,omitempty"` // user, if applicable (RFC 3339 date-time). SharedWithMeTime string `json:"sharedWithMeTime,omitempty"` // SharingUser: The user who shared the file with the requesting user, // if applicable. SharingUser *User `json:"sharingUser,omitempty"` // Size: The size of the file's content in bytes. This is only // applicable to files with binary content in Drive. Size int64 `json:"size,omitempty,string"` // Spaces: The list of spaces which contain the file. The currently // supported values are 'drive', 'appDataFolder' and 'photos'. Spaces []string `json:"spaces,omitempty"` // Starred: Whether the user has starred the file. Starred bool `json:"starred,omitempty"` // ThumbnailLink: A short-lived link to the file's thumbnail, if // available. Typically lasts on the order of hours. ThumbnailLink string `json:"thumbnailLink,omitempty"` // Trashed: Whether the file has been trashed, either explicitly or from // a trashed parent folder. Only the owner may trash a file, and other // users cannot see files in the owner's trash. Trashed bool `json:"trashed,omitempty"` // Version: A monotonically increasing version number for the file. This // reflects every change made to the file on the server, even those not // visible to the user. Version int64 `json:"version,omitempty,string"` // VideoMediaMetadata: Additional metadata about video media. This may // not be available immediately upon upload. VideoMediaMetadata *FileVideoMediaMetadata `json:"videoMediaMetadata,omitempty"` // ViewedByMe: Whether the file has been viewed by this user. ViewedByMe bool `json:"viewedByMe,omitempty"` // ViewedByMeTime: The last time the file was viewed by the user (RFC // 3339 date-time). ViewedByMeTime string `json:"viewedByMeTime,omitempty"` // ViewersCanCopyContent: Whether users with only reader or commenter // permission can copy the file's content. This affects copy, download, // and print operations. ViewersCanCopyContent bool `json:"viewersCanCopyContent,omitempty"` // WebContentLink: A link for downloading the content of the file in a // browser. This is only available for files with binary content in // Drive. WebContentLink string `json:"webContentLink,omitempty"` // WebViewLink: A link for opening the file in a relevant Google editor // or viewer in a browser. WebViewLink string `json:"webViewLink,omitempty"` // the file's permissions. WritersCanShare bool `json:"writersCanShare,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "AppProperties") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
File: The metadata for a file.
func (*File) MarshalJSON ¶
type FileCapabilities ¶
type FileCapabilities struct { // CanComment: Whether the user can comment on the file. CanComment bool `json:"canComment,omitempty"` // CanCopy: Whether the user can copy the file. CanCopy bool `json:"canCopy,omitempty"` // CanEdit: Whether the user can edit the file's content. CanEdit bool `json:"canEdit,omitempty"` // sharing settings. CanShare bool `json:"canShare,omitempty"` // ForceSendFields is a list of field names (e.g. "CanComment") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileCapabilities: Capabilities the current user has on the file.
func (*FileCapabilities) MarshalJSON ¶
func (s *FileCapabilities) MarshalJSON() ([]byte, error)
type FileContentHints ¶
type FileContentHints struct { // IndexableText: Text to be indexed for the file to improve fullText // queries. This is limited to 128KB in length and may contain HTML // elements. IndexableText string `json:"indexableText,omitempty"` // Thumbnail: A thumbnail for the file. This will only be used if Drive // cannot generate a standard thumbnail. Thumbnail *FileContentHintsThumbnail `json:"thumbnail,omitempty"` // ForceSendFields is a list of field names (e.g. "IndexableText") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileContentHints: Additional information about the content of the file. These fields are never populated in responses.
func (*FileContentHints) MarshalJSON ¶
func (s *FileContentHints) MarshalJSON() ([]byte, error)
type FileContentHintsThumbnail ¶
type FileContentHintsThumbnail struct { // Image: The thumbnail data encoded with URL-safe Base64 (RFC 4648 // section 5). Image string `json:"image,omitempty"` // MimeType: The MIME type of the thumbnail. MimeType string `json:"mimeType,omitempty"` // ForceSendFields is a list of field names (e.g. "Image") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileContentHintsThumbnail: A thumbnail for the file. This will only be used if Drive cannot generate a standard thumbnail.
func (*FileContentHintsThumbnail) MarshalJSON ¶
func (s *FileContentHintsThumbnail) MarshalJSON() ([]byte, error)
type FileImageMediaMetadata ¶
type FileImageMediaMetadata struct { // Aperture: The aperture used to create the photo (f-number). Aperture float64 `json:"aperture,omitempty"` // CameraMake: The make of the camera used to create the photo. CameraMake string `json:"cameraMake,omitempty"` // CameraModel: The model of the camera used to create the photo. CameraModel string `json:"cameraModel,omitempty"` // ColorSpace: The color space of the photo. ColorSpace string `json:"colorSpace,omitempty"` // ExposureBias: The exposure bias of the photo (APEX value). ExposureBias float64 `json:"exposureBias,omitempty"` // ExposureMode: The exposure mode used to create the photo. ExposureMode string `json:"exposureMode,omitempty"` // ExposureTime: The length of the exposure, in seconds. ExposureTime float64 `json:"exposureTime,omitempty"` // FlashUsed: Whether a flash was used to create the photo. FlashUsed bool `json:"flashUsed,omitempty"` // FocalLength: The focal length used to create the photo, in // millimeters. FocalLength float64 `json:"focalLength,omitempty"` // Height: The height of the image in pixels. Height int64 `json:"height,omitempty"` // IsoSpeed: The ISO speed used to create the photo. IsoSpeed int64 `json:"isoSpeed,omitempty"` // Lens: The lens used to create the photo. Lens string `json:"lens,omitempty"` // Location: Geographic location information stored in the image. Location *FileImageMediaMetadataLocation `json:"location,omitempty"` // MaxApertureValue: The smallest f-number of the lens at the focal // length used to create the photo (APEX value). MaxApertureValue float64 `json:"maxApertureValue,omitempty"` // MeteringMode: The metering mode used to create the photo. MeteringMode string `json:"meteringMode,omitempty"` // Rotation: The rotation in clockwise degrees from the image's original // orientation. Rotation int64 `json:"rotation,omitempty"` // Sensor: The type of sensor used to create the photo. Sensor string `json:"sensor,omitempty"` // SubjectDistance: The distance to the subject of the photo, in meters. SubjectDistance int64 `json:"subjectDistance,omitempty"` // Time: The date and time the photo was taken (EXIF DateTime). Time string `json:"time,omitempty"` // WhiteBalance: The white balance mode used to create the photo. WhiteBalance string `json:"whiteBalance,omitempty"` // Width: The width of the image in pixels. Width int64 `json:"width,omitempty"` // ForceSendFields is a list of field names (e.g. "Aperture") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileImageMediaMetadata: Additional metadata about image media, if available.
func (*FileImageMediaMetadata) MarshalJSON ¶
func (s *FileImageMediaMetadata) MarshalJSON() ([]byte, error)
type FileImageMediaMetadataLocation ¶
type FileImageMediaMetadataLocation struct { // Altitude: The altitude stored in the image. Altitude float64 `json:"altitude,omitempty"` // Latitude: The latitude stored in the image. Latitude float64 `json:"latitude,omitempty"` // Longitude: The longitude stored in the image. Longitude float64 `json:"longitude,omitempty"` // ForceSendFields is a list of field names (e.g. "Altitude") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileImageMediaMetadataLocation: Geographic location information stored in the image.
func (*FileImageMediaMetadataLocation) MarshalJSON ¶
func (s *FileImageMediaMetadataLocation) MarshalJSON() ([]byte, error)
type FileList ¶
type FileList struct { // Files: The page of files. Files []*File `json:"files,omitempty"` // Kind: This is always drive#fileList. Kind string `json:"kind,omitempty"` // NextPageToken: The page token for the next page of files. This will // be absent if the end of the files list has been reached. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Files") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileList: A list of files.
func (*FileList) MarshalJSON ¶
type FileVideoMediaMetadata ¶
type FileVideoMediaMetadata struct { // DurationMillis: The duration of the video in milliseconds. DurationMillis int64 `json:"durationMillis,omitempty,string"` // Height: The height of the video in pixels. Height int64 `json:"height,omitempty"` // Width: The width of the video in pixels. Width int64 `json:"width,omitempty"` // ForceSendFields is a list of field names (e.g. "DurationMillis") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
FileVideoMediaMetadata: Additional metadata about video media. This may not be available immediately upon upload.
func (*FileVideoMediaMetadata) MarshalJSON ¶
func (s *FileVideoMediaMetadata) MarshalJSON() ([]byte, error)
type FilesCopyCall ¶
type FilesCopyCall struct {
// contains filtered or unexported fields
}
func (*FilesCopyCall) Context ¶
func (c *FilesCopyCall) Context(ctx context.Context) *FilesCopyCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesCopyCall) Do ¶
func (c *FilesCopyCall) Do() (*File, error)
Do executes the "drive.files.copy" call. Exactly one of *File or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *File.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesCopyCall) Fields ¶
func (c *FilesCopyCall) Fields(s ...googleapi.Field) *FilesCopyCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesCopyCall) IgnoreDefaultVisibility ¶
func (c *FilesCopyCall) IgnoreDefaultVisibility(ignoreDefaultVisibility bool) *FilesCopyCall
IgnoreDefaultVisibility sets the optional parameter "ignoreDefaultVisibility": Whether to ignore the domain's default visibility settings for the created file. Domain administrators can choose to make all uploaded files visible to the domain by default; this parameter bypasses that behavior for the request. Permissions are still inherited from parent folders.
func (*FilesCopyCall) KeepRevisionForever ¶
func (c *FilesCopyCall) KeepRevisionForever(keepRevisionForever bool) *FilesCopyCall
KeepRevisionForever sets the optional parameter "keepRevisionForever": Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Drive.
func (*FilesCopyCall) OcrLanguage ¶
func (c *FilesCopyCall) OcrLanguage(ocrLanguage string) *FilesCopyCall
OcrLanguage sets the optional parameter "ocrLanguage": A language hint for OCR processing during image import (ISO 639-1 code).
func (*FilesCopyCall) QuotaUser ¶
func (c *FilesCopyCall) QuotaUser(quotaUser string) *FilesCopyCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesCopyCall) UserIP ¶
func (c *FilesCopyCall) UserIP(userIP string) *FilesCopyCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesCreateCall ¶
type FilesCreateCall struct {
// contains filtered or unexported fields
}
func (*FilesCreateCall) Context ¶
func (c *FilesCreateCall) Context(ctx context.Context) *FilesCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled. This context will supersede any context previously provided to the ResumableMedia method.
func (*FilesCreateCall) Do ¶
func (c *FilesCreateCall) Do() (*File, error)
Do executes the "drive.files.create" call. Exactly one of *File or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *File.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesCreateCall) Fields ¶
func (c *FilesCreateCall) Fields(s ...googleapi.Field) *FilesCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesCreateCall) IgnoreDefaultVisibility ¶
func (c *FilesCreateCall) IgnoreDefaultVisibility(ignoreDefaultVisibility bool) *FilesCreateCall
IgnoreDefaultVisibility sets the optional parameter "ignoreDefaultVisibility": Whether to ignore the domain's default visibility settings for the created file. Domain administrators can choose to make all uploaded files visible to the domain by default; this parameter bypasses that behavior for the request. Permissions are still inherited from parent folders.
func (*FilesCreateCall) KeepRevisionForever ¶
func (c *FilesCreateCall) KeepRevisionForever(keepRevisionForever bool) *FilesCreateCall
KeepRevisionForever sets the optional parameter "keepRevisionForever": Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Drive.
func (*FilesCreateCall) Media ¶
func (c *FilesCreateCall) Media(r io.Reader) *FilesCreateCall
Media specifies the media to upload in a single chunk. At most one of Media and ResumableMedia may be set.
func (*FilesCreateCall) OcrLanguage ¶
func (c *FilesCreateCall) OcrLanguage(ocrLanguage string) *FilesCreateCall
OcrLanguage sets the optional parameter "ocrLanguage": A language hint for OCR processing during image import (ISO 639-1 code).
func (*FilesCreateCall) ProgressUpdater ¶
func (c *FilesCreateCall) ProgressUpdater(pu googleapi.ProgressUpdater) *FilesCreateCall
ProgressUpdater provides a callback function that will be called after every chunk. It should be a low-latency function in order to not slow down the upload operation. This should only be called when using ResumableMedia (as opposed to Media).
func (*FilesCreateCall) QuotaUser ¶
func (c *FilesCreateCall) QuotaUser(quotaUser string) *FilesCreateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesCreateCall) ResumableMedia ¶
func (c *FilesCreateCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *FilesCreateCall
ResumableMedia specifies the media to upload in chunks and can be canceled with ctx. At most one of Media and ResumableMedia may be set. mediaType identifies the MIME media type of the upload, such as "image/png". If mediaType is "", it will be auto-detected. The provided ctx will supersede any context previously provided to the Context method.
func (*FilesCreateCall) UseContentAsIndexableText ¶
func (c *FilesCreateCall) UseContentAsIndexableText(useContentAsIndexableText bool) *FilesCreateCall
UseContentAsIndexableText sets the optional parameter "useContentAsIndexableText": Whether to use the uploaded content as indexable text.
func (*FilesCreateCall) UserIP ¶
func (c *FilesCreateCall) UserIP(userIP string) *FilesCreateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesDeleteCall ¶
type FilesDeleteCall struct {
// contains filtered or unexported fields
}
func (*FilesDeleteCall) Context ¶
func (c *FilesDeleteCall) Context(ctx context.Context) *FilesDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesDeleteCall) Do ¶
func (c *FilesDeleteCall) Do() error
Do executes the "drive.files.delete" call.
func (*FilesDeleteCall) Fields ¶
func (c *FilesDeleteCall) Fields(s ...googleapi.Field) *FilesDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesDeleteCall) QuotaUser ¶
func (c *FilesDeleteCall) QuotaUser(quotaUser string) *FilesDeleteCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesDeleteCall) UserIP ¶
func (c *FilesDeleteCall) UserIP(userIP string) *FilesDeleteCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesEmptyTrashCall ¶
type FilesEmptyTrashCall struct {
// contains filtered or unexported fields
}
func (*FilesEmptyTrashCall) Context ¶
func (c *FilesEmptyTrashCall) Context(ctx context.Context) *FilesEmptyTrashCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesEmptyTrashCall) Do ¶
func (c *FilesEmptyTrashCall) Do() error
Do executes the "drive.files.emptyTrash" call.
func (*FilesEmptyTrashCall) Fields ¶
func (c *FilesEmptyTrashCall) Fields(s ...googleapi.Field) *FilesEmptyTrashCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesEmptyTrashCall) QuotaUser ¶
func (c *FilesEmptyTrashCall) QuotaUser(quotaUser string) *FilesEmptyTrashCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesEmptyTrashCall) UserIP ¶
func (c *FilesEmptyTrashCall) UserIP(userIP string) *FilesEmptyTrashCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesExportCall ¶
type FilesExportCall struct {
// contains filtered or unexported fields
}
func (*FilesExportCall) Context ¶
func (c *FilesExportCall) Context(ctx context.Context) *FilesExportCall
Context sets the context to be used in this call's Do and Download methods. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesExportCall) Do ¶
func (c *FilesExportCall) Do() error
Do executes the "drive.files.export" call.
func (*FilesExportCall) Download ¶
func (c *FilesExportCall) Download() (*http.Response, error)
Download fetches the API endpoint's "media" value, instead of the normal API response value. If the returned error is nil, the Response is guaranteed to have a 2xx status code. Callers must close the Response.Body as usual.
func (*FilesExportCall) Fields ¶
func (c *FilesExportCall) Fields(s ...googleapi.Field) *FilesExportCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesExportCall) IfNoneMatch ¶
func (c *FilesExportCall) IfNoneMatch(entityTag string) *FilesExportCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*FilesExportCall) QuotaUser ¶
func (c *FilesExportCall) QuotaUser(quotaUser string) *FilesExportCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesExportCall) UserIP ¶
func (c *FilesExportCall) UserIP(userIP string) *FilesExportCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesGenerateIdsCall ¶
type FilesGenerateIdsCall struct {
// contains filtered or unexported fields
}
func (*FilesGenerateIdsCall) Context ¶
func (c *FilesGenerateIdsCall) Context(ctx context.Context) *FilesGenerateIdsCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesGenerateIdsCall) Count ¶
func (c *FilesGenerateIdsCall) Count(count int64) *FilesGenerateIdsCall
Count sets the optional parameter "count": The number of IDs to return.
func (*FilesGenerateIdsCall) Do ¶
func (c *FilesGenerateIdsCall) Do() (*GeneratedIds, error)
Do executes the "drive.files.generateIds" call. Exactly one of *GeneratedIds or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *GeneratedIds.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesGenerateIdsCall) Fields ¶
func (c *FilesGenerateIdsCall) Fields(s ...googleapi.Field) *FilesGenerateIdsCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesGenerateIdsCall) IfNoneMatch ¶
func (c *FilesGenerateIdsCall) IfNoneMatch(entityTag string) *FilesGenerateIdsCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*FilesGenerateIdsCall) QuotaUser ¶
func (c *FilesGenerateIdsCall) QuotaUser(quotaUser string) *FilesGenerateIdsCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesGenerateIdsCall) Space ¶
func (c *FilesGenerateIdsCall) Space(space string) *FilesGenerateIdsCall
Space sets the optional parameter "space": The space in which the IDs can be used to create new files. Supported values are 'drive' and 'appDataFolder'.
func (*FilesGenerateIdsCall) UserIP ¶
func (c *FilesGenerateIdsCall) UserIP(userIP string) *FilesGenerateIdsCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesGetCall ¶
type FilesGetCall struct {
// contains filtered or unexported fields
}
func (*FilesGetCall) AcknowledgeAbuse ¶
func (c *FilesGetCall) AcknowledgeAbuse(acknowledgeAbuse bool) *FilesGetCall
AcknowledgeAbuse sets the optional parameter "acknowledgeAbuse": Whether the user is acknowledging the risk of downloading known malware or other abusive files. This is only applicable when alt=media.
func (*FilesGetCall) Context ¶
func (c *FilesGetCall) Context(ctx context.Context) *FilesGetCall
Context sets the context to be used in this call's Do and Download methods. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesGetCall) Do ¶
func (c *FilesGetCall) Do() (*File, error)
Do executes the "drive.files.get" call. Exactly one of *File or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *File.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesGetCall) Download ¶
func (c *FilesGetCall) Download() (*http.Response, error)
Download fetches the API endpoint's "media" value, instead of the normal API response value. If the returned error is nil, the Response is guaranteed to have a 2xx status code. Callers must close the Response.Body as usual.
func (*FilesGetCall) Fields ¶
func (c *FilesGetCall) Fields(s ...googleapi.Field) *FilesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesGetCall) IfNoneMatch ¶
func (c *FilesGetCall) IfNoneMatch(entityTag string) *FilesGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*FilesGetCall) QuotaUser ¶
func (c *FilesGetCall) QuotaUser(quotaUser string) *FilesGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesGetCall) UserIP ¶
func (c *FilesGetCall) UserIP(userIP string) *FilesGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesListCall ¶
type FilesListCall struct {
// contains filtered or unexported fields
}
func (*FilesListCall) Context ¶
func (c *FilesListCall) Context(ctx context.Context) *FilesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesListCall) Corpus ¶
func (c *FilesListCall) Corpus(corpus string) *FilesListCall
Corpus sets the optional parameter "corpus": The source of files to list.
Possible values:
"domain" - Files shared to the user's domain. "user" (default) - Files owned by or shared to the user.
func (*FilesListCall) Do ¶
func (c *FilesListCall) Do() (*FileList, error)
Do executes the "drive.files.list" call. Exactly one of *FileList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *FileList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesListCall) Fields ¶
func (c *FilesListCall) Fields(s ...googleapi.Field) *FilesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesListCall) IfNoneMatch ¶
func (c *FilesListCall) IfNoneMatch(entityTag string) *FilesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*FilesListCall) OrderBy ¶
func (c *FilesListCall) OrderBy(orderBy string) *FilesListCall
OrderBy sets the optional parameter "orderBy": A comma-separated list of sort keys. Valid keys are 'createdTime', 'folder', 'modifiedByMeTime', 'modifiedTime', 'name', 'quotaBytesUsed', 'recency', 'sharedWithMeTime', 'starred', and 'viewedByMeTime'. Each key sorts ascending by default, but may be reversed with the 'desc' modifier. Example usage: ?orderBy=folder,modifiedTime desc,name. Please note that there is a current limitation for users with approximately one million files in which the requested sort order is ignored.
func (*FilesListCall) PageSize ¶
func (c *FilesListCall) PageSize(pageSize int64) *FilesListCall
PageSize sets the optional parameter "pageSize": The maximum number of files to return per page.
func (*FilesListCall) PageToken ¶
func (c *FilesListCall) PageToken(pageToken string) *FilesListCall
PageToken sets the optional parameter "pageToken": The token for continuing a previous list request on the next page. This should be set to the value of 'nextPageToken' from the previous response.
func (*FilesListCall) Q ¶
func (c *FilesListCall) Q(q string) *FilesListCall
Q sets the optional parameter "q": A query for filtering the file results. See the "Search for Files" guide for supported syntax.
func (*FilesListCall) QuotaUser ¶
func (c *FilesListCall) QuotaUser(quotaUser string) *FilesListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesListCall) Spaces ¶
func (c *FilesListCall) Spaces(spaces string) *FilesListCall
Spaces sets the optional parameter "spaces": A comma-separated list of spaces to query within the corpus. Supported values are 'drive', 'appDataFolder' and 'photos'.
func (*FilesListCall) UserIP ¶
func (c *FilesListCall) UserIP(userIP string) *FilesListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesService ¶
type FilesService struct {
// contains filtered or unexported fields
}
func NewFilesService ¶
func NewFilesService(s *Service) *FilesService
func (*FilesService) Copy ¶
func (r *FilesService) Copy(fileId string, file *File) *FilesCopyCall
Copy: Creates a copy of a file and applies any requested updates with patch semantics.
func (*FilesService) Create ¶
func (r *FilesService) Create(file *File) *FilesCreateCall
Create: Creates a new file.
func (*FilesService) Delete ¶
func (r *FilesService) Delete(fileId string) *FilesDeleteCall
Delete: Permanently deletes a file owned by the user without moving it to the trash. If the target is a folder, all descendants owned by the user are also deleted.
func (*FilesService) EmptyTrash ¶
func (r *FilesService) EmptyTrash() *FilesEmptyTrashCall
EmptyTrash: Permanently deletes all of the user's trashed files.
func (*FilesService) Export ¶
func (r *FilesService) Export(fileId string, mimeType string) *FilesExportCall
Export: Exports a Google Doc to the requested MIME type.
func (*FilesService) GenerateIds ¶
func (r *FilesService) GenerateIds() *FilesGenerateIdsCall
GenerateIds: Generates a set of file IDs which can be provided in create requests.
func (*FilesService) Get ¶
func (r *FilesService) Get(fileId string) *FilesGetCall
Get: Gets a file's metadata or content by ID.
func (*FilesService) List ¶
func (r *FilesService) List() *FilesListCall
List: Lists or searches files.
func (*FilesService) Update ¶
func (r *FilesService) Update(fileId string, file *File) *FilesUpdateCall
Update: Updates a file's metadata and/or content with patch semantics.
func (*FilesService) Watch ¶
func (r *FilesService) Watch(fileId string, channel *Channel) *FilesWatchCall
Watch: Subscribes to changes to a file
type FilesUpdateCall ¶
type FilesUpdateCall struct {
// contains filtered or unexported fields
}
func (*FilesUpdateCall) AddParents ¶
func (c *FilesUpdateCall) AddParents(addParents string) *FilesUpdateCall
AddParents sets the optional parameter "addParents": A comma-separated list of parent IDs to add.
func (*FilesUpdateCall) Context ¶
func (c *FilesUpdateCall) Context(ctx context.Context) *FilesUpdateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled. This context will supersede any context previously provided to the ResumableMedia method.
func (*FilesUpdateCall) Do ¶
func (c *FilesUpdateCall) Do() (*File, error)
Do executes the "drive.files.update" call. Exactly one of *File or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *File.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesUpdateCall) Fields ¶
func (c *FilesUpdateCall) Fields(s ...googleapi.Field) *FilesUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesUpdateCall) KeepRevisionForever ¶
func (c *FilesUpdateCall) KeepRevisionForever(keepRevisionForever bool) *FilesUpdateCall
KeepRevisionForever sets the optional parameter "keepRevisionForever": Whether to set the 'keepForever' field in the new head revision. This is only applicable to files with binary content in Drive.
func (*FilesUpdateCall) Media ¶
func (c *FilesUpdateCall) Media(r io.Reader) *FilesUpdateCall
Media specifies the media to upload in a single chunk. At most one of Media and ResumableMedia may be set.
func (*FilesUpdateCall) OcrLanguage ¶
func (c *FilesUpdateCall) OcrLanguage(ocrLanguage string) *FilesUpdateCall
OcrLanguage sets the optional parameter "ocrLanguage": A language hint for OCR processing during image import (ISO 639-1 code).
func (*FilesUpdateCall) ProgressUpdater ¶
func (c *FilesUpdateCall) ProgressUpdater(pu googleapi.ProgressUpdater) *FilesUpdateCall
ProgressUpdater provides a callback function that will be called after every chunk. It should be a low-latency function in order to not slow down the upload operation. This should only be called when using ResumableMedia (as opposed to Media).
func (*FilesUpdateCall) QuotaUser ¶
func (c *FilesUpdateCall) QuotaUser(quotaUser string) *FilesUpdateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesUpdateCall) RemoveParents ¶
func (c *FilesUpdateCall) RemoveParents(removeParents string) *FilesUpdateCall
RemoveParents sets the optional parameter "removeParents": A comma-separated list of parent IDs to remove.
func (*FilesUpdateCall) ResumableMedia ¶
func (c *FilesUpdateCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *FilesUpdateCall
ResumableMedia specifies the media to upload in chunks and can be canceled with ctx. At most one of Media and ResumableMedia may be set. mediaType identifies the MIME media type of the upload, such as "image/png". If mediaType is "", it will be auto-detected. The provided ctx will supersede any context previously provided to the Context method.
func (*FilesUpdateCall) UseContentAsIndexableText ¶
func (c *FilesUpdateCall) UseContentAsIndexableText(useContentAsIndexableText bool) *FilesUpdateCall
UseContentAsIndexableText sets the optional parameter "useContentAsIndexableText": Whether to use the uploaded content as indexable text.
func (*FilesUpdateCall) UserIP ¶
func (c *FilesUpdateCall) UserIP(userIP string) *FilesUpdateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type FilesWatchCall ¶
type FilesWatchCall struct {
// contains filtered or unexported fields
}
func (*FilesWatchCall) AcknowledgeAbuse ¶
func (c *FilesWatchCall) AcknowledgeAbuse(acknowledgeAbuse bool) *FilesWatchCall
AcknowledgeAbuse sets the optional parameter "acknowledgeAbuse": Whether the user is acknowledging the risk of downloading known malware or other abusive files. This is only applicable when alt=media.
func (*FilesWatchCall) Context ¶
func (c *FilesWatchCall) Context(ctx context.Context) *FilesWatchCall
Context sets the context to be used in this call's Do and Download methods. Any pending HTTP request will be aborted if the provided context is canceled.
func (*FilesWatchCall) Do ¶
func (c *FilesWatchCall) Do() (*Channel, error)
Do executes the "drive.files.watch" call. Exactly one of *Channel or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Channel.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*FilesWatchCall) Download ¶
func (c *FilesWatchCall) Download() (*http.Response, error)
Download fetches the API endpoint's "media" value, instead of the normal API response value. If the returned error is nil, the Response is guaranteed to have a 2xx status code. Callers must close the Response.Body as usual.
func (*FilesWatchCall) Fields ¶
func (c *FilesWatchCall) Fields(s ...googleapi.Field) *FilesWatchCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*FilesWatchCall) QuotaUser ¶
func (c *FilesWatchCall) QuotaUser(quotaUser string) *FilesWatchCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*FilesWatchCall) UserIP ¶
func (c *FilesWatchCall) UserIP(userIP string) *FilesWatchCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type GeneratedIds ¶
type GeneratedIds struct { // Ids: The IDs generated for the requesting user in the specified // space. Ids []string `json:"ids,omitempty"` // Kind: This is always drive#generatedIds Kind string `json:"kind,omitempty"` // Space: The type of file that can be created with these IDs. Space string `json:"space,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Ids") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
GeneratedIds: A list of generated file IDs which can be provided in create requests.
func (*GeneratedIds) MarshalJSON ¶
func (s *GeneratedIds) MarshalJSON() ([]byte, error)
type Permission ¶
type Permission struct { // AllowFileDiscovery: Whether the permission allows the file to be // discovered through search. This is only applicable for permissions of // type domain or anyone. AllowFileDiscovery bool `json:"allowFileDiscovery,omitempty"` // DisplayName: A displayable name for users, groups or domains. DisplayName string `json:"displayName,omitempty"` // Domain: The domain to which this permission refers. Domain string `json:"domain,omitempty"` // EmailAddress: The email address of the user or group to which this // permission refers. EmailAddress string `json:"emailAddress,omitempty"` // Id: The ID of this permission. This is a unique identifier for the // grantee, and is published in User resources as permissionId. Id string `json:"id,omitempty"` // Kind: This is always drive#permission. Kind string `json:"kind,omitempty"` // PhotoLink: A link to the user's profile photo, if available. PhotoLink string `json:"photoLink,omitempty"` // Role: The role granted by this permission. Valid values are: // - owner // - writer // - commenter // - reader Role string `json:"role,omitempty"` // Type: The type of the grantee. Valid values are: // - user // - group // - domain // - anyone Type string `json:"type,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "AllowFileDiscovery") // to unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Permission: A permission for a file. A permission grants a user, group, domain or the world access to a file or a folder hierarchy.
func (*Permission) MarshalJSON ¶
func (s *Permission) MarshalJSON() ([]byte, error)
type PermissionList ¶
type PermissionList struct { // Kind: This is always drive#permissionList. Kind string `json:"kind,omitempty"` // Permissions: The full list of permissions. Permissions []*Permission `json:"permissions,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Kind") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
PermissionList: A list of permissions for a file.
func (*PermissionList) MarshalJSON ¶
func (s *PermissionList) MarshalJSON() ([]byte, error)
type PermissionsCreateCall ¶
type PermissionsCreateCall struct {
// contains filtered or unexported fields
}
func (*PermissionsCreateCall) Context ¶
func (c *PermissionsCreateCall) Context(ctx context.Context) *PermissionsCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*PermissionsCreateCall) Do ¶
func (c *PermissionsCreateCall) Do() (*Permission, error)
Do executes the "drive.permissions.create" call. Exactly one of *Permission or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Permission.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*PermissionsCreateCall) EmailMessage ¶
func (c *PermissionsCreateCall) EmailMessage(emailMessage string) *PermissionsCreateCall
EmailMessage sets the optional parameter "emailMessage": A custom message to include in the notification email.
func (*PermissionsCreateCall) Fields ¶
func (c *PermissionsCreateCall) Fields(s ...googleapi.Field) *PermissionsCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*PermissionsCreateCall) QuotaUser ¶
func (c *PermissionsCreateCall) QuotaUser(quotaUser string) *PermissionsCreateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*PermissionsCreateCall) SendNotificationEmail ¶
func (c *PermissionsCreateCall) SendNotificationEmail(sendNotificationEmail bool) *PermissionsCreateCall
SendNotificationEmail sets the optional parameter "sendNotificationEmail": Whether to send a notification email when sharing to users or groups. This defaults to true for users and groups, and is not allowed for other requests. It must not be disabled for ownership transfers.
func (*PermissionsCreateCall) TransferOwnership ¶
func (c *PermissionsCreateCall) TransferOwnership(transferOwnership bool) *PermissionsCreateCall
TransferOwnership sets the optional parameter "transferOwnership": Whether to transfer ownership to the specified user and downgrade the current owner to a writer. This parameter is required as an acknowledgement of the side effect.
func (*PermissionsCreateCall) UserIP ¶
func (c *PermissionsCreateCall) UserIP(userIP string) *PermissionsCreateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type PermissionsDeleteCall ¶
type PermissionsDeleteCall struct {
// contains filtered or unexported fields
}
func (*PermissionsDeleteCall) Context ¶
func (c *PermissionsDeleteCall) Context(ctx context.Context) *PermissionsDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*PermissionsDeleteCall) Do ¶
func (c *PermissionsDeleteCall) Do() error
Do executes the "drive.permissions.delete" call.
func (*PermissionsDeleteCall) Fields ¶
func (c *PermissionsDeleteCall) Fields(s ...googleapi.Field) *PermissionsDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*PermissionsDeleteCall) QuotaUser ¶
func (c *PermissionsDeleteCall) QuotaUser(quotaUser string) *PermissionsDeleteCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*PermissionsDeleteCall) UserIP ¶
func (c *PermissionsDeleteCall) UserIP(userIP string) *PermissionsDeleteCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type PermissionsGetCall ¶
type PermissionsGetCall struct {
// contains filtered or unexported fields
}
func (*PermissionsGetCall) Context ¶
func (c *PermissionsGetCall) Context(ctx context.Context) *PermissionsGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*PermissionsGetCall) Do ¶
func (c *PermissionsGetCall) Do() (*Permission, error)
Do executes the "drive.permissions.get" call. Exactly one of *Permission or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Permission.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*PermissionsGetCall) Fields ¶
func (c *PermissionsGetCall) Fields(s ...googleapi.Field) *PermissionsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*PermissionsGetCall) IfNoneMatch ¶
func (c *PermissionsGetCall) IfNoneMatch(entityTag string) *PermissionsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*PermissionsGetCall) QuotaUser ¶
func (c *PermissionsGetCall) QuotaUser(quotaUser string) *PermissionsGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*PermissionsGetCall) UserIP ¶
func (c *PermissionsGetCall) UserIP(userIP string) *PermissionsGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type PermissionsListCall ¶
type PermissionsListCall struct {
// contains filtered or unexported fields
}
func (*PermissionsListCall) Context ¶
func (c *PermissionsListCall) Context(ctx context.Context) *PermissionsListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*PermissionsListCall) Do ¶
func (c *PermissionsListCall) Do() (*PermissionList, error)
Do executes the "drive.permissions.list" call. Exactly one of *PermissionList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *PermissionList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*PermissionsListCall) Fields ¶
func (c *PermissionsListCall) Fields(s ...googleapi.Field) *PermissionsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*PermissionsListCall) IfNoneMatch ¶
func (c *PermissionsListCall) IfNoneMatch(entityTag string) *PermissionsListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*PermissionsListCall) QuotaUser ¶
func (c *PermissionsListCall) QuotaUser(quotaUser string) *PermissionsListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*PermissionsListCall) UserIP ¶
func (c *PermissionsListCall) UserIP(userIP string) *PermissionsListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type PermissionsService ¶
type PermissionsService struct {
// contains filtered or unexported fields
}
func NewPermissionsService ¶
func NewPermissionsService(s *Service) *PermissionsService
func (*PermissionsService) Create ¶
func (r *PermissionsService) Create(fileId string, permission *Permission) *PermissionsCreateCall
Create: Creates a permission for a file.
func (*PermissionsService) Delete ¶
func (r *PermissionsService) Delete(fileId string, permissionId string) *PermissionsDeleteCall
Delete: Deletes a permission.
func (*PermissionsService) Get ¶
func (r *PermissionsService) Get(fileId string, permissionId string) *PermissionsGetCall
Get: Gets a permission by ID.
func (*PermissionsService) List ¶
func (r *PermissionsService) List(fileId string) *PermissionsListCall
List: Lists a file's permissions.
func (*PermissionsService) Update ¶
func (r *PermissionsService) Update(fileId string, permissionId string, permission *Permission) *PermissionsUpdateCall
Update: Updates a permission with patch semantics.
type PermissionsUpdateCall ¶
type PermissionsUpdateCall struct {
// contains filtered or unexported fields
}
func (*PermissionsUpdateCall) Context ¶
func (c *PermissionsUpdateCall) Context(ctx context.Context) *PermissionsUpdateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*PermissionsUpdateCall) Do ¶
func (c *PermissionsUpdateCall) Do() (*Permission, error)
Do executes the "drive.permissions.update" call. Exactly one of *Permission or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Permission.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*PermissionsUpdateCall) Fields ¶
func (c *PermissionsUpdateCall) Fields(s ...googleapi.Field) *PermissionsUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*PermissionsUpdateCall) QuotaUser ¶
func (c *PermissionsUpdateCall) QuotaUser(quotaUser string) *PermissionsUpdateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*PermissionsUpdateCall) TransferOwnership ¶
func (c *PermissionsUpdateCall) TransferOwnership(transferOwnership bool) *PermissionsUpdateCall
TransferOwnership sets the optional parameter "transferOwnership": Whether to transfer ownership to the specified user and downgrade the current owner to a writer. This parameter is required as an acknowledgement of the side effect.
func (*PermissionsUpdateCall) UserIP ¶
func (c *PermissionsUpdateCall) UserIP(userIP string) *PermissionsUpdateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RepliesCreateCall ¶
type RepliesCreateCall struct {
// contains filtered or unexported fields
}
func (*RepliesCreateCall) Context ¶
func (c *RepliesCreateCall) Context(ctx context.Context) *RepliesCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RepliesCreateCall) Do ¶
func (c *RepliesCreateCall) Do() (*Reply, error)
Do executes the "drive.replies.create" call. Exactly one of *Reply or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Reply.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RepliesCreateCall) Fields ¶
func (c *RepliesCreateCall) Fields(s ...googleapi.Field) *RepliesCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RepliesCreateCall) QuotaUser ¶
func (c *RepliesCreateCall) QuotaUser(quotaUser string) *RepliesCreateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RepliesCreateCall) UserIP ¶
func (c *RepliesCreateCall) UserIP(userIP string) *RepliesCreateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RepliesDeleteCall ¶
type RepliesDeleteCall struct {
// contains filtered or unexported fields
}
func (*RepliesDeleteCall) Context ¶
func (c *RepliesDeleteCall) Context(ctx context.Context) *RepliesDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RepliesDeleteCall) Do ¶
func (c *RepliesDeleteCall) Do() error
Do executes the "drive.replies.delete" call.
func (*RepliesDeleteCall) Fields ¶
func (c *RepliesDeleteCall) Fields(s ...googleapi.Field) *RepliesDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RepliesDeleteCall) QuotaUser ¶
func (c *RepliesDeleteCall) QuotaUser(quotaUser string) *RepliesDeleteCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RepliesDeleteCall) UserIP ¶
func (c *RepliesDeleteCall) UserIP(userIP string) *RepliesDeleteCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RepliesGetCall ¶
type RepliesGetCall struct {
// contains filtered or unexported fields
}
func (*RepliesGetCall) Context ¶
func (c *RepliesGetCall) Context(ctx context.Context) *RepliesGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RepliesGetCall) Do ¶
func (c *RepliesGetCall) Do() (*Reply, error)
Do executes the "drive.replies.get" call. Exactly one of *Reply or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Reply.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RepliesGetCall) Fields ¶
func (c *RepliesGetCall) Fields(s ...googleapi.Field) *RepliesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RepliesGetCall) IfNoneMatch ¶
func (c *RepliesGetCall) IfNoneMatch(entityTag string) *RepliesGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*RepliesGetCall) IncludeDeleted ¶
func (c *RepliesGetCall) IncludeDeleted(includeDeleted bool) *RepliesGetCall
IncludeDeleted sets the optional parameter "includeDeleted": Whether to return deleted replies. Deleted replies will not include their original content.
func (*RepliesGetCall) QuotaUser ¶
func (c *RepliesGetCall) QuotaUser(quotaUser string) *RepliesGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RepliesGetCall) UserIP ¶
func (c *RepliesGetCall) UserIP(userIP string) *RepliesGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RepliesListCall ¶
type RepliesListCall struct {
// contains filtered or unexported fields
}
func (*RepliesListCall) Context ¶
func (c *RepliesListCall) Context(ctx context.Context) *RepliesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RepliesListCall) Do ¶
func (c *RepliesListCall) Do() (*ReplyList, error)
Do executes the "drive.replies.list" call. Exactly one of *ReplyList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ReplyList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RepliesListCall) Fields ¶
func (c *RepliesListCall) Fields(s ...googleapi.Field) *RepliesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RepliesListCall) IfNoneMatch ¶
func (c *RepliesListCall) IfNoneMatch(entityTag string) *RepliesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*RepliesListCall) IncludeDeleted ¶
func (c *RepliesListCall) IncludeDeleted(includeDeleted bool) *RepliesListCall
IncludeDeleted sets the optional parameter "includeDeleted": Whether to include deleted replies. Deleted replies will not include their original content.
func (*RepliesListCall) PageSize ¶
func (c *RepliesListCall) PageSize(pageSize int64) *RepliesListCall
PageSize sets the optional parameter "pageSize": The maximum number of replies to return per page.
func (*RepliesListCall) PageToken ¶
func (c *RepliesListCall) PageToken(pageToken string) *RepliesListCall
PageToken sets the optional parameter "pageToken": The token for continuing a previous list request on the next page. This should be set to the value of 'nextPageToken' from the previous response.
func (*RepliesListCall) QuotaUser ¶
func (c *RepliesListCall) QuotaUser(quotaUser string) *RepliesListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RepliesListCall) UserIP ¶
func (c *RepliesListCall) UserIP(userIP string) *RepliesListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RepliesService ¶
type RepliesService struct {
// contains filtered or unexported fields
}
func NewRepliesService ¶
func NewRepliesService(s *Service) *RepliesService
func (*RepliesService) Create ¶
func (r *RepliesService) Create(fileId string, commentId string, reply *Reply) *RepliesCreateCall
Create: Creates a new reply to a comment.
func (*RepliesService) Delete ¶
func (r *RepliesService) Delete(fileId string, commentId string, replyId string) *RepliesDeleteCall
Delete: Deletes a reply.
func (*RepliesService) Get ¶
func (r *RepliesService) Get(fileId string, commentId string, replyId string) *RepliesGetCall
Get: Gets a reply by ID.
func (*RepliesService) List ¶
func (r *RepliesService) List(fileId string, commentId string) *RepliesListCall
List: Lists a comment's replies.
func (*RepliesService) Update ¶
func (r *RepliesService) Update(fileId string, commentId string, replyId string, reply *Reply) *RepliesUpdateCall
Update: Updates a reply with patch semantics.
type RepliesUpdateCall ¶
type RepliesUpdateCall struct {
// contains filtered or unexported fields
}
func (*RepliesUpdateCall) Context ¶
func (c *RepliesUpdateCall) Context(ctx context.Context) *RepliesUpdateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RepliesUpdateCall) Do ¶
func (c *RepliesUpdateCall) Do() (*Reply, error)
Do executes the "drive.replies.update" call. Exactly one of *Reply or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Reply.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RepliesUpdateCall) Fields ¶
func (c *RepliesUpdateCall) Fields(s ...googleapi.Field) *RepliesUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RepliesUpdateCall) QuotaUser ¶
func (c *RepliesUpdateCall) QuotaUser(quotaUser string) *RepliesUpdateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RepliesUpdateCall) UserIP ¶
func (c *RepliesUpdateCall) UserIP(userIP string) *RepliesUpdateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type Reply ¶
type Reply struct { // Action: The action the reply performed to the parent comment. Valid // values are: // - resolve // - reopen Action string `json:"action,omitempty"` // Author: The user who created the reply. Author *User `json:"author,omitempty"` // Content: The plain text content of the reply. This field is used for // setting the content, while htmlContent should be displayed. This is // required on creates if no action is specified. Content string `json:"content,omitempty"` // CreatedTime: The time at which the reply was created (RFC 3339 // date-time). CreatedTime string `json:"createdTime,omitempty"` // Deleted: Whether the reply has been deleted. A deleted reply has no // content. Deleted bool `json:"deleted,omitempty"` // HtmlContent: The content of the reply with HTML formatting. HtmlContent string `json:"htmlContent,omitempty"` // Id: The ID of the reply. Id string `json:"id,omitempty"` // Kind: This is always drive#reply. Kind string `json:"kind,omitempty"` // ModifiedTime: The last time the reply was modified (RFC 3339 // date-time). ModifiedTime string `json:"modifiedTime,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Action") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Reply: A reply to a comment on a file.
func (*Reply) MarshalJSON ¶
type ReplyList ¶
type ReplyList struct { // Kind: This is always drive#replyList. Kind string `json:"kind,omitempty"` // NextPageToken: The page token for the next page of replies. This will // be absent if the end of the replies list has been reached. NextPageToken string `json:"nextPageToken,omitempty"` // Replies: The page of replies. Replies []*Reply `json:"replies,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Kind") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
ReplyList: A list of replies to a comment on a file.
func (*ReplyList) MarshalJSON ¶
type Revision ¶
type Revision struct { // Id: The ID of the revision. Id string `json:"id,omitempty"` // KeepForever: Whether to keep this revision forever, even if it is no // longer the head revision. If not set, the revision will be // automatically purged 30 days after newer content is uploaded. This // can be set on a maximum of 200 revisions for a file. // This field is only applicable to files with binary content in Drive. KeepForever bool `json:"keepForever,omitempty"` // Kind: This is always drive#revision. Kind string `json:"kind,omitempty"` // LastModifyingUser: The last user to modify this revision. LastModifyingUser *User `json:"lastModifyingUser,omitempty"` // Md5Checksum: The MD5 checksum of the revision's content. This is only // applicable to files with binary content in Drive. Md5Checksum string `json:"md5Checksum,omitempty"` // MimeType: The MIME type of the revision. MimeType string `json:"mimeType,omitempty"` // ModifiedTime: The last time the revision was modified (RFC 3339 // date-time). ModifiedTime string `json:"modifiedTime,omitempty"` // OriginalFilename: The original filename used to create this revision. // This is only applicable to files with binary content in Drive. OriginalFilename string `json:"originalFilename,omitempty"` // PublishAuto: Whether subsequent revisions will be automatically // republished. This is only applicable to Google Docs. PublishAuto bool `json:"publishAuto,omitempty"` // Published: Whether this revision is published. This is only // applicable to Google Docs. Published bool `json:"published,omitempty"` // PublishedOutsideDomain: Whether this revision is published outside // the domain. This is only applicable to Google Docs. PublishedOutsideDomain bool `json:"publishedOutsideDomain,omitempty"` // Size: The size of the revision's content in bytes. This is only // applicable to files with binary content in Drive. Size int64 `json:"size,omitempty,string"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Id") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
Revision: The metadata for a revision to a file.
func (*Revision) MarshalJSON ¶
type RevisionList ¶
type RevisionList struct { // Kind: This is always drive#revisionList. Kind string `json:"kind,omitempty"` // Revisions: The full list of revisions. Revisions []*Revision `json:"revisions,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Kind") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
RevisionList: A list of revisions of a file.
func (*RevisionList) MarshalJSON ¶
func (s *RevisionList) MarshalJSON() ([]byte, error)
type RevisionsDeleteCall ¶
type RevisionsDeleteCall struct {
// contains filtered or unexported fields
}
func (*RevisionsDeleteCall) Context ¶
func (c *RevisionsDeleteCall) Context(ctx context.Context) *RevisionsDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RevisionsDeleteCall) Do ¶
func (c *RevisionsDeleteCall) Do() error
Do executes the "drive.revisions.delete" call.
func (*RevisionsDeleteCall) Fields ¶
func (c *RevisionsDeleteCall) Fields(s ...googleapi.Field) *RevisionsDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RevisionsDeleteCall) QuotaUser ¶
func (c *RevisionsDeleteCall) QuotaUser(quotaUser string) *RevisionsDeleteCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RevisionsDeleteCall) UserIP ¶
func (c *RevisionsDeleteCall) UserIP(userIP string) *RevisionsDeleteCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RevisionsGetCall ¶
type RevisionsGetCall struct {
// contains filtered or unexported fields
}
func (*RevisionsGetCall) AcknowledgeAbuse ¶
func (c *RevisionsGetCall) AcknowledgeAbuse(acknowledgeAbuse bool) *RevisionsGetCall
AcknowledgeAbuse sets the optional parameter "acknowledgeAbuse": Whether the user is acknowledging the risk of downloading known malware or other abusive files. This is only applicable when alt=media.
func (*RevisionsGetCall) Context ¶
func (c *RevisionsGetCall) Context(ctx context.Context) *RevisionsGetCall
Context sets the context to be used in this call's Do and Download methods. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RevisionsGetCall) Do ¶
func (c *RevisionsGetCall) Do() (*Revision, error)
Do executes the "drive.revisions.get" call. Exactly one of *Revision or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Revision.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RevisionsGetCall) Download ¶
func (c *RevisionsGetCall) Download() (*http.Response, error)
Download fetches the API endpoint's "media" value, instead of the normal API response value. If the returned error is nil, the Response is guaranteed to have a 2xx status code. Callers must close the Response.Body as usual.
func (*RevisionsGetCall) Fields ¶
func (c *RevisionsGetCall) Fields(s ...googleapi.Field) *RevisionsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RevisionsGetCall) IfNoneMatch ¶
func (c *RevisionsGetCall) IfNoneMatch(entityTag string) *RevisionsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*RevisionsGetCall) QuotaUser ¶
func (c *RevisionsGetCall) QuotaUser(quotaUser string) *RevisionsGetCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RevisionsGetCall) UserIP ¶
func (c *RevisionsGetCall) UserIP(userIP string) *RevisionsGetCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RevisionsListCall ¶
type RevisionsListCall struct {
// contains filtered or unexported fields
}
func (*RevisionsListCall) Context ¶
func (c *RevisionsListCall) Context(ctx context.Context) *RevisionsListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RevisionsListCall) Do ¶
func (c *RevisionsListCall) Do() (*RevisionList, error)
Do executes the "drive.revisions.list" call. Exactly one of *RevisionList or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *RevisionList.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RevisionsListCall) Fields ¶
func (c *RevisionsListCall) Fields(s ...googleapi.Field) *RevisionsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RevisionsListCall) IfNoneMatch ¶
func (c *RevisionsListCall) IfNoneMatch(entityTag string) *RevisionsListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*RevisionsListCall) QuotaUser ¶
func (c *RevisionsListCall) QuotaUser(quotaUser string) *RevisionsListCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RevisionsListCall) UserIP ¶
func (c *RevisionsListCall) UserIP(userIP string) *RevisionsListCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type RevisionsService ¶
type RevisionsService struct {
// contains filtered or unexported fields
}
func NewRevisionsService ¶
func NewRevisionsService(s *Service) *RevisionsService
func (*RevisionsService) Delete ¶
func (r *RevisionsService) Delete(fileId string, revisionId string) *RevisionsDeleteCall
Delete: Permanently deletes a revision. This method is only applicable to files with binary content in Drive.
func (*RevisionsService) Get ¶
func (r *RevisionsService) Get(fileId string, revisionId string) *RevisionsGetCall
Get: Gets a revision's metadata or content by ID.
func (*RevisionsService) List ¶
func (r *RevisionsService) List(fileId string) *RevisionsListCall
List: Lists a file's revisions.
func (*RevisionsService) Update ¶
func (r *RevisionsService) Update(fileId string, revisionId string, revision *Revision) *RevisionsUpdateCall
Update: Updates a revision with patch semantics.
type RevisionsUpdateCall ¶
type RevisionsUpdateCall struct {
// contains filtered or unexported fields
}
func (*RevisionsUpdateCall) Context ¶
func (c *RevisionsUpdateCall) Context(ctx context.Context) *RevisionsUpdateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*RevisionsUpdateCall) Do ¶
func (c *RevisionsUpdateCall) Do() (*Revision, error)
Do executes the "drive.revisions.update" call. Exactly one of *Revision or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Revision.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*RevisionsUpdateCall) Fields ¶
func (c *RevisionsUpdateCall) Fields(s ...googleapi.Field) *RevisionsUpdateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*RevisionsUpdateCall) QuotaUser ¶
func (c *RevisionsUpdateCall) QuotaUser(quotaUser string) *RevisionsUpdateCall
QuotaUser sets the optional parameter "quotaUser": Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
func (*RevisionsUpdateCall) UserIP ¶
func (c *RevisionsUpdateCall) UserIP(userIP string) *RevisionsUpdateCall
UserIP sets the optional parameter "userIp": IP address of the site where the request originates. Use this if you want to enforce per-user limits.
type Service ¶
type Service struct { BasePath string // API endpoint base URL UserAgent string // optional additional User-Agent fragment About *AboutService Changes *ChangesService Channels *ChannelsService Comments *CommentsService Files *FilesService Permissions *PermissionsService Replies *RepliesService Revisions *RevisionsService // contains filtered or unexported fields }
type StartPageToken ¶
type StartPageToken struct { // Kind: This is always drive#startPageToken. Kind string `json:"kind,omitempty"` // StartPageToken: The starting page token for listing changes. StartPageToken string `json:"startPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Kind") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
func (*StartPageToken) MarshalJSON ¶
func (s *StartPageToken) MarshalJSON() ([]byte, error)
type User ¶
type User struct { // DisplayName: A plain text displayable name for this user. DisplayName string `json:"displayName,omitempty"` // EmailAddress: The email address of the user. This may not be present // in certain contexts if the user has not made their email address // visible to the requester. EmailAddress string `json:"emailAddress,omitempty"` // Kind: This is always drive#user. Kind string `json:"kind,omitempty"` // Me: Whether this user is the requesting user. Me bool `json:"me,omitempty"` // PermissionId: The user's ID as visible in Permission resources. PermissionId string `json:"permissionId,omitempty"` // PhotoLink: A link to the user's profile photo, if available. PhotoLink string `json:"photoLink,omitempty"` // ForceSendFields is a list of field names (e.g. "DisplayName") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` }
User: Information about a Drive user.