class Google::Apis::DriveV2::ContentRestriction
A restriction for accessing the content of the file.
Attributes
Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified. Corresponds to the JSON property `readOnly` @return [Boolean]
Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified. Corresponds to the JSON property `readOnly` @return [Boolean]
Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true. Corresponds to the JSON property `reason` @return [String]
Information about a Drive
user. Corresponds to the JSON property `restrictingUser` @return [Google::Apis::DriveV2::User]
The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true. Corresponds to the JSON property `restrictionDate` @return [DateTime]
The type of the content restriction. Currently the only possible value is globalContentRestriction. Corresponds to the JSON property `type` @return [String]
Public Class Methods
# File lib/google/apis/drive_v2/classes.rb, line 1380 def initialize(**args) update!(**args) end
Public Instance Methods
Update properties of this object
# File lib/google/apis/drive_v2/classes.rb, line 1385 def update!(**args) @read_only = args[:read_only] if args.key?(:read_only) @reason = args[:reason] if args.key?(:reason) @restricting_user = args[:restricting_user] if args.key?(:restricting_user) @restriction_date = args[:restriction_date] if args.key?(:restriction_date) @type = args[:type] if args.key?(:type) end