Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
3ec1ab93247fc842cd81612939298da1084319e2
[simgrid.git] / include / gras / virtu.h
1 /* $Id$                    */
2
3 /* gras/virtu.h - public interface to virtualization (cross-OS portability) */
4
5 /* Copyright (c) 2003, 2004 Martin Quinson. All rights reserved.            */
6
7 /* This program is free software; you can redistribute it and/or modify it
8  * under the terms of the license (GNU LGPL) which comes with this package. */
9
10 #ifndef GRAS_VIRTU_H
11 #define GRAS_VIRTU_H
12
13 #include "xbt/misc.h" /* BEGIN_DECL */
14
15 BEGIN_DECL()
16
17 /**
18  * gras_os_time:
19  * @Returns: number of second since the Epoch.
20  * (00:00:00 UTC, January 1, 1970 in Real Life, and begining of simulation in SG)
21  * 
22  * Get the current time.
23  */
24 double gras_os_time(void);
25
26 /**
27  * gras_os_sleep:
28  * @Param1: number of seconds to sleep
29  * @Param2: number of microseconds to sleep
30  * 
31  * sleeps for the given amount of time.
32  */
33 void gras_os_sleep(unsigned long sec, unsigned long usec);
34
35 /**
36  * gras_get_my_fqdn:
37  *
38  * Returns the fully-qualified name of the host machine, or NULL if the name
39  * cannot be determined.  Always returns the same value, so multiple calls
40  * cause no problems.
41  */
42 const char *
43 gras_get_my_fqdn(void);
44
45 END_DECL()
46
47 #endif /* GRAS_VIRTU_H */
48