UtcTimePropertiesBuilder
Builder that creates an instance of the TimeProperties object.
The UtcTimePropertiesBuilder allows callers to create an instance
ITimeProperties in UTC. The constraint is a combination of a start time
and an execution window. For instance, if we want the EPG sync task
to be executed between 2AM and 4AM UTC, then the timeProperties can be built as
UtcTimePropertiesBuilder.startHour(2).startMinute(0).startSecond(0).executionWindowInMinutes(120).build();
Extends
Builder
Constructors
new UtcTimePropertiesBuilder()
new UtcTimePropertiesBuilder(): UtcTimePropertiesBuilder
Returns
Methods
build()
build(): ITimeProperties
Builds the TimeProperties object based on the parameters provided.
Throws
InvalidArgumentErrorif one or more of the required fields are missing.IllegalStateErrorif the function is called after this builder instance has already built an object once.
Returns
ITimeProperties The built TimeProperties object.
executionWindowInMinutes()
executionWindowInMinutes(window:
number): UtcTimePropertiesBuilder
Sets the length of the execution time window in the TimeProperties.
This field is optional for the time properties. The default value is 60 mins.
Parameters
window
number
The length of the execution time window in mins.
Throws
IllegalStateErrorif the function is called after this builder instance has already built an object once.InvalidArgumentErrorif the execution window is smaller than 1 hour.
Returns
UtcTimePropertiesBuilder The UtcTimePropertiesBuilder object with the execution window set.
startHour()
startHour(hour:
number): UtcTimePropertiesBuilder
Sets the start hour in the TimeProperties.
This field is required for the time properties.
Parameters
hour
number
Represents Hour (0-23).
Throws
IllegalStateErrorif the function is called after this builder instance has already built an object once.InvalidArgumentErrorif the number of hour is not in the range between 0 and 23.
Returns
UtcTimePropertiesBuilder The UtcTimePropertiesBuilder object with the start hour set.
startMinute()
startMinute(minute:
number): UtcTimePropertiesBuilder
Sets the start minute in the TimeProperties.
This field is required for the time properties.
Parameters
minute
number
Represents Minute (0-59).
Throws
IllegalStateErrorif the function is called after this builder instance has already built an object once.InvalidArgumentErrorif the number of minute is not in the range between 0 and 59.
Returns
UtcTimePropertiesBuilder The UtcTimePropertiesBuilder object with the start minute set.
startSecond()
startSecond(second:
number): UtcTimePropertiesBuilder
Sets the start second in the TimeProperties.
This field is required for the time properties.
Parameters
second
number
Represents Second (0-59).
Throws
IllegalStateErrorif the function is called after this builder instance has already built an object once.InvalidArgumentErrorif the number of second is not in the range between 0 and 59.
Returns
UtcTimePropertiesBuilder The UtcTimePropertiesBuilder object with the start second set.
Last updated: Jul 31, 2026

