/* Code generated by cmd/cgo; DO NOT EDIT. */ /* package git.openprivacy.ca/cwtch.im/libcwtch-go */ #line 1 "cgo-builtin-export-prolog" #include /* for ptrdiff_t below */ #ifndef GO_CGO_EXPORT_PROLOGUE_H #define GO_CGO_EXPORT_PROLOGUE_H #ifndef GO_CGO_GOSTRING_TYPEDEF typedef struct { const char *p; ptrdiff_t n; } _GoString_; #endif #endif /* Start of preamble from import "C" comments. */ #line 5 "lib.go" //Needed to invoke C.free #include #line 1 "cgo-generated-wrapper" /* End of preamble from import "C" comments. */ /* Start of boilerplate cgo prologue. */ #line 1 "cgo-gcc-export-header-prolog" #ifndef GO_CGO_PROLOGUE_H #define GO_CGO_PROLOGUE_H typedef signed char GoInt8; typedef unsigned char GoUint8; typedef short GoInt16; typedef unsigned short GoUint16; typedef int GoInt32; typedef unsigned int GoUint32; typedef long long GoInt64; typedef unsigned long long GoUint64; typedef GoInt64 GoInt; typedef GoUint64 GoUint; typedef __SIZE_TYPE__ GoUintptr; typedef float GoFloat32; typedef double GoFloat64; typedef float _Complex GoComplex64; typedef double _Complex GoComplex128; /* static assertion to make sure the file is being used on architecture at least with matching size of GoInt. */ typedef char _check_for_64_bit_pointer_matching_GoInt[sizeof(void*)==64/8 ? 1:-1]; #ifndef GO_CGO_GOSTRING_TYPEDEF typedef _GoString_ GoString; #endif typedef void *GoMap; typedef void *GoChan; typedef struct { void *t; void *v; } GoInterface; typedef struct { void *data; GoInt len; GoInt cap; } GoSlice; #endif /* End of boilerplate cgo prologue. */ #ifdef __cplusplus extern "C" { #endif extern int c_StartCwtch(char* dir_c, int len, char* tor_c, int torLen); extern void c_ReconnectCwtchForeground(); // A generic method for Rebroadcasting App Events from a UI extern void c_SendAppEvent(char* json_ptr, int json_len); // A generic method for Rebroadcasting Profile Events from a UI extern void c_SendProfileEvent(char* onion_ptr, int onion_len, char* json_ptr, int json_len); // the pointer returned from this function **must** be freed using c_Free extern char* c_GetAppBusEvent(); extern void c_CreateProfile(char* nick_ptr, int nick_len, char* pass_ptr, int pass_len); extern void c_LoadProfiles(char* passwordPtr, int passwordLen); extern void c_AcceptContact(char* profilePtr, int profileLen, char* handlePtr, int handleLen); extern void c_RejectInvite(char* profilePtr, int profileLen, char* handlePtr, int handleLen); extern void c_BlockContact(char* profilePtr, int profileLen, char* handlePtr, int handleLen); extern void c_UpdateMessageFlags(char* profile_ptr, int profile_len, char* handle_ptr, int handle_len, int mIdx, long unsigned int message_flags); // the pointer returned from this function **must** be Freed by c_Free extern char* c_GetMessage(char* profile_ptr, int profile_len, char* handle_ptr, int handle_len, int message_index); // the pointer returned from this function **must** be freed by calling c_Free extern char* c_GetMessagesByContentHash(char* profile_ptr, int profile_len, char* handle_ptr, int handle_len, char* contenthash_ptr, int contenthash_len); // Dangerous function. Should only be used as documented in `MEMORY.md` extern void c_FreePointer(char* ptr); extern void c_SendMessage(char* profile_ptr, int profile_len, char* handle_ptr, int handle_len, char* msg_ptr, int msg_len); extern void c_SendInvitation(char* profile_ptr, int profile_len, char* handle_ptr, int handle_len, char* target_ptr, int target_len); extern void c_ResetTor(); extern void c_CreateGroup(char* profile_ptr, int profile_len, char* server_ptr, int server_len, char* name_ptr, int name_len); extern void c_DeleteProfile(char* profile_ptr, int profile_len, char* password_ptr, int password_len); extern void c_ArchiveConversation(char* profile_ptr, int profile_len, char* contact_ptr, int contact_len); extern void c_DeleteContact(char* profile_ptr, int profile_len, char* hanlde_ptr, int handle_len); extern void c_ImportBundle(char* profile_ptr, int profile_len, char* bundle_ptr, int bundle_len); extern void c_SetProfileAttribute(char* profile_ptr, int profile_len, char* key_ptr, int key_len, char* val_ptr, int val_len); extern void c_SetContactAttribute(char* profile_ptr, int profile_len, char* contact_ptr, int contact_len, char* key_ptr, int key_len, char* val_ptr, int val_len); extern void c_SetGroupAttribute(char* profile_ptr, int profile_len, char* group_ptr, int group_len, char* key_ptr, int key_len, char* val_ptr, int val_len); extern void c_ShutdownCwtch(); #ifdef __cplusplus } #endif