Class: Google::Apis::MybusinessV3::TimePeriod

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

Overview

Represents a span of time that the business is open, starting on the specified open day/time and closing on the specified close day/time. The closing time must occur after the opening time, for example later in the same day, or on a subsequent day.

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

Returns a new instance of TimePeriod



1829
1830
1831
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1829

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

Instance Attribute Details

#close_dayString

Indicates the day of the week this period ends on. Corresponds to the JSON property closeDay

Returns:

  • (String)


1808
1809
1810
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1808

def close_day
  @close_day
end

#close_timeString

Time in 24hr ISO 8601 extended format (hh:mm). Valid values are 00:00-24:00, where 24:00 represents midnight at the end of the specified day field. Corresponds to the JSON property closeTime

Returns:

  • (String)


1815
1816
1817
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1815

def close_time
  @close_time
end

#open_dayString

Indicates the day of the week this period starts on. Corresponds to the JSON property openDay

Returns:

  • (String)


1821
1822
1823
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1821

def open_day
  @open_day
end

#open_timeString

Time in 24hr ISO 8601 extended format (hh:mm). Valid values are 00:00-24:00, where 24:00 represents midnight at the end of the specified day field. Corresponds to the JSON property openTime

Returns:

  • (String)


1827
1828
1829
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1827

def open_time
  @open_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1834
1835
1836
1837
1838
1839
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1834

def update!(**args)
  @close_day = args[:close_day] if args.key?(:close_day)
  @close_time = args[:close_time] if args.key?(:close_time)
  @open_day = args[:open_day] if args.key?(:open_day)
  @open_time = args[:open_time] if args.key?(:open_time)
end