4 <name>Tizen.Applications.Alarm</name>
7 <member name="T:Tizen.Applications.Alarm">
9 The alarm API allows setting an "alarm clock" for the delivery of a notification at some point in the future.
13 public class AlarmExample
16 IEnumerable < Alarm > alarms = AlarmManager.GetAllScheduledAlarms();
22 <member name="M:Tizen.Applications.Alarm.#ctor(System.Int32)">
24 Constructor created with the new AlarmId.
26 <param name="id"></param>
28 <member name="P:Tizen.Applications.Alarm.AlarmId">
30 The alarm ID uniquely identifies an alarm.
33 <member name="P:Tizen.Applications.Alarm.WeekFlag">
35 Gets the recurrence days of the week.
37 <privilege>http://tizen.org/privilege/alarm.get</privilege>
39 week_flag may be a combination of days, like Tuesday | Friday.
42 <member name="P:Tizen.Applications.Alarm.ScheduledDate">
44 Gets the scheduled time.
46 <privilege>http://tizen.org/privilege/alarm.get</privilege>
48 <member name="P:Tizen.Applications.Alarm.Period">
50 Gets the period of time between the recurrent alarms.
52 <privilege>http://tizen.org/privilege/alarm.get</privilege>
54 <member name="P:Tizen.Applications.Alarm.AlarmAppControl">
56 Gets the AppControl to be invoked when the the alarm is triggered.
58 <privilege>http://tizen.org/privilege/alarm.get</privilege>
60 <member name="P:Tizen.Applications.Alarm.Global">
62 Gets whether the alarm will launch global application or not.
64 <privilege>http://tizen.org/privilege/alarm.set</privilege>
65 <privilege>http://tizen.org/privilege/alarm.get</privilege>
67 <member name="M:Tizen.Applications.Alarm.Cancel">
69 Cancels the specific alarm.
71 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parmaeter.</exception>
72 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied due to insufficient privileges.</exception>
73 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
74 <privilege>http://tizen.org/privilege/alarm.set</privilege>
76 <member name="T:Tizen.Applications.AlarmWeekFlag">
78 Enumeration for alarm week flag, the days of the week.
81 <member name="F:Tizen.Applications.AlarmWeekFlag.Sunday">
83 An identifier for Sunday.
86 <member name="F:Tizen.Applications.AlarmWeekFlag.Monday">
88 An identifier for Monday.
91 <member name="F:Tizen.Applications.AlarmWeekFlag.Tuesday">
93 An identifier for Tuesday.
96 <member name="F:Tizen.Applications.AlarmWeekFlag.Wednesday">
98 An identifier for Wednesday.
101 <member name="F:Tizen.Applications.AlarmWeekFlag.Thursday">
103 An identifier for Thursday.
106 <member name="F:Tizen.Applications.AlarmWeekFlag.Friday">
108 An identifier for Friday.
111 <member name="F:Tizen.Applications.AlarmWeekFlag.Saturday">
113 An identifier for Saturday.
116 <member name="F:Tizen.Applications.AlarmWeekFlag.AllDays">
118 All days of the week.
121 <member name="F:Tizen.Applications.AlarmWeekFlag.WeekDays">
126 <member name="T:Tizen.Applications.AlarmManager">
128 Mobile devices typically give constant access to information from various sources. Some of this information is best delivered through alarms.
129 The most obvious case is a calendar scheduling application, which lets you know when a meeting is about to start. Alarms are certainly better than actively waiting in a loop.
130 They are also better than putting an interface to sleep because they do not block your main UI thread.
131 Use of alarms helps build smooth user experiences and implements unattended data synchronization tasks.
132 If an application is installed after setting the alarm, your alarm is canceled automatically.
136 public class AlarmManagerExample
139 Alarm alarm = AlarmManager.CreateAlarm(24000,1000,null);
140 AlarmManager.CancelAll();
145 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.Int32,System.Int32,Tizen.Applications.AppControl)">
147 Sets an alarm to be triggered after a specific time.
148 The alarm will first go off delay seconds later and then will go off every certain amount of time defined using period seconds.
150 <param name="delay">The amount of time before the first execution (in seconds).</param>
151 <param name="period"> The amount of time between subsequent alarms (in seconds). This value does not guarantee the accuracy.
152 The actual interval is calculated by the OS. The minimum value is 600sec.</param>
153 <param name="appControl"> The destination AppControl is used to perform a specific task when the alarm is triggered. </param>
154 <returns> An alarm instance is created with the set param values.</returns>
155 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
156 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
157 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
158 <privilege>http://tizen.org/privilege/alarm.set</privilege>
160 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.Int32,Tizen.Applications.AppControl)">
162 Sets an alarm to be triggered after a specific time.
163 The alarm will go off delay seconds later.
165 <param name="delay"> The amount of time before the execution (in seconds). </param>
166 <param name="appControl"> The destination AppControl to perform a specific task when the alarm is triggered. </param>
167 <returns> An alarm instance is created with the set param values.</returns>
168 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
169 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
170 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
171 <privilege>http://tizen.org/privilege/alarm.set</privilege>
173 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.DateTime,Tizen.Applications.AppControl)">
175 Sets an alarm to be triggered at a specific time.
176 The date describes the time of the first occurrence.
178 <param name="value"> The first active alarm time. </param>
179 <param name="appControl"> The destination AppControl to perform specific work when the alarm is triggered. </param>
180 <returns> An alarm instance is created with the set param values.</returns>
181 <remarks>This operation is permitted with the UI application appcontrol only.</remarks>
182 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
183 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
184 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
185 <privilege>http://tizen.org/privilege/alarm.set</privilege>
187 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.DateTime,Tizen.Applications.AlarmWeekFlag,Tizen.Applications.AppControl)">
189 Sets an alarm to be triggered periodically, starting at a specific time.
190 The date describes the time of the first occurrence.
191 The weekFlag is the repeat value of the days of the week.
192 If the weekFlag is AlarmWeekFlag.Tuesday, the alarm will repeat every Tuesday at a specific time.
194 <remarks>This operation is permitted with UI application appcontrol only.</remarks>
195 <param name="value"> The first active alarm time. </param>
196 <param name="weekFlag"> The day of the week, AlarmWeekFlag may be a combination of days, like AlarmWeekFlag.Sunday | AlarmWeekFlag.Monday.</param>
197 <param name="appControl"> The destination AppControl to perform specific work when the alarm is triggered. </param>
198 <returns> An alarm instance is created with the set param values.</returns>
199 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
200 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
201 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
202 <privilege>http://tizen.org/privilege/alarm.set</privilege>
204 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.DateTime,Tizen.Applications.Notifications.Notification)">
206 Sets a notification alarm to be triggered at a specific time.
207 The date describes the time of the first occurrence.
209 <param name="dateTime"> The first active alarm time. </param>
210 <param name="notification"> The notification to be posted when the alarm is triggered. </param>
211 <returns> An alarm instance is created with the set param values.</returns>
212 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
213 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
214 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
215 <privilege>http://tizen.org/privilege/alarm.set</privilege>
216 <privilege>http://tizen.org/privilege/notification</privilege>
218 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.Int32,System.Int32,Tizen.Applications.Notifications.Notification)">
220 Sets a notification alarm to be triggered after a specific time.
221 The alarm will first go off delay seconds later and then will go off every certain amount of time defined using period seconds.
223 <param name="delay">The amount of time before the first execution (in seconds). </param>
224 <param name="period"> The amount of time between subsequent alarms (in seconds). This value does not guarantee the accuracy. </param>
225 <param name="notification"> The notification to be posted when the alarm is triggered. </param>
226 <returns> An alarm instance is created with the set param values.</returns>
227 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
228 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
229 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
230 <privilege>http://tizen.org/privilege/alarm.set</privilege>
231 <privilege>http://tizen.org/privilege/notification</privilege>
233 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.DateTime,Tizen.Applications.AlarmWeekFlag,Tizen.Applications.Notifications.Notification)">
235 Sets a notification alarm to be triggered periodically, starting at a specific time.
236 The date describes the time of the first occurrence.
237 The weekFlag is the repeat value of the days of the week.
238 If the weekFlag is AlarmWeekFlag.Tuesday, the alarm will repeat every Tuesday at a specific time.
240 <param name="dateTime"> The first active alarm time. </param>
241 <param name="weekFlag"> The day of the week, AlarmWeekFlag may be a combination of days,
242 like AlarmWeekFlag.Sunday | AlarmWeekFlag.Monday.</param>
243 <param name="notification"> The notification to be posted when the alarm is triggered. </param>
244 <returns> An alarm instance is created with the set param values.</returns>
245 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
246 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
247 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
248 <privilege>http://tizen.org/privilege/alarm.set</privilege>
249 <privilege>http://tizen.org/privilege/notification</privilege>
251 <member name="M:Tizen.Applications.AlarmManager.CreateAlarm(System.Int32,Tizen.Applications.Notifications.Notification)">
253 Sets a notification alarm to be triggered after a specific time.
254 The alarm will go off delay seconds later.
256 <param name="delay">The amount of time before the first execution (in seconds).</param>
257 <param name="notification"> The notification to be posted when the alarm is triggered. </param>
258 <returns> An alarm instance is created with the set param values.</returns>
259 <exception cref="T:System.ArgumentException">Thrown in case of an invalid parameter.</exception>
260 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
261 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
262 <privilege>http://tizen.org/privilege/alarm.set</privilege>
263 <privilege>http://tizen.org/privilege/notification</privilege>
265 <member name="M:Tizen.Applications.AlarmManager.CancelAll">
267 Cancels all scheduled alarms that are registered by the application that calls this API.
269 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
270 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
271 <privilege>http://tizen.org/privilege/alarm.set</privilege>
273 <member name="M:Tizen.Applications.AlarmManager.GetAllScheduledAlarms">
275 Retrieves all registered alarms.
277 <returns>List of all alarm instances.</returns>
278 <exception cref="T:System.UnauthorizedAccessException">Thrown in case of a permission denied.</exception>
279 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>
280 <privilege>http://tizen.org/privilege/alarm.get</privilege>
282 <member name="M:Tizen.Applications.AlarmManager.GetCurrentTime">
284 Gets the current system time.
286 <returns>The current system time.</returns>
287 <exception cref="T:System.InvalidOperationException">Thrown in case of any internal error.</exception>