target.apidocs.com.google.api.services.drive.Drive.Revisions.html Maven / Gradle / Ivy
Drive.Revisions (Google Drive API v3-rev20240809-2.0.0)
com.google.api.services.drive
Class Drive.Revisions
- java.lang.Object
-
- com.google.api.services.drive.Drive.Revisions
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
class
Drive.Revisions.Delete
class
Drive.Revisions.Get
class
Drive.Revisions.List
class
Drive.Revisions.Update
-
Constructor Summary
Constructors
Constructor and Description
Revisions()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Drive.Revisions.Delete
delete(String fileId,
String revisionId)
Permanently deletes a file version.
Drive.Revisions.Get
get(String fileId,
String revisionId)
Gets a revision's metadata or content by ID.
Drive.Revisions.List
list(String fileId)
Lists a file's revisions.
Drive.Revisions.Update
update(String fileId,
String revisionId,
Revision content)
Updates a revision with patch semantics.
-
-
Method Detail
-
delete
public Drive.Revisions.Delete delete(String fileId,
String revisionId)
throws IOException
Permanently deletes a file version. You can only delete revisions for files with binary content
in Google Drive, like images or videos. Revisions for other files, like Google Docs or Sheets,
and the last remaining file version can't be deleted.
Create a request for the method "revisions.delete".
This request holds the parameters needed by the drive server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
fileId
- The ID of the file.
revisionId
- The ID of the revision.
- Returns:
- the request
- Throws:
IOException
-
get
public Drive.Revisions.Get get(String fileId,
String revisionId)
throws IOException
Gets a revision's metadata or content by ID.
Create a request for the method "revisions.get".
This request holds the parameters needed by the drive server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
fileId
- The ID of the file.
revisionId
- The ID of the revision.
- Returns:
- the request
- Throws:
IOException
-
list
public Drive.Revisions.List list(String fileId)
throws IOException
Lists a file's revisions.
Create a request for the method "revisions.list".
This request holds the parameters needed by the drive server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
fileId
- The ID of the file.
- Returns:
- the request
- Throws:
IOException
-
update
public Drive.Revisions.Update update(String fileId,
String revisionId,
Revision content)
throws IOException
Updates a revision with patch semantics.
Create a request for the method "revisions.update".
This request holds the parameters needed by the drive server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
fileId
- The ID of the file.
revisionId
- The ID of the revision.
content
- the Revision
- Returns:
- the request
- Throws:
IOException
Copyright © 2011–2024 Google. All rights reserved.