Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Kill old $Id$ command dating from CVS
[simgrid.git] / src / include / xbt / xbt_os_time.h
1 /*  xbt/xbt_portability.h -- all system dependency                          */
2 /* Private portability layer                                                */
3
4 /* Copyright (c) 2004,2005 Martin Quinson. All rights reserved.             */
5
6 /* This program is free software; you can redistribute it and/or modify it
7  * under the terms of the license (GNU LGPL) which comes with this package. */
8
9 #ifndef _XBT_PORTABILITY_H
10 #define _XBT_PORTABILITY_H
11
12 #include <xbt/misc.h>           /* XBT_PUBLIC */
13
14 /** @brief get time in seconds 
15
16   * gives  the  number  of  seconds since the Epoch (00:00:00 UTC, January 1, 1970).
17   * Most users should use gras_os_time and should not use this function unless 
18     they really know what they are doing. */
19 XBT_PUBLIC(double) xbt_os_time(void);
20 XBT_PUBLIC(void) xbt_os_sleep(double sec);
21
22      typedef struct s_xbt_os_timer *xbt_os_timer_t;
23 XBT_PUBLIC(xbt_os_timer_t) xbt_os_timer_new(void);
24 XBT_PUBLIC(void) xbt_os_timer_free(xbt_os_timer_t timer);
25 XBT_PUBLIC(void) xbt_os_timer_start(xbt_os_timer_t timer);
26 XBT_PUBLIC(void) xbt_os_timer_stop(xbt_os_timer_t timer);
27 XBT_PUBLIC(double) xbt_os_timer_elapsed(xbt_os_timer_t timer);
28
29 #endif