File: globus_utp.h

package info (click to toggle)
globus-xio 6.2-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 8,128 kB
  • sloc: ansic: 46,711; sh: 11,139; perl: 1,598; makefile: 289
file content (110 lines) | stat: -rw-r--r-- 2,820 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
/*
 * Copyright 1999-2006 University of Chicago
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 * http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/**********************************************************************
globus_utp.h

Public declarations for the Unnamed Timing Package (UTP).
**********************************************************************/

#ifndef GLOBUS_UTP_INCLUDE
#define GLOBUS_UTP_INCLUDE

#include "globus_common.h"

#ifdef __cplusplus
extern "C" {
#endif

/**********************************************************************
Publicly-accessible functions.
**********************************************************************/

extern int
globus_utp_init(unsigned numTimers, int mode);

extern void
globus_utp_write_file(const char *outFilename);

extern void
globus_utp_set_attribute(const char *keyStr,
			 const char *keyArg,
			 const char *valueStr,
			 ...);

extern void
globus_utp_start_timer(unsigned timerNumber);

extern void
globus_utp_stop_timer(unsigned timerNumber);

extern void
globus_utp_reset_timer(unsigned timerNumber);

extern void
globus_utp_disable_timer(unsigned timerNumber);

extern void
globus_utp_enable_timer(unsigned timerNumber);

extern void
globus_utp_disable_all_timers(void);

extern void
globus_utp_enable_all_timers(void);

extern const char *
globus_utp_name_timer(unsigned timerNumber,
		      const char *nameStr,
		      ...);

extern void
globus_utp_get_accum_time(unsigned timerNumber,
			  double *time,
			  int *precision);


/**********************************************************************
Publicly-accessible definitions.
**********************************************************************/

/*
 * Initialization modes.
 */
#define GLOBUS_UTP_MODE_SHARED  0	/* Pick one of these. */
#define GLOBUS_UTP_MODE_PRIVATE 1

/*
 * Strings for timer names and attribute keys and
 * values must be shorter than this.
 */
#define GLOBUS_UTP_MAX_NAME_LENGTH 240

#define GLOBUS_UTP_DEFAULT_TIMER_NAME ""

/******************************************************************************
			  Module activation structure
******************************************************************************/
extern globus_module_descriptor_t	globus_i_utp_module;

#define GLOBUS_UTP_MODULE (&globus_i_utp_module)


#ifdef __cplusplus
}
#endif

#endif /* #ifndef GLOBUS_UTP_INCLUDE */