1 | /** |
---|
2 | * @file TypeManager.h |
---|
3 | * @author Sheng Di |
---|
4 | * @date July, 2017 |
---|
5 | * @brief Header file for the TypeManager.c. |
---|
6 | * (C) 2016 by Mathematics and Computer Science (MCS), Argonne National Laboratory. |
---|
7 | * See COPYRIGHT in top-level directory. |
---|
8 | */ |
---|
9 | |
---|
10 | #ifndef _TypeManager_H |
---|
11 | #define _TypeManager_H |
---|
12 | |
---|
13 | #ifdef __cplusplus |
---|
14 | extern "C" { |
---|
15 | #endif |
---|
16 | |
---|
17 | #include <stdio.h> |
---|
18 | #include <stdint.h> |
---|
19 | |
---|
20 | //TypeManager.c |
---|
21 | size_t convertIntArray2ByteArray_fast_1b(unsigned char* intArray, size_t intArrayLength, unsigned char **result); |
---|
22 | size_t convertIntArray2ByteArray_fast_1b_to_result(unsigned char* intArray, size_t intArrayLength, unsigned char *result); |
---|
23 | void convertByteArray2IntArray_fast_1b(size_t intArrayLength, unsigned char* byteArray, size_t byteArrayLength, unsigned char **intArray); |
---|
24 | size_t convertIntArray2ByteArray_fast_2b(unsigned char* timeStepType, size_t timeStepTypeLength, unsigned char **result); |
---|
25 | size_t convertIntArray2ByteArray_fast_2b_inplace(unsigned char* timeStepType, size_t timeStepTypeLength, unsigned char *result); |
---|
26 | void convertByteArray2IntArray_fast_2b(size_t stepLength, unsigned char* byteArray, size_t byteArrayLength, unsigned char **intArray); |
---|
27 | size_t convertIntArray2ByteArray_fast_3b(unsigned char* timeStepType, size_t timeStepTypeLength, unsigned char **result); |
---|
28 | void convertByteArray2IntArray_fast_3b(size_t stepLength, unsigned char* byteArray, size_t byteArrayLength, unsigned char **intArray); |
---|
29 | int getLeftMovingSteps(size_t k, unsigned char resiBitLength); |
---|
30 | size_t convertIntArray2ByteArray_fast_dynamic(unsigned char* timeStepType, unsigned char resiBitLength, size_t nbEle, unsigned char **bytes); |
---|
31 | size_t convertIntArray2ByteArray_fast_dynamic2(unsigned char* timeStepType, unsigned char* resiBitLength, size_t resiBitLengthLength, unsigned char **bytes); |
---|
32 | int computeBitNumRequired(size_t dataLength); |
---|
33 | void decompressBitArraybySimpleLZ77(int** result, unsigned char* bytes, size_t bytesLength, size_t totalLength, int validLength); |
---|
34 | |
---|
35 | #ifdef __cplusplus |
---|
36 | } |
---|
37 | #endif |
---|
38 | |
---|
39 | #endif /* ----- #ifndef _TypeManager_H ----- */ |
---|
40 | |
---|