*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> timer_settime (3c)              
Title
Content
Arch
Section
 

Contents


timer_settime(3C)					     timer_settime(3C)


NAME    [Toc]    [Back]

     timer_settime - set the expiration	time for a posix timer

SYNOPSIS    [Toc]    [Back]

     #include <time.h>

     int timer_settime (timer_t	timerid<b>, int flags<b>,
     const struct itimerspec *value<b>, struct itimerspec *ovalue<b>);

DESCRIPTION    [Toc]    [Back]

     timer_settime sets	the expiration time for	the posix timer	named by
     timerid.  The timespec_t it_value field of	value is used to specify the
     desired timer expiration time.  If	the timer was previously set and has
     not expired, then the timer is reset to the specified it_value.  In the
     event it_value is set to zero, the	timer is disarmed.

     By	default, posix timers interpret	specified expiration times to be
     relative to the time of the timer_settime call.  Therefore, the timer
     will expire in it_value nanoseconds from when the call is made.  This
     behavior, however,	may be altered using the flags parameter.  If the
     TIMER_ABSTIME flag	is set,	then the timer will interpret the specified
     expiration	time to	be absolute in respect to the clock associated with
     timerid.  Hence, the timer	will expire when the clock reaches the
     specified it_value.  If TIMER_ABSTIME is selected and the specified
     expiration	time has already elapsed, the call will	succeed	and expiration
     notification will be delivered.

     The periodic interval time	for which subsequent timer expirations occur
     may be set	using the it_interval field of value.  If it_interval is set
     to	zero, then the timer will only expire once, as specified by it_value.

     If	ovalue is not set to NULL, then	the previous time remaining before
     timerid expiration	is stored at memory address ovalue.

     timer_settime will	fail if	one or more of the following are true:

     [EINVAL]	 The timerid does not name a valid posix timer.

     [EINVAL]	 value contained a nanosecond value greater than 1000 million
		 or less than zero.

     [EFAULT]	 The address specified by either value or ovalue is outside
		 the range of the address space	of the calling process.

SEE ALSO    [Toc]    [Back]

      
      
     timer_create(3C), timer_delete(3C), timer_getoverrun(3C),
     timer_gettime(3C),	clock_settime(2), clock_gettime(2), clock_getres(2),
     getitimer(2), setiitimer(2)







									Page 1






timer_settime(3C)					     timer_settime(3C)



DIAGNOSTICS
     Upon successful completion, a value of 0 is returned to the calling
     process. Otherwise, a value of -1 is returned and errno is	set to
     indicate the error.


									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
timer_gettime IRIX get the time remaining before posix timer expiration
create_link HP-UX Creates a soft link and optionally specifies an expiration time and an extension time
timer_create IRIX create a posix timer
timer_delete IRIX delete a posix timer
timer_getoverrun IRIX get the posix timer overrun count
tis_get_expiration Tru64 Obtains a value representing a desired expiration time
pthread_get_expiration_np Tru64 Obtains a value representing a desired expiration time
hardclock NetBSD real-time timer
clock_settime IRIX get/set date and time (POSIX)
aio_max_ops HP-UX maximum number of POSIX async I/O operations that can be queued at any time
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service