Class: Google::Apis::PeopleV1::Event

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

Overview

An event related to the person.

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) ⇒ Event

Returns a new instance of Event



1819
1820
1821
# File 'generated/google/apis/people_v1/classes.rb', line 1819

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

Instance Attribute Details

#dateGoogle::Apis::PeopleV1::Date

Represents a whole calendar date, for example a 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. The year may be 0 to represent a month and day independent of year; for example, anniversary date. Corresponds to the JSON property date



1811
1812
1813
# File 'generated/google/apis/people_v1/classes.rb', line 1811

def date
  @date
end

#formatted_typeString

The read-only type of the event translated and formatted in the viewer's account locale or the Accept-Language HTTP header locale. Corresponds to the JSON property formattedType

Returns:

  • (String)


1817
1818
1819
# File 'generated/google/apis/people_v1/classes.rb', line 1817

def formatted_type
  @formatted_type
end

#metadataGoogle::Apis::PeopleV1::FieldMetadata

Metadata about a field. Corresponds to the JSON property metadata



1799
1800
1801
# File 'generated/google/apis/people_v1/classes.rb', line 1799

def 
  @metadata
end

#typeString

The type of the event. The type can be custom or predefined. Possible values include, but are not limited to, the following:

  • anniversary
  • other Corresponds to the JSON property type

Returns:

  • (String)


1794
1795
1796
# File 'generated/google/apis/people_v1/classes.rb', line 1794

def type
  @type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1824
1825
1826
1827
1828
1829
# File 'generated/google/apis/people_v1/classes.rb', line 1824

def update!(**args)
  @type = args[:type] if args.key?(:type)
  @metadata = args[:metadata] if args.key?(:metadata)
  @date = args[:date] if args.key?(:date)
  @formatted_type = args[:formatted_type] if args.key?(:formatted_type)
end