class Google::Apis::DriveV2::Revision

A revision of a file.

Attributes

download_url[RW]

Short term download URL for the file. This will only be populated on files with content stored in Drive. Corresponds to the JSON property `downloadUrl` @return [String]

etag[RW]

The ETag of the revision. Corresponds to the JSON property `etag` @return [String]

file_size[RW]

The size of the revision in bytes. This will only be populated on files with content stored in Drive. Corresponds to the JSON property `fileSize` @return [String]

id[RW]

The ID of the revision. Corresponds to the JSON property `id` @return [String]

kind[RW]

This is always drive#revision. Corresponds to the JSON property `kind` @return [String]

last_modifying_user[RW]

Information about a Drive user. Corresponds to the JSON property `lastModifyingUser` @return [Google::Apis::DriveV2::User]

last_modifying_user_name[RW]

Name of the last user to modify this revision. Corresponds to the JSON property `lastModifyingUserName` @return [String]

md5_checksum[RW]

An MD5 checksum for the content of this revision. This will only be populated on files with content stored in Drive. Corresponds to the JSON property `md5Checksum` @return [String]

mime_type[RW]

The MIME type of the revision. Corresponds to the JSON property `mimeType` @return [String]

modified_date[RW]

Last time this revision was modified (formatted RFC 3339 timestamp). Corresponds to the JSON property `modifiedDate` @return [DateTime]

original_filename[RW]

The original filename when this revision was created. This will only be populated on files with content stored in Drive. Corresponds to the JSON property `originalFilename` @return [String]

pinned[RW]

Whether this revision is pinned to prevent automatic purging. This will only be populated and can only be modified on files with content stored in Drive which are not Google Docs. Revisions can also be pinned when they are created through the drive.files.insert/update/copy by using the pinned query parameter. Corresponds to the JSON property `pinned` @return [Boolean]

pinned?[RW]

Whether this revision is pinned to prevent automatic purging. This will only be populated and can only be modified on files with content stored in Drive which are not Google Docs. Revisions can also be pinned when they are created through the drive.files.insert/update/copy by using the pinned query parameter. Corresponds to the JSON property `pinned` @return [Boolean]

publish_auto[RW]

Whether subsequent revisions will be automatically republished. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `publishAuto` @return [Boolean]

publish_auto?[RW]

Whether subsequent revisions will be automatically republished. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `publishAuto` @return [Boolean]

published[RW]

Whether this revision is published. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `published` @return [Boolean]

published?[RW]

Whether this revision is published. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `published` @return [Boolean]

published_outside_domain[RW]

Whether this revision is published outside the domain. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `publishedOutsideDomain` @return [Boolean]

published_outside_domain?[RW]

Whether this revision is published outside the domain. This is only populated and can only be modified for Google Docs. Corresponds to the JSON property `publishedOutsideDomain` @return [Boolean]

Public Class Methods

new(**args) click to toggle source
# File generated/google/apis/drive_v2/classes.rb, line 2440
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File generated/google/apis/drive_v2/classes.rb, line 2445
def update!(**args)
  @download_url = args[:download_url] if args.key?(:download_url)
  @etag = args[:etag] if args.key?(:etag)
  @export_links = args[:export_links] if args.key?(:export_links)
  @file_size = args[:file_size] if args.key?(:file_size)
  @id = args[:id] if args.key?(:id)
  @kind = args[:kind] if args.key?(:kind)
  @last_modifying_user = args[:last_modifying_user] if args.key?(:last_modifying_user)
  @last_modifying_user_name = args[:last_modifying_user_name] if args.key?(:last_modifying_user_name)
  @md5_checksum = args[:md5_checksum] if args.key?(:md5_checksum)
  @mime_type = args[:mime_type] if args.key?(:mime_type)
  @modified_date = args[:modified_date] if args.key?(:modified_date)
  @original_filename = args[:original_filename] if args.key?(:original_filename)
  @pinned = args[:pinned] if args.key?(:pinned)
  @publish_auto = args[:publish_auto] if args.key?(:publish_auto)
  @published = args[:published] if args.key?(:published)
  @published_link = args[:published_link] if args.key?(:published_link)
  @published_outside_domain = args[:published_outside_domain] if args.key?(:published_outside_domain)
  @self_link = args[:self_link] if args.key?(:self_link)
end