51 lines
2.7 KiB
Cython
51 lines
2.7 KiB
Cython
|
|
||
|
cdef extern from "Eet.h":
|
||
|
|
||
|
enum _Eet_Error:
|
||
|
EET_ERROR_NONE #No error, it's all fine!
|
||
|
EET_ERROR_BAD_OBJECT #Given object or handle is NULL or invalid
|
||
|
EET_ERROR_EMPTY #There was nothing to do
|
||
|
EET_ERROR_NOT_WRITABLE #Could not write to file or file is #EET_FILE_MODE_READ
|
||
|
EET_ERROR_OUT_OF_MEMORY #Could not allocate memory
|
||
|
EET_ERROR_WRITE_ERROR #Failed to write data to destination
|
||
|
EET_ERROR_WRITE_ERROR_FILE_TOO_BIG #Failed to write file since it is too big
|
||
|
EET_ERROR_WRITE_ERROR_IO_ERROR #Failed to write due a generic Input/Output error
|
||
|
EET_ERROR_WRITE_ERROR_OUT_OF_SPACE #Failed to write due out of space
|
||
|
EET_ERROR_WRITE_ERROR_FILE_CLOSED #Failed to write because file was closed
|
||
|
EET_ERROR_MMAP_FAILED #Could not mmap file
|
||
|
EET_ERROR_X509_ENCODING_FAILED #Could not encode using X509
|
||
|
EET_ERROR_SIGNATURE_FAILED #Could not validate signature
|
||
|
EET_ERROR_INVALID_SIGNATURE #Signature is invalid
|
||
|
EET_ERROR_NOT_SIGNED #File or contents are not signed
|
||
|
EET_ERROR_NOT_IMPLEMENTED #Function is not implemented
|
||
|
EET_ERROR_PRNG_NOT_SEEDED #Could not introduce random seed
|
||
|
EET_ERROR_ENCRYPT_FAILED #Could not encrypt contents
|
||
|
EET_ERROR_DECRYPT_FAILED #Could not decrypt contents
|
||
|
|
||
|
ctypedef _Eet_Error Eet_Error
|
||
|
|
||
|
ctypedef enum _Eet_Compression:
|
||
|
EET_COMPRESSION_NONE #No compression at all @since 1.7
|
||
|
EET_COMPRESSION_DEFAULT #Default compression (Zlib) @since 1.7
|
||
|
EET_COMPRESSION_LOW #Fast but minimal compression (Zlib) @since 1.7
|
||
|
EET_COMPRESSION_MED #Medium compression level (Zlib) @since 1.7
|
||
|
EET_COMPRESSION_HI #Slow but high compression level (Zlib) @since 1.7
|
||
|
EET_COMPRESSION_VERYFAST #Very fast, but lower compression ratio (LZ4HC) @since 1.7
|
||
|
EET_COMPRESSION_SUPERFAST #Very fast, but lower compression ratio (faster to compress than EET_COMPRESSION_VERYFAST) (LZ4) @since 1.7
|
||
|
|
||
|
EET_COMPRESSION_LOW2 #Space filler for compatibility. Don't use it @since 1.7
|
||
|
EET_COMPRESSION_MED1 #Space filler for compatibility. Don't use it @since 1.7
|
||
|
EET_COMPRESSION_MED2 #Space filler for compatibility. Don't use it @since 1.7
|
||
|
EET_COMPRESSION_HI1 #Space filler for compatibility. Don't use it @since 1.7
|
||
|
EET_COMPRESSION_HI2 #Space filler for compatibility. Don't use it @since 1.7
|
||
|
|
||
|
ctypedef _Eet_Compression Eet_Compression
|
||
|
|
||
|
ctypedef enum _Eet_File_Mode:
|
||
|
EET_FILE_MODE_INVALID
|
||
|
EET_FILE_MODE_READ #File is read-only.
|
||
|
EET_FILE_MODE_WRITE #File is write-only.
|
||
|
EET_FILE_MODE_READ_WRITE #File is for both read and write
|
||
|
|
||
|
ctypedef _Eet_File_Mode Eet_File_Mode
|