pthreads/{array_thrsafe_rwlock/array.h → array_thrsafe_perf/array_rwlock.h} RENAMED
@@ -1,18 +1,18 @@
1
- #ifndef ARRAY_H
2
- #define ARRAY_H
3
 
4
  #include <stddef.h>
5
 
6
- typedef struct array array_t;
7
 
8
- static const size_t array_not_found = (size_t)-1;
9
 
10
- array_t* array_create(size_t capacity);
11
- void array_destroy(array_t* array);
12
- size_t array_get_count(array_t *array);
13
- void* array_get_element(array_t* array, size_t index);
14
- int array_append(array_t* array, void* element);
15
- size_t array_find_first(array_t *array, const void* element, size_t start_pos);
16
- int array_remove_first(array_t* array, const void* element, size_t start_pos);
17
 
18
- #endif // ARRAY_H
1
+ #ifndef ARRAY_RWLOCK_H
2
+ #define ARRAY_RWLOCK_H
3
 
4
  #include <stddef.h>
5
 
6
+ typedef struct array_rwlock array_rwlock_t;
7
 
8
+ static const size_t array_rwlock_not_found = (size_t)-1;
9
 
10
+ array_rwlock_t* array_rwlock_create(size_t capacity);
11
+ void array_rwlock_destroy(array_rwlock_t* array);
12
+ size_t array_rwlock_get_count(array_rwlock_t *array);
13
+ void* array_rwlock_get_element(array_rwlock_t* array, size_t index);
14
+ int array_rwlock_append(array_rwlock_t* array, void* element);
15
+ size_t array_rwlock_find_first(array_rwlock_t *array, const void* element, size_t start_pos);
16
+ int array_rwlock_remove_first(array_rwlock_t* array, const void* element, size_t start_pos);
17
 
18
+ #endif // ARRAY_RWLOCK_H