Access and modify an existing refresh schedule. To get all refresh schedules, see Spreadsheet.getDataSourceRefreshSchedules()
.
Only use this class with data that's connected to a database.
Methods
Method | Return type | Brief description |
---|---|---|
getFrequency() | DataSourceRefreshScheduleFrequency | Gets the refresh schedule frequency, which specifies how often and when to refresh. |
getScope() | DataSourceRefreshScope | Gets the scope of this refresh schedule. |
getTimeIntervalOfNextRun() | TimeInterval | Gets the time window of the next run of this refresh schedule. |
isEnabled() | Boolean | Determines whether this refresh schedule is enabled. |
Detailed documentation
getFrequency()
Gets the refresh schedule frequency, which specifies how often and when to refresh.
Return
DataSourceRefreshScheduleFrequency
— The refresh schedule frequency.
Authorization
Scripts that use this method require authorization with one or more of the following scopes:
-
https://www.googleapis.com/auth/spreadsheets.currentonly
-
https://www.googleapis.com/auth/spreadsheets
getScope()
Gets the scope of this refresh schedule.
Return
DataSourceRefreshScope
— The refresh scope.
Authorization
Scripts that use this method require authorization with one or more of the following scopes:
-
https://www.googleapis.com/auth/spreadsheets.currentonly
-
https://www.googleapis.com/auth/spreadsheets
getTimeIntervalOfNextRun()
Gets the time window of the next run of this refresh schedule. Only applies if this refresh schedule is enabled.
Return
TimeInterval
— The time window of the next run.
Authorization
Scripts that use this method require authorization with one or more of the following scopes:
-
https://www.googleapis.com/auth/spreadsheets.currentonly
-
https://www.googleapis.com/auth/spreadsheets
isEnabled()
Determines whether this refresh schedule is enabled.
Return
Boolean
— Whether this refresh schedule is enabled.
Authorization
Scripts that use this method require authorization with one or more of the following scopes:
-
https://www.googleapis.com/auth/spreadsheets.currentonly
-
https://www.googleapis.com/auth/spreadsheets