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



662
663
664
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 662

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)


653
654
655
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 653

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)


660
661
662
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 660

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)


641
642
643
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 641

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)


647
648
649
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 647

def open_time
  @open_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



667
668
669
670
671
672
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 667

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