2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								IN:  alarms 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 21:57:41 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								USING:  help.markup  help.syntax  calendar  quotations  ;
 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								HELP:  alarm 
							 
						 
					
						
							
								
									
										
										
										
											2008-05-21 22:31:54 -04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								{ $class-description "An alarm. Can be passed to "  { $link cancel-alarm } "."  } ;
 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								HELP:  add-alarm 
							 
						 
					
						
							
								
									
										
										
										
											2008-11-16 07:02:13 -05:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								{ $values { "quot"  quotation } { "time"  timestamp } { "frequency"  { $maybe duration } } { "alarm"  alarm } }
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								{ $description "Creates and registers an alarm. If "  { $snippet "frequency"  } " is "  { $link f  } ", this will be a one-time alarm, otherwise it will fire with the given frequency. The quotation will be called from the alarm thread."  } ;
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2008-02-22 00:47:06 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								HELP:  later 
							 
						 
					
						
							
								
									
										
										
										
											2008-09-04 19:14:24 -04:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								{ $values { "quot"  quotation } { "duration"  duration } { "alarm"  alarm } }
							 
						 
					
						
							
								
									
										
										
										
											2008-07-08 16:50:38 -04:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								{ $description "Creates and registers an alarm which calls the quotation once at "  { $snippet "time"  } " from now."  } ;
 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-22 00:47:06 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								HELP:  cancel-alarm 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								{ $values { "alarm"  alarm } }
							 
						 
					
						
							
								
									
										
										
										
											2008-02-23 23:29:46 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								{ $description "Cancels an alarm. Does nothing if the alarm is not active."  } ;
 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2008-09-04 19:14:24 -04:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								HELP:  every 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								{ $values
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								     { "quot"  quotation } { "duration"  duration }
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								     { "alarm"  alarm } }
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								{ $description "Creates and registers an alarm which calls the quotation repeatedly, using "  { $snippet "dt"  } " as the frequency."  } ;
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								ARTICLE: "alarms"  "Alarms" 
							 
						 
					
						
							
								
									
										
										
										
											2008-09-12 13:21:32 -04:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								"The "  { $vocab-link "alarms"  } " vocabulary provides a lightweight way to schedule one-time and recurring tasks without spawning a new thread." 
							 
						 
					
						
							
								
									
										
										
										
											2009-10-01 15:56:36 -04:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								{ $subsections
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    alarm
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    add-alarm
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    later
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    cancel-alarm
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								}
							 
						 
					
						
							
								
									
										
										
										
											2008-02-22 17:18:45 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								"Alarms do not persist across image saves. Saving and restoring an image has the effect of calling "  { $link cancel-alarm } " on all "  { $link alarm } " instances."  ;
 
							 
						 
					
						
							
								
									
										
										
										
											2008-02-21 20:19:21 -05:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								ABOUT: "alarms"