Changeset 201 for trunk/include/range_list.h
- Timestamp:
- 06/05/10 00:45:05 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/range_list.h
r169 r201 36 36 #include <string.h> 37 37 #include <math.h> 38 #include "talloc.h" 38 #include <talloc.h> 39 40 /* GCC-specific macro for library exports */ 41 #ifdef _EXPORT 42 #undef _EXPORT 43 #endif 44 #define _EXPORT __attribute__((visibility("default"))) 39 45 40 46 typedef struct _range_list_element … … 59 65 * @return A newly allocated range_list, or NULL if an error occurred. 60 66 */ 67 _EXPORT 61 68 range_list* range_list_new(); 62 69 … … 69 76 * @param rl the range_list to be free()d. 70 77 */ 78 _EXPORT 71 79 void range_list_free(range_list* rl); 72 80 … … 78 86 * @return The number of elements currently in the list. 79 87 */ 88 _EXPORT 80 89 uint32_t range_list_size(const range_list* rl); 81 90 … … 97 106 * errors may also be possible. 98 107 */ 108 _EXPORT 99 109 bool range_list_add(range_list* rl, uint32_t offset, uint32_t length, void* data); 100 110 … … 109 119 * @return true if the element was successfully removed, false otherwise. 110 120 */ 121 _EXPORT 111 122 bool range_list_remove(range_list* rl, uint32_t index); 112 123 … … 120 131 * available. 121 132 */ 133 _EXPORT 122 134 const range_list_element* range_list_get(const range_list* rl, uint32_t index); 123 135 … … 130 142 * @return A matching element index or a negative value if none could be found. 131 143 */ 144 _EXPORT 132 145 int32_t range_list_find(const range_list* rl, uint32_t offset); 133 146 … … 144 157 * element was never set. 145 158 */ 159 _EXPORT 146 160 void* range_list_find_data(const range_list* rl, uint32_t offset); 147 161 … … 165 179 * @return true if the element was successfully split, false otherwise. 166 180 */ 181 _EXPORT 167 182 bool range_list_split_element(range_list* rl, uint32_t index, uint32_t offset); 168 183 … … 177 192 * @return true if the specified range exists and is complete, false otherwise. 178 193 */ 194 _EXPORT 179 195 bool range_list_has_range(range_list* rl, uint32_t start, uint32_t length); 180 196
Note: See TracChangeset
for help on using the changeset viewer.