Class: Google::Apis::DlpV2::GooglePrivacyDlpV2DateTime

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/dlp_v2/classes.rb,
generated/google/apis/dlp_v2/representations.rb,
generated/google/apis/dlp_v2/representations.rb

Overview

Message for a date time object.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ GooglePrivacyDlpV2DateTime

Returns a new instance of GooglePrivacyDlpV2DateTime



1248
1249
1250
# File 'generated/google/apis/dlp_v2/classes.rb', line 1248

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#dateGoogle::Apis::DlpV2::GoogleTypeDate

Represents a whole calendar date, e.g. date of birth. The time of day and time zone are either specified elsewhere or are not significant. The date is relative to the Proleptic Gregorian Calendar. The day may be 0 to represent a year and month where the day is not significant, e.g. credit card expiration date. The year may be 0 to represent a month and day independent of year, e.g. anniversary date. Related types are google.type.TimeOfDay and google.protobuf.Timestamp. Corresponds to the JSON property date



1229
1230
1231
# File 'generated/google/apis/dlp_v2/classes.rb', line 1229

def date
  @date
end

#day_of_weekString

Corresponds to the JSON property dayOfWeek

Returns:

  • (String)


1234
1235
1236
# File 'generated/google/apis/dlp_v2/classes.rb', line 1234

def day_of_week
  @day_of_week
end

#timeGoogle::Apis::DlpV2::GoogleTypeTimeOfDay

Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may choose to allow leap seconds. Related types are google.type.Date and google.protobuf.Timestamp. Corresponds to the JSON property time



1241
1242
1243
# File 'generated/google/apis/dlp_v2/classes.rb', line 1241

def time
  @time
end

#time_zoneGoogle::Apis::DlpV2::GooglePrivacyDlpV2TimeZone

Corresponds to the JSON property timeZone



1246
1247
1248
# File 'generated/google/apis/dlp_v2/classes.rb', line 1246

def time_zone
  @time_zone
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1253
1254
1255
1256
1257
1258
# File 'generated/google/apis/dlp_v2/classes.rb', line 1253

def update!(**args)
  @date = args[:date] if args.key?(:date)
  @day_of_week = args[:day_of_week] if args.key?(:day_of_week)
  @time = args[:time] if args.key?(:time)
  @time_zone = args[:time_zone] if args.key?(:time_zone)
end