Fawkes API  Fawkes Development Version
interface_mem_header.h
1 
2 /***************************************************************************
3  * interface_mem_header.h - BlackBoard interface memory header
4  *
5  * Generated: Fri Oct 20 13:41:29 2006
6  * Copyright 2006 Tim Niemueller [www.niemueller.de]
7  *
8  ****************************************************************************/
9 
10 /* This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version. A runtime exception applies to
14  * this software (see LICENSE.GPL_WRE file mentioned below for details).
15  *
16  * This program is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  * GNU Library General Public License for more details.
20  *
21  * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
22  */
23 
24 #ifndef __BLACKBOARD_INTERFACE_MEM_HEADER_H_
25 #define __BLACKBOARD_INTERFACE_MEM_HEADER_H_
26 
27 #include <interface/interface.h>
28 
29 #include <stdint.h>
30 
31 namespace fawkes {
32 
33 /** This struct is used as header for interfaces in memory chunks.
34  * This header is stored at the beginning of each allocated memory chunk.
35  */
36 typedef struct {
37  char type[__INTERFACE_TYPE_SIZE]; /**< interface type */
38  char id[__INTERFACE_ID_SIZE]; /**< interface identifier */
39  unsigned char hash[__INTERFACE_HASH_SIZE]; /**< interface type version hash */
40  uint16_t flag_writer_active : 1; /**< 1 if there is a writer, 0 otherwise */
41  uint16_t flag_reserved : 15; /**< reserved for future use */
42  uint16_t num_readers; /**< number of active readers */
43  uint32_t refcount; /**< reference count */
44  uint32_t serial; /**< memory serial */
46 
47 } // end namespace fawkes
48 
49 #endif
Fawkes library namespace.
uint16_t flag_writer_active
1 if there is a writer, 0 otherwise
uint16_t num_readers
number of active readers
This struct is used as header for interfaces in memory chunks.
uint32_t serial
memory serial
uint16_t flag_reserved
reserved for future use
uint32_t refcount
reference count