├── Debug.xm ├── LICENSE ├── Makefile ├── NOTES.txt ├── OKPrefs ├── Makefile ├── OKDicts.h ├── OKDicts.mm ├── OKPrefs.h ├── OKPrefs.mm ├── OKPrefs.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── Resources │ ├── Info.plist │ ├── OKIcon.png │ ├── OKIcon@2x.png │ ├── Options.plist │ ├── UserDict.plist │ ├── about.txt │ └── buy.png ├── Shared.h ├── entry.plist ├── octopuscore │ └── OctopusDaemon │ │ └── .stamp ├── octopusd │ └── .stamp └── theos ├── Octopus.xcodeproj ├── kexik.mode1v3 ├── kexik.pbxuser ├── project.pbxproj └── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ └── Octopus.xccheckout ├── Octopus.xcworkspace └── contents.xcworkspacedata ├── OctopusBeast.h ├── OctopusBeast.mm ├── OctopusKeyboard.plist ├── README.md ├── TODO.txt ├── Tweak.xm ├── bin ├── dpkg-deb └── ldid ├── complete.h ├── complete.mm ├── include ├── curl │ ├── curl │ ├── curl.h │ ├── curlbuild.h │ ├── curlrules.h │ ├── curlver.h │ ├── easy.h │ ├── mprintf.h │ ├── multi.h │ ├── stdcheaders.h │ └── typecheck-gcc.h ├── gdbm.h ├── kptapi │ ├── License_EPL_V_1_0.html │ ├── Linux │ │ ├── License_EPL_V_1_0.html │ │ └── kptlibapi.h │ ├── android │ │ ├── License_EPL_V_1_0.html │ │ └── kptlibapi.h │ ├── kptapi_alloc.h │ ├── kptapi_cmd.h │ ├── kptapi_components.h │ ├── kptapi_componenttypes.h │ ├── kptapi_config.h │ ├── kptapi_create.h │ ├── kptapi_destroy.h │ ├── kptapi_dict.h │ ├── kptapi_dispatch.h │ ├── kptapi_error.h │ ├── kptapi_framework.h │ ├── kptapi_init.h │ ├── kptapi_inputmgr.h │ ├── kptapi_keymap.h │ ├── kptapi_lang.h │ ├── kptapi_learn.h │ ├── kptapi_libversion.h │ ├── kptapi_locking.h │ ├── kptapi_output.h │ ├── kptapi_packages.h │ ├── kptapi_personal.h │ ├── kptapi_progress.h │ ├── kptapi_result.h │ ├── kptapi_suggs.h │ ├── kptapi_suggtypes.h │ ├── symbian │ │ ├── License_EPL_V_1_0.html │ │ └── kptlibapi.h │ ├── win32 │ │ ├── License_EPL_V_1_0.html │ │ └── kptlibapi.h │ └── winSD │ │ ├── License_EPL_V_1_0.html │ │ └── kptlibapi.h ├── pal │ ├── License_EPL_V_1_0.html │ ├── android │ │ ├── kptcall.h │ │ ├── kptchar.h │ │ ├── kptendian.h │ │ ├── kptfilepath_platform.h │ │ ├── kptfmtspec.h │ │ ├── kptint.h │ │ ├── kptlibcode.h │ │ ├── kptlibcollections.h │ │ ├── kptlibsysmem.h │ │ ├── kptlibsystem.h │ │ ├── kptlibtest.h │ │ ├── kptlibunicode.h │ │ ├── kptlibutil.h │ │ ├── kptmemory.h │ │ └── kptunittest.h │ ├── cmockery.h │ ├── kptalloct.h │ ├── kptapi.h │ ├── kptassert.h │ ├── kptbinaryfile.h │ ├── kptbinarystore.h │ ├── kptbinarystream.h │ ├── kptbool.h │ ├── kptbyte.h │ ├── kptcheck.h │ ├── kptcodelibversion.h │ ├── kptcollectionslibversion.h │ ├── kptcommandline.h │ ├── kptcompile.h │ ├── kptcrc32.h │ ├── kptcrc32ieee.h │ ├── kptcritsection.h │ ├── kptdirmanager.h │ ├── kptdirscan.h │ ├── kptdllloader.h │ ├── kpterr.h │ ├── kpterrorstack.h │ ├── kptfilehdr.h │ ├── kptfilemanager.h │ ├── kptfilepath.h │ ├── kptfletcher16.h │ ├── kptformat.h │ ├── kpthandle.h │ ├── kptheap.h │ ├── kptid.h │ ├── kptiterator.h │ ├── kptlist.h │ ├── kptmap.h │ ├── kptmemoryfile.h │ ├── kptmemoryshare.h │ ├── kptout.h │ ├── kptpal.h │ ├── kptrad32.h │ ├── kptresult.h │ ├── kptstatus.h │ ├── kptstorage.h │ ├── kptstrings.h │ ├── kptsysmem.h │ ├── kptsysmemlibversion.h │ ├── kptsysstring.h │ ├── kptsysstringcontainer.h │ ├── kptsystemlibversion.h │ ├── kpttest.h │ ├── kpttestlibversion.h │ ├── kpttextfile.h │ ├── kpttextfilebomparser.h │ ├── kpttextfilecharconverter.h │ ├── kptthread.h │ ├── kpttime.h │ ├── kpttimer.h │ ├── kpttree.h │ ├── kptunicode.h │ ├── kptunicodelibversion.h │ ├── kptunicodetable.h │ ├── kptunistring.h │ ├── kptunistringcontainer.h │ ├── kptutillibversion.h │ ├── kptvector.h │ ├── private │ │ ├── KPTUnicodeData.h │ │ ├── android │ │ │ ├── kptpal_imp.h │ │ │ └── kptsystem.h │ │ ├── cmockery_internal.h │ │ ├── kptbinaryfile_internal.h │ │ ├── kptbinarystream_imp.h │ │ ├── kptbinheap.h │ │ ├── kptbstree.h │ │ ├── kptcrc32ieee_table.h │ │ ├── kptdirscan_imp.h │ │ ├── kpterrorstack_imp.h │ │ ├── kptfilepath_imp.h │ │ ├── kptfortify.h │ │ ├── kptfortify_user.h │ │ ├── kptheap_imp.h │ │ ├── kptorderedheap.h │ │ ├── kptout_imp.h │ │ ├── kptpool.h │ │ ├── kptrbtree.h │ │ ├── kpttextfile_private.h │ │ ├── kpttreebase.h │ │ ├── kpttreefactory.h │ │ ├── kptunicodebinarydata.h │ │ ├── kptvector_imp.h │ │ ├── symbian │ │ │ ├── kptglobal.h │ │ │ └── kptsystem.h │ │ ├── win32 │ │ │ └── kptsystem.h │ │ └── winSD │ │ │ └── kptsystem.h │ ├── symbian │ │ ├── kptcall.h │ │ ├── kptchar.h │ │ ├── kptendian.h │ │ ├── kptfilepath_platform.h │ │ ├── kptfmtspec.h │ │ ├── kptint.h │ │ ├── kptlibcode.h │ │ ├── kptlibcollections.h │ │ ├── kptlibsysmem.h │ │ ├── kptlibsystem.h │ │ ├── kptlibtest.h │ │ ├── kptlibunicode.h │ │ ├── kptlibutil.h │ │ └── kptmemory.h │ ├── win32 │ │ ├── kptcall.h │ │ ├── kptchar.h │ │ ├── kptendian.h │ │ ├── kptfilepath_platform.h │ │ ├── kptfmtspec.h │ │ ├── kptint.h │ │ ├── kptlibcode.h │ │ ├── kptlibcollections.h │ │ ├── kptlibsysmem.h │ │ ├── kptlibsystem.h │ │ ├── kptlibtest.h │ │ ├── kptlibunicode.h │ │ ├── kptlibutil.h │ │ ├── kptmemory.h │ │ └── kptunittest.h │ └── winSD │ │ ├── kptcall.h │ │ ├── kptchar.h │ │ ├── kptendian.h │ │ ├── kptfilepath_platform.h │ │ ├── kptfmtspec.h │ │ ├── kptint.h │ │ ├── kptlibcode.h │ │ ├── kptlibcollections.h │ │ ├── kptlibsysmem.h │ │ ├── kptlibsystem.h │ │ ├── kptlibtest.h │ │ ├── kptlibunicode.h │ │ ├── kptlibutil.h │ │ ├── kptmemory.h │ │ └── kptunittest.h ├── phrase_map.hpp ├── segtree.hpp ├── servers │ ├── bootstrap.h │ ├── bootstrap_defs.h │ ├── key_defs.h │ ├── ls_defs.h │ ├── netname.h │ ├── netname_defs.h │ └── nm_defs.h ├── sparsetable.hpp ├── suggest.hpp ├── types.hpp └── utils.hpp ├── langpacks ├── ar.deb ├── cz.deb ├── da.deb ├── de.deb ├── en-gb.deb ├── es.deb ├── et.deb ├── fi.deb ├── fr.deb ├── he.deb ├── id.deb ├── it.deb ├── layout │ ├── DEBIAN │ │ ├── control │ │ └── postinst │ └── Library │ │ └── Application Support │ │ └── OctopusKeyboard │ │ ├── Context │ │ ├── estee_0.atc │ │ ├── estee_1.atc │ │ └── estee_2.atc │ │ └── Dictionaries │ │ ├── estee.abn │ │ └── estee.atd ├── lt.deb ├── lv.deb ├── make.sh ├── ms.deb ├── nl.deb ├── no.deb ├── pl.deb ├── pt-BR.deb ├── pt-PT.deb ├── ro.deb ├── ru.deb ├── se.deb ├── tr.deb └── vn.deb ├── layout └── DEBIAN │ ├── control │ ├── postinst │ └── prerm ├── lib ├── libcurl.a ├── libcurl_armv6.a └── libkpt.a ├── octopus.h ├── octopus_mach_types.h ├── octopuscore ├── ATXProfile │ ├── ConfigSettings.dat │ ├── Context │ │ ├── User_0.atc │ │ ├── User_1.atc │ │ └── User_2.atc │ ├── Default_Profile.ata │ ├── Dictionaries │ │ └── User.atu │ ├── KPTUnicodeData.bin │ ├── Lang │ │ ├── v2_keymap0.atm │ │ └── v2_keymap1.atm │ ├── Profile.ata │ ├── Profile.ata.bak │ ├── cmplst.dat │ └── language.bin ├── ATXProfileBig │ ├── ConfigSettings.dat │ ├── Context │ │ ├── User_0.atc │ │ ├── User_1.atc │ │ ├── User_2.atc │ │ ├── czecz_0.atc │ │ ├── czecz_1.atc │ │ ├── czecz_2.atc │ │ ├── enggb_0.atc │ │ ├── enggb_1.atc │ │ └── enggb_2.atc │ ├── Default_Profile.ata │ ├── Dictionaries │ │ ├── User.atu │ │ ├── czecz.abn │ │ ├── czecz.atd │ │ ├── czecz001.atn │ │ ├── czecz_v2_keymap0001.atn │ │ ├── enggb.abn │ │ ├── enggb.atd │ │ ├── enggb001.atn │ │ ├── enggb_v2_keymap0001.atn │ │ └── enggb_v2_keymap1001.atn │ ├── EC │ │ └── atxcoretest.ini │ ├── FC │ │ └── atxcoretest.ini │ ├── KPTUnicodeData.bin │ ├── Lang │ │ ├── api_kmp_en-GB_KPTTestManu_KPTTestDev.atz │ │ ├── v2_keymap0.atm │ │ └── v2_keymap1.atm │ ├── Profile.ata │ ├── atxspchr.txt │ ├── cmplst.dat │ └── language.bin ├── KPTAPIUserGuide.pdf ├── Makefile ├── OctopusDaemon.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── OctopusDaemon │ ├── AntiGDB.h │ ├── Layouts.h │ ├── Layouts.mm │ ├── TextInput.h │ ├── TextInput.mm │ ├── examples.h │ ├── examples.mm │ ├── main.h │ ├── main.mm │ ├── octopus.defs │ ├── octopus.h │ ├── octopusServer.c │ ├── octopusUser.c │ └── octopus_mach_types.h ├── OctopusTest │ └── main.cpp ├── layout │ ├── DEBIAN │ │ └── control │ ├── Library │ │ └── Application Support │ │ │ └── OctopusKeyboard │ │ │ ├── ConfigSettings.dat │ │ │ ├── Context │ │ │ ├── engus_0.atc │ │ │ ├── engus_1.atc │ │ │ └── engus_2.atc │ │ │ ├── Default_Profile.ata │ │ │ ├── Dictionaries │ │ │ ├── engus.abn │ │ │ ├── engus.atd │ │ │ ├── engus001.atn │ │ │ ├── engus_v2_keymap0001.atn │ │ │ └── engus_v2_keymap1001.atn │ │ │ ├── KPTUnicodeData.bin │ │ │ ├── Lang │ │ │ ├── v2_keymap0.atm │ │ │ └── v2_keymap1.atm │ │ │ ├── Profile.ata │ │ │ ├── cmplst.dat │ │ │ └── language.bin │ └── System │ │ └── Library │ │ └── LaunchDaemons │ │ └── me.k3a.octopusd.plist ├── mig_manual.pdf └── theos └── theos /Makefile: -------------------------------------------------------------------------------- 1 | GO_EASY_ON_ME=1 2 | NO_RESPRING = 1 3 | 4 | export TARGET=iphone:latest:6.0 5 | export ARCHS = armv7 6 | # use CLANG 7 | TARGET_CC = xcrun --sdk iphoneos clang 8 | TARGET_CXX = xcrun --sdk iphoneos clang++ 9 | 10 | include theos/makefiles/common.mk 11 | 12 | SUBPROJECTS = octopuscore OKPrefs 13 | 14 | TWEAK_NAME = OctopusKeyboard 15 | OctopusKeyboard_FILES = Tweak.xm OctopusBeast.mm octopuscore/OctopusDaemon/octopusUser.c 16 | OctopusKeyboard_FRAMEWORKS = CoreGraphics UIKit QuartzCore 17 | OctopusKeyboard_PRIVATE_FRAMEWORKS = TextInput 18 | OctopusKeyboard_CFLAGS = -g0 -fvisibility=hidden -Iinclude -Iinclude/pal -Iinclude/pal/android -Iinclude/kptapi -Iinclude/kptapi/android -Ioctopuscore/OctopusDaemon 19 | OctopusKeyboard_LDFLAGS = -Llib 20 | ifeq ($(DEBUG),1) 21 | OctopusKeyboard_CFLAGS += -DDEBUG=1 22 | endif 23 | 24 | include $(THEOS_MAKE_PATH)/tweak.mk 25 | include $(THEOS_MAKE_PATH)/aggregate.mk 26 | 27 | testw: distclean package 28 | install.copyFile "$(THEOS_PACKAGE_DIR)/$(THEOS_PACKAGE_FILENAME).deb" "$(THEOS_PACKAGE_FILENAME).deb" 29 | install.exec "dpkg -i $(THEOS_PACKAGE_FILENAME).deb ; rm $(THEOS_PACKAGE_FILENAME).deb" 30 | install.exec "killall MobileSafari ; sleep 1 ; ~mobile/open Safari" 31 | 32 | test: distclean package install 33 | ssh ufoxy "killall octopusd; sleep 2; killall MobileNotes; ~/open Notes" 34 | 35 | ptest: distclean package install 36 | ssh root@ufoxy "killall Preferences ; sbopenurl 'prefs:root=Octopus Keyboard'" 37 | 38 | testd: distclean package install 39 | ssh ufoxy "killall octopusd " 40 | 41 | distclean: 42 | rm *.deb || true 43 | 44 | dumpdb: dumpdb.cpp 45 | xcrun -sdk iphoneos g++ -DTARGET_IPHONE=1 -O2 -I/theos//include -include /theos//Prefix.pch -Wall -isysroot "/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk" -arch armv6 -D__IPHONE_OS_VERSION_MIN_REQUIRED=__IPHONE_3_0 -miphoneos-version-min=3.0 -Iinclude -DDEBUG -ggdb -O0 dumpdb.cpp -o dumpdb -lgdbm -Llib 46 | -------------------------------------------------------------------------------- /OKPrefs/Makefile: -------------------------------------------------------------------------------- 1 | GO_EASY_ON_ME=1 2 | 3 | export TARGET=iphone:latest:6.0 4 | export ARCHS = armv7 5 | 6 | include theos/makefiles/common.mk 7 | 8 | BUNDLE_NAME = OKPrefs 9 | OKPrefs_FILES = OKPrefs.mm OKDicts.mm ../octopuscore/OctopusDaemon/octopusUser.c 10 | OKPrefs_INSTALL_PATH = /Library/PreferenceBundles 11 | OKPrefs_FRAMEWORKS = UIKit Accounts Twitter MessageUI 12 | OKPrefs_PRIVATE_FRAMEWORKS = Preferences AppSupport 13 | OKPrefs_CFLAGS = -I../include 14 | OKPrefs_LDFLAGS = -L../lib 15 | 16 | include $(THEOS_MAKE_PATH)/bundle.mk 17 | 18 | internal-stage:: 19 | $(ECHO_NOTHING)mkdir -p $(THEOS_STAGING_DIR)/Library/PreferenceLoader/Preferences$(ECHO_END) 20 | $(ECHO_NOTHING)cp entry.plist $(THEOS_STAGING_DIR)/Library/PreferenceLoader/Preferences/OKPrefs.plist$(ECHO_END) 21 | 22 | test: all stage 23 | ssh root@ufoxy "rm -rf /Library/PreferenceBundles/OKPrefs.bundle ; killall Preferences || true" 24 | scp -r $(THEOS_STAGING_DIR)/* root@ufoxy:/ 25 | ssh root@ufoxy "sbopenurl 'prefs:root=Octopus Keyboard'" 26 | -------------------------------------------------------------------------------- /OKPrefs/OKDicts.h: -------------------------------------------------------------------------------- 1 | // 2 | // OKDicts.h 3 | // OKPrefs 4 | // 5 | // Created by K3A on 6/15/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #import "OKPrefs.h" 10 | 11 | @interface OKDicts : PSViewController { 12 | //UITableView* _view; 13 | NSMutableArray* _dicts; 14 | } 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /OKPrefs/OKPrefs.h: -------------------------------------------------------------------------------- 1 | // 2 | // SEPrefs.h 3 | // SEPrefs 4 | // 5 | // Created by K3A on 3/3/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | extern "C" { 13 | #include "../octopuscore/OctopusDaemon/octopus.h" 14 | } 15 | 16 | #define PREF_FILE "/var/mobile/Library/Preferences/me.k3a.OctopusKeyboard.plist" 17 | #define COLOBUS_PREF_FILE "/var/mobile/Library/Preferences/.me.k3a.OctopusKeyboard.plist" 18 | 19 | mach_port_t GetServerPort(); 20 | 21 | @interface K3AOKPrefsController : PSViewController { 22 | 23 | UITableView *_tableView; 24 | //NSMutableString *_title; 25 | NSMutableDictionary *_settings; 26 | NSMutableDictionary *_colobusSettings; 27 | NSString* _softVersion; 28 | 29 | unsigned _state; // 0-unknown, 1-success, 2-fail 30 | } 31 | +(K3AOKPrefsController*)instance; 32 | - (id) view; 33 | - (id) navigationTitle; 34 | - (void) dealloc; 35 | - (void)loadFromSpecifier:(PSSpecifier *)spec; 36 | - (void)setSpecifier:(PSSpecifier *)spec; 37 | -(void)saveSettings; 38 | -(int)prefInt:(NSString*)key default:(int)def; 39 | -(BOOL)setPrefInt:(NSString*)key value:(int)val; 40 | 41 | -(void)onSuccess; 42 | -(void)onFail; 43 | 44 | @end 45 | 46 | @interface UISwitch (K3AOKAdditions) 47 | - (void)setAlternateColors:(BOOL)alternateColors; 48 | @end 49 | -------------------------------------------------------------------------------- /OKPrefs/OKPrefs.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /OKPrefs/Resources/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | English 7 | CFBundleExecutable 8 | OKPrefs 9 | CFBundleIdentifier 10 | me.k3a.okprefs 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 1.0.0 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1.0 21 | DTPlatformName 22 | iphoneos 23 | MinimumOSVersion 24 | 3.0 25 | NSPrincipalClass 26 | K3AOKPrefsController 27 | 28 | 29 | -------------------------------------------------------------------------------- /OKPrefs/Resources/OKIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/OKPrefs/Resources/OKIcon.png -------------------------------------------------------------------------------- /OKPrefs/Resources/OKIcon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/OKPrefs/Resources/OKIcon@2x.png -------------------------------------------------------------------------------- /OKPrefs/Resources/buy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/OKPrefs/Resources/buy.png -------------------------------------------------------------------------------- /OKPrefs/Shared.h: -------------------------------------------------------------------------------- 1 | // 2 | // Shared.h 3 | // SEPrefs 4 | // 5 | // Created by K3A on 2/26/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface PSViewController (K3ASEPrefsFakeUIViewController) 13 | -(void)presentModalViewController:(id)ctrl animated:(BOOL)animated; 14 | -(void)dismissModalViewControllerAnimated:(BOOL)animated; 15 | @property(nonatomic, readonly) UINavigationController* navigationController; 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /OKPrefs/entry.plist: -------------------------------------------------------------------------------- 1 | { 2 | entry = { 3 | bundle = OKPrefs; 4 | cell = PSLinkCell; 5 | detail = K3AOKPrefsController; 6 | icon = OKIcon.png; 7 | isController = 1; 8 | label = "Octopus Keyboard"; 9 | }; 10 | } 11 | -------------------------------------------------------------------------------- /OKPrefs/octopuscore/OctopusDaemon/.stamp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/OKPrefs/octopuscore/OctopusDaemon/.stamp -------------------------------------------------------------------------------- /OKPrefs/octopusd/.stamp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/OKPrefs/octopusd/.stamp -------------------------------------------------------------------------------- /OKPrefs/theos: -------------------------------------------------------------------------------- 1 | /theos -------------------------------------------------------------------------------- /Octopus.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Octopus.xcodeproj/project.xcworkspace/xcshareddata/Octopus.xccheckout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDESourceControlProjectFavoriteDictionaryKey 6 | 7 | IDESourceControlProjectIdentifier 8 | C5D70C98-5CD9-4665-8249-813404EE85C3 9 | IDESourceControlProjectName 10 | Octopus 11 | IDESourceControlProjectOriginsDictionary 12 | 13 | 5398645D-AFC9-4EBE-A681-A2FEB4BC61B4 14 | svn://reversity.org/octopus/trunk 15 | 16 | IDESourceControlProjectPath 17 | Octopus.xcodeproj/project.xcworkspace 18 | IDESourceControlProjectRelativeInstallPathDictionary 19 | 20 | 5398645D-AFC9-4EBE-A681-A2FEB4BC61B4 21 | ../.. 22 | 23 | IDESourceControlProjectRepositoryRootDictionary 24 | 25 | 5398645D-AFC9-4EBE-A681-A2FEB4BC61B4 26 | svn://reversity.org/octopus 27 | 28 | IDESourceControlProjectURL 29 | svn://reversity.org/octopus/trunk/Octopus.xcodeproj 30 | IDESourceControlProjectVersion 31 | 110 32 | IDESourceControlProjectWCCIdentifier 33 | 5398645D-AFC9-4EBE-A681-A2FEB4BC61B4 34 | IDESourceControlProjectWCConfigurations 35 | 36 | 37 | IDESourceControlRepositoryExtensionIdentifierKey 38 | public.vcs.subversion 39 | IDESourceControlRepositoryTrunkRelativeLocationKey 40 | trunk 41 | IDESourceControlWCCIdentifierKey 42 | 5398645D-AFC9-4EBE-A681-A2FEB4BC61B4 43 | IDESourceControlWCCName 44 | octopus 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /Octopus.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /OctopusKeyboard.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Filter 6 | 7 | Bundles 8 | 9 | com.apple.UIKit 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /bin/dpkg-deb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/bin/dpkg-deb -------------------------------------------------------------------------------- /bin/ldid: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/bin/ldid -------------------------------------------------------------------------------- /complete.h: -------------------------------------------------------------------------------- 1 | #include "include/types.hpp" 2 | 3 | bool db_init(const char* inpMode); 4 | bool db_shutdown(); 5 | void db_refresh(); 6 | int db_store(char *word); 7 | bool db_sync(); 8 | 9 | void db_lowercase(); 10 | 11 | unsigned face_init(); 12 | // returns the std::list of suggestions, each item has phrase and weight members 13 | vp_t face_query(const char* iline, unsigned num); 14 | 15 | -------------------------------------------------------------------------------- /include/curl/curlver.h: -------------------------------------------------------------------------------- 1 | #ifndef __CURL_CURLVER_H 2 | #define __CURL_CURLVER_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2013, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at http://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | /* This header file contains nothing but libcurl version info, generated by 26 | a script at release-time. This was made its own header file in 7.11.2 */ 27 | 28 | /* This is the global package copyright */ 29 | #define LIBCURL_COPYRIGHT "1996 - 2013 Daniel Stenberg, ." 30 | 31 | /* This is the version number of the libcurl package from which this header 32 | file origins: */ 33 | #define LIBCURL_VERSION "7.29.0" 34 | 35 | /* The numeric version number is also available "in parts" by using these 36 | defines: */ 37 | #define LIBCURL_VERSION_MAJOR 7 38 | #define LIBCURL_VERSION_MINOR 29 39 | #define LIBCURL_VERSION_PATCH 0 40 | 41 | /* This is the numeric version of the libcurl version number, meant for easier 42 | parsing and comparions by programs. The LIBCURL_VERSION_NUM define will 43 | always follow this syntax: 44 | 45 | 0xXXYYZZ 46 | 47 | Where XX, YY and ZZ are the main version, release and patch numbers in 48 | hexadecimal (using 8 bits each). All three numbers are always represented 49 | using two digits. 1.2 would appear as "0x010200" while version 9.11.7 50 | appears as "0x090b07". 51 | 52 | This 6-digit (24 bits) hexadecimal number does not show pre-release number, 53 | and it is always a greater number in a more recent release. It makes 54 | comparisons with greater than and less than work. 55 | */ 56 | #define LIBCURL_VERSION_NUM 0x071d00 57 | 58 | /* 59 | * This is the date and time when the full source package was created. The 60 | * timestamp is not stored in git, as the timestamp is properly set in the 61 | * tarballs by the maketgz script. 62 | * 63 | * The format of the date should follow this template: 64 | * 65 | * "Mon Feb 12 11:35:33 UTC 2007" 66 | */ 67 | #define LIBCURL_TIMESTAMP "Wed Feb 6 10:13:08 UTC 2013" 68 | 69 | #endif /* __CURL_CURLVER_H */ 70 | -------------------------------------------------------------------------------- /include/curl/stdcheaders.h: -------------------------------------------------------------------------------- 1 | #ifndef __STDC_HEADERS_H 2 | #define __STDC_HEADERS_H 3 | /*************************************************************************** 4 | * _ _ ____ _ 5 | * Project ___| | | | _ \| | 6 | * / __| | | | |_) | | 7 | * | (__| |_| | _ <| |___ 8 | * \___|\___/|_| \_\_____| 9 | * 10 | * Copyright (C) 1998 - 2010, Daniel Stenberg, , et al. 11 | * 12 | * This software is licensed as described in the file COPYING, which 13 | * you should have received as part of this distribution. The terms 14 | * are also available at http://curl.haxx.se/docs/copyright.html. 15 | * 16 | * You may opt to use, copy, modify, merge, publish, distribute and/or sell 17 | * copies of the Software, and permit persons to whom the Software is 18 | * furnished to do so, under the terms of the COPYING file. 19 | * 20 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 21 | * KIND, either express or implied. 22 | * 23 | ***************************************************************************/ 24 | 25 | #include 26 | 27 | size_t fread (void *, size_t, size_t, FILE *); 28 | size_t fwrite (const void *, size_t, size_t, FILE *); 29 | 30 | int strcasecmp(const char *, const char *); 31 | int strncasecmp(const char *, const char *, size_t); 32 | 33 | #endif /* __STDC_HEADERS_H */ 34 | -------------------------------------------------------------------------------- /include/kptapi/Linux/kptlibapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibapi.h 16 | * 17 | * @brief Include file for the KPT API library (Linux) 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptcompile.h" 27 | 28 | #ifndef H_KPT_LIBAPI_H 29 | #define H_KPT_LIBAPI_H 30 | 31 | /* Using the code directly */ 32 | #define KPT_LIB_API 33 | 34 | #endif /* #ifndef H_KPT_LIBAPI_H */ 35 | -------------------------------------------------------------------------------- /include/kptapi/android/kptlibapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibapi.h 16 | * 17 | * @brief Include file for the KPT API library (Android) 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptcompile.h" 27 | 28 | #ifndef H_KPT_LIBAPI_H 29 | #define H_KPT_LIBAPI_H 30 | 31 | /* Using the code directly */ 32 | #define KPT_LIB_API __attribute__ ((visibility("default"))) 33 | 34 | #endif /* #ifndef H_KPT_LIBAPI_H */ 35 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_alloc.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_alloc.h 16 | * 17 | * @brief API Allocation Functions. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_ALLOC_H 27 | #define H_KPTAPI_ALLOC_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | KPT_LIB_API 34 | KPTResultT 35 | KPT_CALL 36 | KPTFwkReleaseAlloc(void *aAllocT); 37 | 38 | #ifdef __cplusplus 39 | } 40 | #endif /*__cplusplus */ 41 | 42 | #endif /* #ifndef H_KPTAPI_ALLOC_H */ 43 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_components.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_components.h 16 | * 17 | * @brief Types and defines for Component Management. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_COMPONENTS_H 27 | #define H_KPTAPI_COMPONENTS_H 28 | 29 | /** Component Identifier */ 30 | typedef uint32_t KPTComponentIdT; 31 | 32 | /** Component Type (@ref kptapi_componenttypes.h) */ 33 | typedef uint32_t KPTComponentTypeT; 34 | 35 | /** State information for a single component */ 36 | typedef struct KPTComponentInfoT KPTComponentInfoT; 37 | 38 | /** State information for a single component */ 39 | struct KPTComponentInfoT 40 | { 41 | KPTComponentIdT componentId; /**< Runtime identifier for the component */ 42 | KPTComponentTypeT componentType; /**< Component type (@ref kptapi_componenttypes.h)*/ 43 | uint32_t version; /**< Component version */ 44 | KPTBoolT isLoaded; /**< Loaded state */ 45 | KPTBoolT isActive; /**< Active state */ 46 | intptr_t extraDetails; /**< This field depends on the component type (@ref kptapi_componenttypes.h)*/ 47 | }; 48 | 49 | /** A container for KPTComponentInfoT items */ 50 | typedef struct KPTComponentListAllocT KPTComponentListAllocT; 51 | struct KPTComponentListAllocT 52 | { 53 | KPTComponentInfoT* components; /**< list of components */ 54 | size_t count; /**< number of components */ 55 | }; 56 | 57 | /** Value for unassigned component IDs */ 58 | #define KPT_COMPONENTID_INVALID 0 59 | 60 | #endif /* #ifndef H_KPTAPI_COMPONENTS_H */ 61 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_componenttypes.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_componenttypes.h 16 | * 17 | * @brief Defines and structures for API component types. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_COMPONENTTYPES_H 27 | #define H_KPTAPI_COMPONENTTYPES_H 28 | 29 | #include "kptapi_dict.h" 30 | 31 | /** Component type base value (not used directly) */ 32 | #define KPT_COMPONENTTYPE 0x00000000 33 | 34 | /** Application component type */ 35 | #define KPT_COMPONENTTYPE_ADAPTXTENGINE (KPT_COMPONENTTYPE + 1) 36 | 37 | /** Dictionary component type */ 38 | #define KPT_COMPONENTTYPE_DICTIONARY (KPT_COMPONENTTYPE + 2) 39 | 40 | 41 | /** 42 | * KPTComponentExtra...T (eg KPTComponentExtraDictionaryT) begin with a uint32. 43 | * So components' "Extra Details" space must be rounded up to end on a 4-byte boundary 44 | */ 45 | #define KPT_COMPONENTEXTRA_ALIGNMENTSIZE 4 46 | 47 | 48 | /** 49 | * Extra details structure for @ref KPT_COMPONENTTYPE_DICTIONARY type. 50 | * To access this information the caller must cast the field KPTComponentInfoT::extraDetails 51 | * to a const KPTComponentExtraDictionaryT*. 52 | */ 53 | typedef struct KPTComponentExtraDictionaryT KPTComponentExtraDictionaryT; 54 | struct KPTComponentExtraDictionaryT 55 | { 56 | uint32_t type; /**< Component type.*/ 57 | KPTDictInfoT dictInfo; /**< Dictionary detail information.*/ 58 | KPTDictStateT dictState; /**< Dictionary state information.*/ 59 | }; 60 | 61 | #endif /* #ifndef H_KPTAPI_COMPONENTTYPES_H */ 62 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_config.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_config.h 16 | * 17 | * @brief Types and defines for Configuration Management. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_CONFIG_H 27 | #define H_KPTAPI_CONFIG_H 28 | 29 | /** 30 | * Values for the locking state. 31 | */ 32 | enum KPTLockingStateT 33 | { 34 | eKPTLockingInvalid = 0, /**< Undefined value */ 35 | eKPTLockingOn = 1, /**< Locking on */ 36 | eKPTLockingOff = 2 /**< Do not lock */ 37 | }; 38 | typedef enum KPTLockingStateT KPTLockingStateT; 39 | 40 | #endif /* #ifndef H_KPTAPI_CONFIG_H */ 41 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_create.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_create.h 16 | * 17 | * @brief Create types and structures. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_CREATE_H 27 | #define H_KPTAPI_CREATE_H 28 | 29 | #include "kptapi_init.h" 30 | 31 | /***************************************************************************** 32 | * Creation Parameters 33 | *****************************************************************************/ 34 | 35 | /** Creation initialisation structure type. */ 36 | typedef struct KPTCreateParamsT KPTCreateParamsT; 37 | struct KPTCreateParamsT 38 | { 39 | KPTInitT* initItems; /**< Initialisation items */ 40 | size_t initItemCount; /**< Number of initialisation items */ 41 | }; 42 | 43 | #ifdef __cplusplus 44 | extern "C" { 45 | #endif /* __cplusplus */ 46 | 47 | /** Creates the Framework. */ 48 | KPT_LIB_API 49 | KPTResultT 50 | KPT_CALL 51 | KPTFwkCreate(const KPTCreateParamsT* aCreate); 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif /*__cplusplus */ 56 | 57 | 58 | #endif /* #ifndef H_KPTAPI_CREATE_H */ 59 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_destroy.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_destroy.h 16 | * 17 | * @brief Destroy Functionality. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_DESTROY_H 27 | #define H_KPTAPI_DESTROY_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | KPT_LIB_API 34 | KPTResultT 35 | KPT_CALL 36 | KPTFwkDestroy(void); 37 | 38 | #ifdef __cplusplus 39 | } 40 | #endif /*__cplusplus */ 41 | 42 | #endif /* #ifndef H_KPTAPI_DESTROY_H */ 43 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_dispatch.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_dispatch.h 16 | * 17 | * @brief Dispatch Interface 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_DISPATCH_H 27 | #define H_KPTAPI_DISPATCH_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | KPT_LIB_API 34 | KPTResultT 35 | KPT_CALL 36 | KPTFwkRunCmd(uint32_t aCommand, 37 | intptr_t aFirst, 38 | intptr_t aSecond); 39 | 40 | 41 | KPT_LIB_API 42 | KPTResultT 43 | KPT_CALL 44 | KPTFwkCancelCmd(void); 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif /*__cplusplus */ 49 | 50 | 51 | #endif /* #ifndef H_KPTAPI_DISPATCH_H */ 52 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_error.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_error.h 16 | * 17 | * @brief Error Manager Types and Structures. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_ERROR_H 27 | #define H_KPTAPI_ERROR_H 28 | 29 | /** 30 | * Field-in-use masks for KPTErrorPopStackT::fieldMask 31 | */ 32 | enum KPTErrorStackPopMaskT 33 | { 34 | eKPTErrorReadCodes = KPTBIT(0), /**< Read error codes (@ref KPTErrorDetailsT::resultCode 35 | and @ref KPTErrorDetailsT::additionalErrorCode)*/ 36 | eKPTErrorReadEntireString = KPTBIT(1), /**< Read string into KPTErrorDetailsT::errorString and 37 | fail if KPTErrorDetailsT::buffLen is not large enough */ 38 | eKPTErrorReadPartialString = KPTBIT(2), /**< Read string into KPTErrorDetailsT::errorString and 39 | truncate text if KPTErrorDetailsT::buffLen is not large enough */ 40 | 41 | eKPTErrorReadCodesAndEntireString = (eKPTErrorReadCodes | eKPTErrorReadEntireString), /**< eKPTErrorReadCodes | eKPTErrorReadEntireString */ 42 | eKPTErrorReadCodesAndPartialString = (eKPTErrorReadCodes | eKPTErrorReadPartialString) /**< eKPTErrorReadCodes | eKPTErrorReadPartialString */ 43 | }; 44 | typedef enum KPTErrorStackPopMaskT KPTErrorStackPopMaskT; 45 | 46 | /** 47 | * Structure containing error details 48 | * 49 | */ 50 | typedef struct KPTErrorDetailsT KPTErrorDetailsT; 51 | struct KPTErrorDetailsT 52 | { 53 | KPTResultT resultCode; /**< Framework result code */ 54 | uint32_t additionalErrorCode; /**< Additional error code (eg from Operating System) */ 55 | KPTSysCharT* errorString; /**< String details associated with error (eg filename). NULL if not used */ 56 | uint32_t buffLen; /**< Length of buffer on input and length required/written on output. Includes terminating NULL character */ 57 | }; 58 | 59 | 60 | /** 61 | * Structure used when reading an error from the error stack 62 | */ 63 | typedef struct KPTErrorPopStackT KPTErrorPopStackT; 64 | struct KPTErrorPopStackT 65 | { 66 | uint32_t fieldMask; /**< Identifies fields in use (@ref KPTErrorStackPopMaskT)*/ 67 | KPTErrorDetailsT errorDetails; /**< Error details */ 68 | }; 69 | 70 | #endif /* #ifndef H_KPTAPI_ERROR_H */ 71 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_framework.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_framework.h 16 | * 17 | * @brief Framework interface 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_FRAMEWORK_H 27 | #define H_KPTAPI_FRAMEWORK_H 28 | 29 | #include "kptlibapi.h" 30 | #include "kptapi.h" 31 | #include "kptapi_result.h" 32 | #include "kptapi_create.h" 33 | #include "kptapi_dispatch.h" 34 | #include "kptapi_destroy.h" 35 | #include "kptapi_locking.h" 36 | #include "kptapi_alloc.h" 37 | #include "kptapi_libversion.h" 38 | #include "kptapi_cmd.h" 39 | 40 | #endif /* #ifndef H_KPTAPI_FRAMEWORK_H */ 41 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_init.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_init.h 16 | * 17 | * @brief Initialisation Types and Structures. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_INIT_H 27 | #define H_KPTAPI_INIT_H 28 | 29 | #include "kptapi_components.h" 30 | 31 | /***************************************************************************** 32 | * Basic Types 33 | *****************************************************************************/ 34 | 35 | /** Base initialisation structure. */ 36 | typedef struct KPTInitT KPTInitT; 37 | struct KPTInitT 38 | { 39 | KPTComponentIdT component; /**< Component to be initialised */ 40 | uint32_t version; /**< Version of component data */ 41 | intptr_t key; /**< Defines the initialisation setting to update */ 42 | intptr_t value; /**< Specifies the new value for the setting */ 43 | }; 44 | 45 | 46 | /* 47 | * Initialisation keys 48 | * 49 | * The values here are only unique for a given component 50 | * 51 | * Other data types (strings, pointers to structures) can be used as keys as well 52 | * but it makes sense for all keys for a given component to be the same type. 53 | */ 54 | 55 | /** 56 | * Enables or disables Framework command locking [Optional] 57 | * 58 | * The KPTInitT::key type is KPTBoolT, either eKPTTrue or eKPTFalse 59 | */ 60 | #define KPT_INIT_FRAMEWORK_LOCKINGENABLED 0x00000001 61 | 62 | /** 63 | * Sets the base path for the Framework's files [Required] 64 | * 65 | * The KPTInitT::key type is const KPTSysCharT* 66 | */ 67 | #define KPT_INIT_FRAMEWORK_BASEPATH 0x00000002 68 | 69 | #endif /* #ifndef H_KPTAPI_INIT_H */ 70 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_libversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_libversion.h 16 | * 17 | * @brief API Library Version Information 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_LIBVERSION_H 27 | #define H_KPTAPI_LIBVERSION_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | /* library version */ 34 | KPT_LIB_API 35 | KPTResultT 36 | KPT_CALL 37 | KPTFwkGetVersion(uint16_t* aMajor, 38 | uint16_t* aMinor, 39 | uint16_t* aPatch, 40 | uint16_t* aBuild); 41 | 42 | #ifdef __cplusplus 43 | } 44 | #endif /*__cplusplus */ 45 | 46 | #endif /* #ifndef H_KPTAPI_LIBVERSION_H */ 47 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_locking.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_locking.h 16 | * 17 | * @brief API Locking Functions. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_LOCKING_H 27 | #define H_KPTAPI_LOCKING_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | /* Locks the framework */ 34 | KPT_LIB_API 35 | KPTResultT 36 | KPT_CALL 37 | KPTFwkGetLock(int32_t aTimeoutMilliseconds); 38 | 39 | /* Releases a lock on the framework */ 40 | KPT_LIB_API 41 | KPTResultT 42 | KPT_CALL 43 | KPTFwkReleaseLock(void); 44 | 45 | #ifdef __cplusplus 46 | } 47 | #endif /*__cplusplus */ 48 | 49 | #endif /* #ifndef H_KPTAPI_LOCKING_H */ 50 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_progress.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_progress.h 16 | * 17 | * @brief Progress types. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_PROGRESS_H 27 | #define H_KPTAPI_PROGRESS_H 28 | 29 | #include "kptapi.h" 30 | 31 | /** Progress item */ 32 | typedef struct KPTProgressItemT KPTProgressItemT; 33 | struct KPTProgressItemT 34 | { 35 | size_t maximum; /**< Maximum value */ 36 | size_t position; /**< Position */ 37 | }; 38 | 39 | /** Progress data */ 40 | typedef struct KPTProgressDataT KPTProgressDataT; 41 | struct KPTProgressDataT 42 | { 43 | KPTProgressItemT current; /**< Progress for current item */ 44 | KPTProgressItemT overall; /**< Progress for overall operation */ 45 | }; 46 | 47 | /** 48 | * Function signature for progress callbacks. 49 | * 50 | * @param[in] aProgress Progress information returned with the callback. 51 | * @param[in] aContext User provided information associated with the callback. 52 | * @return KPTResultT. 53 | */ 54 | typedef KPTResultT (KPT_CALLB *KPTProgressFnT)(const KPTProgressDataT* aProgress, intptr_t aContext); 55 | 56 | #endif /* #ifndef H_KPTAPI_PROGRESS_H */ 57 | -------------------------------------------------------------------------------- /include/kptapi/kptapi_result.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi_result.h 16 | * 17 | * @brief Return types and macros in the KPT system. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_RESULT_H 27 | #define H_KPTAPI_RESULT_H 28 | 29 | #include "kptresult.h" 30 | 31 | #define KPT_CC_FRAMEWORK 0x101 32 | #define KPT_CC_APIMGMT 0x102 33 | #define KPT_CC_CONFIG 0x103 34 | #define KPT_CC_DICTIONARIES 0x104 35 | #define KPT_CC_ERRORMGR 0x105 36 | #define KPT_CC_INPUTMGR 0x106 37 | #define KPT_CC_KEYMAP 0x107 38 | #define KPT_CC_LEARNING 0x108 39 | #define KPT_CC_COMPONENTS 0x10A 40 | #define KPT_CC_OUTPUT 0x10D 41 | #define KPT_CC_PACKAGEMGMT 0x10E 42 | #define KPT_CC_PERSONAL 0x10F 43 | #define KPT_CC_SUGGESTIONS 0x112 44 | #define KPT_CC_FILE 0x116 45 | #define KPT_CC_LANGUAGE 0x117 46 | #define KPT_CC_TEMPV2SUPPORT 0x118 47 | 48 | #endif /* #ifndef H_KPTAPI_RESULT_H */ 49 | -------------------------------------------------------------------------------- /include/kptapi/symbian/kptlibapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibapi.h 16 | * 17 | * @brief Include file for the KPT API library (symbian) 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptcompile.h" 27 | 28 | #ifndef H_KPT_LIBAPI_H 29 | #define H_KPT_LIBAPI_H 30 | 31 | #if defined KPT_LIBAPI_DLL 32 | 33 | /* Using library as a DLL */ 34 | #define KPT_LIB_API __declspec(dllimport) 35 | 36 | #if defined _MT 37 | 38 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 39 | #if defined _DLL 40 | 41 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 42 | #if defined(_DEBUG) 43 | #pragma comment(lib, "kptframeworkv2DMDd.lib") 44 | #else 45 | #pragma comment(lib, "kptframeworkv2DMD.lib") 46 | #endif 47 | 48 | #else 49 | 50 | #if defined(_DEBUG) 51 | #pragma comment(lib, "kptframeworkv2DMTd.lib") 52 | #else 53 | #pragma comment(lib, "kptframeworkv2DMT.lib") 54 | #endif 55 | 56 | #endif 57 | 58 | #endif 59 | 60 | #elif defined KPT_LIBAPI_CREATEDLL 61 | 62 | /* Creating library as a DLL */ 63 | #define KPT_LIB_API __declspec(dllexport) 64 | 65 | #elif defined KPT_LIBAPI_LIB 66 | 67 | /* Using library as a static library */ 68 | #define KPT_LIB_API 69 | 70 | #if defined _MT 71 | 72 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 73 | #if defined _DLL 74 | 75 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 76 | #if defined(_DEBUG) 77 | #pragma comment(lib, "kptframeworkv2SMDd.lib") 78 | #else 79 | #pragma comment(lib, "kptframeworkv2SMD.lib") 80 | #endif 81 | 82 | #else 83 | 84 | #if defined(_DEBUG) 85 | #pragma comment(lib, "kptframeworkv2SMTd.lib") 86 | #else 87 | #pragma comment(lib, "kptframeworkv2SMT.lib") 88 | #endif 89 | 90 | #endif 91 | 92 | #endif 93 | 94 | #elif defined KPT_LIBAPI_CREATELIB 95 | 96 | /* Creating library as a static library */ 97 | #define KPT_LIB_API 98 | 99 | #else 100 | 101 | /* No specification */ 102 | #define KPT_LIB_API 103 | 104 | #endif 105 | 106 | #endif /* #ifndef H_KPT_LIBAPI_H */ 107 | -------------------------------------------------------------------------------- /include/kptapi/win32/kptlibapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibapi.h 16 | * 17 | * @brief Include file for the KPT API library (Win32) 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptcompile.h" 27 | 28 | #ifndef H_KPT_LIBAPI_H 29 | #define H_KPT_LIBAPI_H 30 | 31 | #if defined KPT_LIBAPI_DLL 32 | 33 | /* Using library as a DLL */ 34 | #define KPT_LIB_API __declspec(dllimport) 35 | 36 | #if defined _MT 37 | 38 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 39 | #if defined _DLL 40 | 41 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 42 | #if defined(_DEBUG) 43 | #pragma comment(lib, "kptframeworkv2DMDd.lib") 44 | #else 45 | #pragma comment(lib, "kptframeworkv2DMD.lib") 46 | #endif 47 | 48 | #else 49 | 50 | #if defined(_DEBUG) 51 | #pragma comment(lib, "kptframeworkv2DMTd.lib") 52 | #else 53 | #pragma comment(lib, "kptframeworkv2DMT.lib") 54 | #endif 55 | 56 | #endif 57 | 58 | #endif 59 | 60 | #elif defined KPT_LIBAPI_CREATEDLL 61 | 62 | /* Creating library as a DLL */ 63 | #define KPT_LIB_API __declspec(dllexport) 64 | 65 | #elif defined KPT_LIBAPI_LIB 66 | 67 | /* Using library as a static library */ 68 | #define KPT_LIB_API 69 | 70 | #if defined _MT 71 | 72 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 73 | #if defined _DLL 74 | 75 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 76 | #if defined(_DEBUG) 77 | #pragma comment(lib, "kptframeworkv2SMDd.lib") 78 | #else 79 | #pragma comment(lib, "kptframeworkv2SMD.lib") 80 | #endif 81 | 82 | #else 83 | 84 | #if defined(_DEBUG) 85 | #pragma comment(lib, "kptframeworkv2SMTd.lib") 86 | #else 87 | #pragma comment(lib, "kptframeworkv2SMT.lib") 88 | #endif 89 | 90 | #endif 91 | 92 | #endif 93 | 94 | #elif defined KPT_LIBAPI_CREATELIB 95 | 96 | /* Creating library as a static library */ 97 | #define KPT_LIB_API 98 | 99 | #else 100 | 101 | /* No specification */ 102 | #define KPT_LIB_API 103 | 104 | #endif 105 | 106 | #endif /* #ifndef H_KPT_LIBAPI_H */ 107 | -------------------------------------------------------------------------------- /include/kptapi/winSD/kptlibapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibapi.h 16 | * 17 | * @brief Include file for the KPT API library (Windows SD) 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptcompile.h" 27 | 28 | #ifndef H_KPT_LIBAPI_H 29 | #define H_KPT_LIBAPI_H 30 | 31 | #if defined KPT_LIBAPI_DLL 32 | 33 | /* Using library as a DLL */ 34 | #define KPT_LIB_API __declspec(dllimport) 35 | 36 | #if defined _MT 37 | 38 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 39 | #if defined _DLL 40 | 41 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 42 | #if defined(_DEBUG) 43 | #pragma comment(lib, "kptframeworkv2DMDd.lib") 44 | #else 45 | #pragma comment(lib, "kptframeworkv2DMD.lib") 46 | #endif 47 | 48 | #else 49 | 50 | #if defined(_DEBUG) 51 | #pragma comment(lib, "kptframeworkv2DMTd.lib") 52 | #else 53 | #pragma comment(lib, "kptframeworkv2DMT.lib") 54 | #endif 55 | 56 | #endif 57 | 58 | #endif 59 | 60 | #elif defined KPT_LIBAPI_CREATEDLL 61 | 62 | /* Creating library as a DLL */ 63 | #define KPT_LIB_API __declspec(dllexport) 64 | 65 | #elif defined KPT_LIBAPI_LIB 66 | 67 | /* Using library as a static library */ 68 | #define KPT_LIB_API 69 | 70 | #if defined _MT 71 | 72 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 73 | #if defined _DLL 74 | 75 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 76 | #if defined(_DEBUG) 77 | #pragma comment(lib, "kptframeworkv2SMDd.lib") 78 | #else 79 | #pragma comment(lib, "kptframeworkv2SMD.lib") 80 | #endif 81 | 82 | #else 83 | 84 | #if defined(_DEBUG) 85 | #pragma comment(lib, "kptframeworkv2SMTd.lib") 86 | #else 87 | #pragma comment(lib, "kptframeworkv2SMT.lib") 88 | #endif 89 | 90 | #endif 91 | 92 | #endif 93 | 94 | #elif defined KPT_LIBAPI_CREATELIB 95 | 96 | /* Creating library as a static library */ 97 | #define KPT_LIB_API 98 | 99 | #else 100 | 101 | /* No specification */ 102 | #define KPT_LIB_API 103 | 104 | #endif 105 | 106 | #endif /* #ifndef H_KPT_LIBAPI_H */ 107 | -------------------------------------------------------------------------------- /include/pal/android/kptfilepath_platform.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfilepath_platform.h 16 | * 17 | * @brief Platform-dependent file path defines. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_FILEPATHPLATFORM_H 27 | #define H_KPT_FILEPATHPLATFORM_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /*__cplusplus */ 32 | 33 | #ifndef MAX_PATH 34 | #define MAX_PATH PATH_MAX 35 | #endif 36 | 37 | #ifndef KPT_DIR_DELIM_STD 38 | #define KPT_DIR_DELIM_STD KPT_TS('/') 39 | #endif 40 | #ifndef KPT_DIR_DELIM_ALT 41 | #define KPT_DIR_DELIM_ALT KPT_TS('\\') 42 | #endif 43 | 44 | 45 | #ifdef __cplusplus 46 | } 47 | #endif /*__cplusplus */ 48 | 49 | #endif /* H_KPT_FILEPATHPLATFORM_H */ 50 | -------------------------------------------------------------------------------- /include/pal/android/kptlibcode.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibcode.h 16 | * 17 | * @brief Include file for the KPT code library 18 | * 19 | * @details This file is contains android specific defines to allow the library to be used. 20 | * 21 | *****************************************************************************/ 22 | #include "kptcompile.h" 23 | 24 | #ifndef H_KPT_LIBCODE_H 25 | #define H_KPT_LIBCODE_H 26 | 27 | #if defined KPT_LIBCODE_SOURCE 28 | 29 | /* Using the code directly */ 30 | #define KPT_LIB_CODE 31 | 32 | #elif defined KPT_LIBCODE_DLL 33 | 34 | /* Using library as a DLL */ 35 | #define KPT_LIB_CODE __declspec(dllimport) 36 | 37 | #elif defined KPT_LIBCODE_CREATEDLL 38 | 39 | /* Creating library as a DLL */ 40 | #define KPT_LIB_CODE __declspec(dllexport) 41 | 42 | #elif defined KPT_LIBCODE_CREATELIB 43 | 44 | /* Creating library as a static library */ 45 | #define KPT_LIB_CODE 46 | 47 | #else 48 | 49 | /* Using library as a static library */ 50 | #define KPT_LIB_CODE 51 | 52 | #endif 53 | 54 | /* Compile categories for the Library */ 55 | #ifndef KPT_LIBCODE_CATEGORY 56 | #ifdef NDEBUG 57 | #define KPT_LIBCODE_CATEGORY \ 58 | KPTCAT_ERROR \ 59 | | KPTCAT_WARNING 60 | #else 61 | #define KPT_LIBCODE_CATEGORY \ 62 | KPTCAT_ERROR \ 63 | | KPTCAT_WARNING \ 64 | | KPTCAT_INFORMATION \ 65 | | KPTCAT_DEBUG \ 66 | | KPTCAT_PERFORMANCE \ 67 | | KPTCAT_ALGORITHM 68 | #endif 69 | #endif 70 | 71 | #endif /* #ifndef H_KPT_LIBCODE_H */ 72 | -------------------------------------------------------------------------------- /include/pal/android/kptlibcollections.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibcollections.h 16 | * 17 | * @brief Platform specific defines and includes for Android. 18 | * 19 | * @brief Include file for KPT Collections library 20 | * 21 | * @details This file is contains android specific defines to allow the library to be used. 22 | * 23 | *****************************************************************************/ 24 | #pragma once 25 | #ifndef H_KPT_LIBCOLLECTIONS_H 26 | #define H_KPT_LIBCOLLECTIONS_H 27 | 28 | #include "kptcompile.h" 29 | 30 | #if defined KPT_LIBCOLLECTIONS_SOURCE 31 | 32 | /* Using the code directly */ 33 | #define KPT_LIB_COLLECTIONS 34 | 35 | #elif defined KPT_LIBCOLLECTIONS_DLL 36 | 37 | /* Using library as a DLL */ 38 | #define KPT_LIB_COLLECTIONS __declspec(dllimport) 39 | 40 | #elif defined KPT_LIBCOLLECTIONS_CREATEDLL 41 | 42 | /* Creating library as a DLL */ 43 | #define KPT_LIB_COLLECTIONS __declspec(dllexport) 44 | 45 | #elif defined KPT_LIBCOLLECTIONS_CREATELIB 46 | 47 | /* Creating library as a static library */ 48 | #define KPT_LIB_COLLECTIONS 49 | 50 | #else 51 | 52 | /* Using library as a static library */ 53 | #define KPT_LIB_COLLECTIONS 54 | 55 | #endif 56 | 57 | #endif /* #ifndef H_KPT_LIBCOLLECTIONS_H */ 58 | -------------------------------------------------------------------------------- /include/pal/android/kptlibsysmem.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibsysmem.h 16 | * 17 | * @brief Include file for the KPT system memory library 18 | * 19 | * @details This file is contains android specific defines to allow the library to be used. 20 | * 21 | *****************************************************************************/ 22 | 23 | #include "kptcompile.h" 24 | 25 | #ifndef H_KPT_LIBSYSMEM_H 26 | #define H_KPT_LIBSYSMEM_H 27 | 28 | #if defined KPT_LIBSYSMEM_SOURCE 29 | 30 | /* Using the code directly */ 31 | #define KPT_LIB_SYSMEM 32 | 33 | #elif defined KPT_LIBSYSMEM_DLL 34 | 35 | /* Using library as a DLL */ 36 | #define KPT_LIB_SYSMEM __declspec(dllimport) 37 | 38 | #elif defined KPT_LIBSYSMEM_CREATEDLL 39 | 40 | /* Creating library as a DLL */ 41 | #define KPT_LIB_SYSMEM __declspec(dllexport) 42 | 43 | #elif defined KPT_LIBSYSMEM_CREATELIB 44 | 45 | /* Creating library as a static library */ 46 | #define KPT_LIB_SYSMEM 47 | 48 | #else 49 | 50 | /* Using library as a static library */ 51 | #define KPT_LIB_SYSMEM 52 | 53 | #endif 54 | 55 | /* Compile categories for the Library */ 56 | #ifndef KPT_LIBSYSMEM_CATEGORY 57 | #ifdef NDEBUG 58 | #define KPT_LIBSYSMEM_CATEGORY \ 59 | KPTCAT_ERROR \ 60 | | KPTCAT_WARNING 61 | #else 62 | #define KPT_LIBSYSMEM_CATEGORY \ 63 | KPTCAT_ERROR \ 64 | | KPTCAT_WARNING \ 65 | | KPTCAT_INFORMATION \ 66 | | KPTCAT_DEBUG \ 67 | | KPTCAT_PERFORMANCE \ 68 | | KPTCAT_ALGORITHM 69 | #endif 70 | #endif 71 | 72 | #endif /* #ifndef H_KPT_LIBSYSMEM_H */ 73 | -------------------------------------------------------------------------------- /include/pal/android/kptlibsystem.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibsystem.h 16 | * 17 | * @brief Include file for KPT System library 18 | * 19 | * @details This file is contains android specific defines to allow the library to be used. 20 | * 21 | *****************************************************************************/ 22 | 23 | #include "kptcompile.h" 24 | 25 | #ifndef H_KPT_LIBSYSTEM_H 26 | #define H_KPT_LIBSYSTEM_H 27 | 28 | #if defined KPT_LIBSYSTEM_SOURCE 29 | 30 | /* Using the code directly */ 31 | #define KPT_LIB_SYSTEM 32 | 33 | #elif defined KPT_LIBSYSTEM_DLL 34 | 35 | /* Using library as a DLL */ 36 | #define KPT_LIB_SYSTEM __declspec(dllimport) 37 | 38 | #elif defined KPT_LIBSYSTEM_CREATEDLL 39 | 40 | /* Creating library as a DLL */ 41 | #define KPT_LIB_SYSTEM __declspec(dllexport) 42 | 43 | #elif defined KPT_LIBSYSTEM_CREATELIB 44 | 45 | /* Creating library as a static library */ 46 | #define KPT_LIB_SYSTEM 47 | 48 | #else 49 | 50 | /* Using library as a static library */ 51 | #define KPT_LIB_SYSTEM 52 | 53 | 54 | #endif 55 | 56 | /* Byte order for the Library */ 57 | #ifndef KPT_BYTE_ORDER 58 | #define KPT_BYTE_ORDER KPT_ENDIAN_LITTLE 59 | #endif 60 | 61 | #define KPTBINARYFILE_USE_STD 62 | 63 | /* Compile categories for the Library */ 64 | #ifndef KPT_LIBSYSTEM_CATEGORY 65 | #ifdef NDEBUG 66 | #define KPT_LIBSYSTEM_CATEGORY \ 67 | KPTCAT_ERROR \ 68 | | KPTCAT_WARNING 69 | #else 70 | #define KPT_LIBSYSTEM_CATEGORY \ 71 | KPTCAT_ERROR \ 72 | | KPTCAT_WARNING \ 73 | | KPTCAT_INFORMATION \ 74 | | KPTCAT_DEBUG \ 75 | | KPTCAT_PERFORMANCE \ 76 | | KPTCAT_ALGORITHM 77 | /* | KPTCAT_DISALLOWSTATIC */ 78 | #endif 79 | #endif 80 | 81 | #endif /* #ifndef H_KPT_LIBSYSTEM_H */ 82 | -------------------------------------------------------------------------------- /include/pal/android/kptlibtest.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttestlib.h 16 | * 17 | * @brief Include file for KPT Test library 18 | * 19 | * @details This file is contains android specific defines to allow the library to be used. 20 | * 21 | *****************************************************************************/ 22 | #pragma once 23 | #ifndef H_KPT_LIBTEST_H 24 | #define H_KPT_LIBTEST_H 25 | 26 | #include "kptcompile.h" 27 | 28 | #if defined KPT_LIBTEST_DLL 29 | 30 | /* Using library as a DLL */ 31 | #define KPT_LIB_TEST __declspec(dllimport) 32 | 33 | #elif defined KPT_LIBTEST_CREATEDLL 34 | 35 | /* Creating library as a DLL */ 36 | #define KPT_LIB_TEST __declspec(dllexport) 37 | 38 | #elif defined KPT_LIBTEST_CREATELIB 39 | 40 | /* Creating library as a static library */ 41 | #define KPT_LIB_TEST 42 | 43 | #else 44 | 45 | /* Using library as a static library */ 46 | #define KPT_LIB_TEST 47 | 48 | #endif 49 | 50 | #endif /* #ifndef H_KPT_LIBTEST_H */ 51 | -------------------------------------------------------------------------------- /include/pal/android/kptlibunicode.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptlibunicode.h 16 | * 17 | * @brief Platform specific defines and includes for Android. 18 | * 19 | * @brief Include file for KPT unicode library 20 | * 21 | * @details This file is contains windows specific pragmas that will link to 22 | * the correct unicode library. 23 | * 24 | *****************************************************************************/ 25 | 26 | #include "kptcompile.h" 27 | #ifndef H_KPT_LIBUNICODE_H 28 | #define H_KPT_LIBUNICODE_H 29 | 30 | #if defined KPT_LIBUNICODE_SOURCE 31 | 32 | /* Using the code directly */ 33 | #define KPT_LIB_UNICODE 34 | 35 | #elif defined KPT_LIBUNICODE_DLL 36 | 37 | /* Using library as a DLL */ 38 | #define KPT_LIB_UNICODE __declspec(dllimport) 39 | 40 | 41 | #elif defined KPT_LIBUNICODE_CREATEDLL 42 | 43 | /* Creating library as a DLL */ 44 | #define KPT_LIB_UNICODE __declspec(dllexport) 45 | 46 | #elif defined KPT_LIBUNICODE_CREATELIB 47 | 48 | /* Creating library as a static library */ 49 | #define KPT_LIB_UNICODE 50 | 51 | #else 52 | 53 | /* Using library as a static library */ 54 | #define KPT_LIB_UNICODE 55 | 56 | #endif 57 | 58 | /* Compile categories for the Library */ 59 | #ifndef KPT_LIBUNICODE_CATEGORY 60 | #ifdef NDEBUG 61 | #define KPT_LIBUNICODE_CATEGORY \ 62 | KPTCAT_ERROR \ 63 | | KPTCAT_WARNING 64 | #else 65 | #define KPT_LIBUNICODE_CATEGORY \ 66 | KPTCAT_ERROR \ 67 | | KPTCAT_WARNING \ 68 | | KPTCAT_INFORMATION \ 69 | | KPTCAT_DEBUG \ 70 | | KPTCAT_PERFORMANCE 71 | /* | KPTCAT_DISALLOWSTATIC */ 72 | #endif 73 | #endif 74 | 75 | #endif /* #ifndef H_KPT_LIBUNICODE_H */ 76 | -------------------------------------------------------------------------------- /include/pal/kptalloct.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptalloct.h 16 | * 17 | * @brief Allocation block header. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTALLOC_H 27 | #define H_KPTALLOC_H 28 | 29 | #include "kptlibutil.h" 30 | #include "kptapi.h" 31 | #include "kptheap.h" 32 | 33 | /** Allocation header type */ 34 | typedef struct KPTAllocT KPTAllocT; 35 | 36 | /** 37 | * Signature for element destructor. 38 | * 39 | * @param[in] aProgress An allocation header. 40 | * @return KPTResultT. 41 | */ 42 | typedef KPTResultT (KPT_CALLB *KPTAllocElementDestructorT)(KPTAllocT* aAlloc); 43 | 44 | /** Allocation header structure */ 45 | struct KPTAllocT 46 | { 47 | size_t allocSize; /**< Total number of bytes allocated */ 48 | size_t dataSize; /**< Number of bytes in use */ 49 | size_t elementCount; /**< Number of elements */ 50 | size_t callerStructSize; /**< Size of the structure that wraps the header */ 51 | KPTHeapT* heap; /**< The heap that stores the data */ 52 | KPTAllocElementDestructorT elementDestructor; /**< Cleanup for elements */ 53 | intptr_t data[1]; /**< Start of allocation data; start = &(alloc->data) */ 54 | }; 55 | 56 | /** 57 | * Format for all AllocT wrappers. 58 | * Each wrapper must be large enough to hold a data pointer 59 | * as the first element. The element must be zero-initialised. 60 | * 61 | */ 62 | typedef struct KPTAllocWrapperT KPTAllocWrapperT; 63 | struct KPTAllocWrapperT 64 | { 65 | void *data; 66 | }; 67 | 68 | KPT_LIB_UTIL 69 | KPTResultT 70 | KPT_CALL 71 | KPTAllocRelease(KPTAllocWrapperT* aAlloc); 72 | 73 | KPT_LIB_UTIL 74 | KPTAllocT* 75 | KPT_CALL 76 | KPTAllocAcquire(KPTAllocWrapperT* aAllocWrapper, 77 | size_t aAllocWrapperSize, 78 | size_t aDataBytes, 79 | size_t aElementCount, 80 | KPTAllocElementDestructorT aElementDestructor, 81 | KPTHeapT* aHeap); 82 | 83 | #endif /* #ifndef H_KPTALLOC_H */ 84 | -------------------------------------------------------------------------------- /include/pal/kptapi.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptapi.h 16 | * 17 | * @brief Public types for the KPT libraries. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTAPI_H 27 | #define H_KPTAPI_H 28 | 29 | #include "kptcall.h" 30 | #include "kptint.h" 31 | #include "kptbool.h" 32 | #include "kptbyte.h" 33 | #include "kptchar.h" 34 | #include "kptresult.h" 35 | #include "kpthandle.h" 36 | #include "kptstatus.h" 37 | 38 | #endif /* #ifndef H_KPTAPI_H */ 39 | -------------------------------------------------------------------------------- /include/pal/kptassert.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptassert.h 16 | * 17 | * @brief Assert functions. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTASSERT_H 27 | #define H_KPTASSERT_H 28 | 29 | #include "kpterr.h" 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /** 36 | * \def KPTASSERT_STATIC(aCondition) 37 | * Compile time assertions on static code. These can be used for portability checks 38 | * but they will not appear in the runtime code. 39 | */ 40 | 41 | /** 42 | * \def KPTASSERT_DYNAMIC(aCondition) 43 | * Runtime assertion. 44 | */ 45 | #ifdef NDEBUG 46 | 47 | #define KPTASSERT_DYNAMIC(x) KPT_NOP_FUNCTION 48 | 49 | #else 50 | 51 | #define KPTASSERT_DYNAMIC(aCondition) \ 52 | if (!(aCondition)) KPTERR_PUSHTEXT1(KPTRESULT_ERROR(0, KPT_SC_ASSERT), KPT_TS(#aCondition)) 53 | 54 | #endif 55 | 56 | #define KPTASSERT_JOIN_P(x, y) x ## y 57 | #define KPTASSERT_JOIN(x, y) KPTASSERT_JOIN_P(x, y) 58 | #define KPTASSERT_STATIC(aCondition) \ 59 | typedef int KPTASSERT_JOIN(KPTASSERT_STATIC_, __LINE__) [(aCondition) ? 1 : -1] 60 | 61 | #ifdef __cplusplus 62 | } 63 | #endif /*__cplusplus */ 64 | 65 | #endif /* #ifndef H_KPTASSERT_H */ 66 | -------------------------------------------------------------------------------- /include/pal/kptbool.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptbool.h 16 | * 17 | * @brief Boolean type for interfaces. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTBOOL_H 27 | #define H_KPTBOOL_H 28 | 29 | /** Boolean type */ 30 | enum KPTBoolT 31 | { 32 | eKPTFalse = 0, /**< false */ 33 | eKPTTrue = 1 /**< true */ 34 | }; 35 | typedef enum KPTBoolT KPTBoolT; 36 | 37 | #endif /* #ifndef H_KPTBOOL_H */ 38 | -------------------------------------------------------------------------------- /include/pal/kptcheck.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcheck.h 16 | * 17 | * @brief Checksum algorithms. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_CHECK_H 27 | #define H_CHECK_H 28 | 29 | #include "kptlibcode.h" 30 | #include "kptapi.h" 31 | #include "kptfletcher16.h" 32 | #include "kptcrc32ieee.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif /* __cplusplus */ 37 | 38 | KPT_LIB_CODE 39 | uint32_t 40 | KPT_CALL 41 | KPTCheckInvertedSumUpdate(uint32_t aTotal, 42 | const uint8_t* aData, 43 | size_t aSize); 44 | 45 | KPT_LIB_CODE 46 | uint8_t 47 | KPT_CALL 48 | KPTCheckInvertedSumEnd(uint32_t aTotal); 49 | 50 | #ifdef __cplusplus 51 | } 52 | #endif /*__cplusplus */ 53 | 54 | #endif /* #ifndef H_CHECK_H */ 55 | -------------------------------------------------------------------------------- /include/pal/kptcodelibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcodelibversion.h 16 | * 17 | * @brief Code library version information. 18 | * 19 | * @details Code library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTCODELIBVERSION_H 27 | #define H_KPTCODELIBVERSION_H 28 | 29 | #include "kptlibcode.h" 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_CODE 37 | KPTResultT 38 | KPT_CALL 39 | KPTCodeLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTCODELIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kptcollectionslibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcollectionslibversion.h 16 | * 17 | * @brief Collections library version information. 18 | * 19 | * @details Collections library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTCOLLECTLIBVERSION_H 27 | #define H_KPTCOLLECTLIBVERSION_H 28 | 29 | #include "kptlibcollections.h" 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_COLLECTIONS 37 | KPTResultT 38 | KPT_CALL 39 | KPTCollectionsLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTCOLLECTLIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kptcrc32.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcrc32.h 16 | * 17 | * @brief Interface file for the CRC32 algorithm. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTCRC32_H 27 | #define H_KPTCRC32_H 28 | 29 | #include "kptlibcode.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /* __cplusplus */ 35 | 36 | #define KPTCRC32_IEEE8023 0xEDB88320UL /**< CRC-32-IEEE 802.3 Polynomial */ 37 | #define KPTCRC32_CASTAGNOLI 0x82F63B78UL /**< Castagnoli Polynomial */ 38 | #define KPTCRC32_KOOPMAN 0xEB31D82EUL /**< Koopman Polynomial */ 39 | 40 | typedef struct KPTCrc32T KPTCrc32T; 41 | /** Management structure for calculating a CRC32. */ 42 | struct KPTCrc32T 43 | { 44 | uint32_t crc; /**< The running crc value used in Update functions */ 45 | const uint32_t* crcTable; /**< 256 entry CRC table filled by KPTCrc32FillTable. */ 46 | }; 47 | 48 | KPT_LIB_CODE 49 | void 50 | KPT_CALL 51 | KPTCrc32FillTable(uint32_t* aTable, uint32_t aPolynomial); 52 | 53 | KPT_LIB_CODE 54 | KPTResultT 55 | KPT_CALL 56 | KPTCrc32Begin(KPTCrc32T* aCheck, const uint32_t* aCRCTable); 57 | 58 | KPT_LIB_CODE 59 | void 60 | KPT_CALL 61 | KPTCrc32Update(KPTCrc32T* aCheck, const uint8_t* aData, size_t aSize); 62 | 63 | KPT_LIB_CODE 64 | uint32_t 65 | KPT_CALL 66 | KPTCrc32End(KPTCrc32T* aCheck); 67 | 68 | KPT_LIB_CODE 69 | uint32_t 70 | KPT_CALL 71 | KPTCrc32Compute(const uint8_t* aData, size_t aSize, const uint32_t* aCRCTable); 72 | 73 | #ifdef __cplusplus 74 | } 75 | #endif /*__cplusplus */ 76 | 77 | #endif /* #ifndef H_KPTCRC32_H */ 78 | -------------------------------------------------------------------------------- /include/pal/kptcrc32ieee.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcrc32ieee.h 16 | * 17 | * @brief Interface file for the CRC32 (IEEE) algorithm. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTCRC32IEEE_H 27 | #define H_KPTCRC32IEEE_H 28 | 29 | #include "kptlibcode.h" 30 | #include "kptapi.h" 31 | #include "kptcrc32.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | KPT_LIB_CODE 38 | KPTResultT 39 | KPT_CALL 40 | KPTCrc32IeeeBegin(KPTCrc32T* aCheck); 41 | 42 | KPT_LIB_CODE 43 | uint32_t 44 | KPT_CALL 45 | KPTCrc32IeeeCompute(const uint8_t* aData, 46 | size_t aSize); 47 | 48 | #ifdef __cplusplus 49 | } 50 | #endif /*__cplusplus */ 51 | 52 | #endif /* #ifndef H_KPTCRC32IEEE_H */ 53 | -------------------------------------------------------------------------------- /include/pal/kptcritsection.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptcritsection.h 16 | * 17 | * @brief Support for a platform idependent critical section. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTCRITSECTION_H 27 | #define H_KPTCRITSECTION_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | #include "kptheap.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | DECLARE_KPTHANDLE(KPTCriticalSectionT) 38 | 39 | KPT_LIB_SYSTEM 40 | KPTResultT 41 | KPT_CALL 42 | KPTCriticalSectionCreate(KPTCriticalSectionT** aHandle, 43 | KPTHeapT* aHeap); 44 | 45 | KPT_LIB_SYSTEM 46 | KPTResultT 47 | KPT_CALL 48 | KPTCriticalSectionDestroy(KPTCriticalSectionT** aHandle); 49 | 50 | KPT_LIB_SYSTEM 51 | KPTResultT 52 | KPT_CALL 53 | KPTCriticalSectionLock(KPTCriticalSectionT* aHandle); 54 | 55 | KPT_LIB_SYSTEM 56 | KPTResultT 57 | KPT_CALL 58 | KPTCriticalSectionTryLock(KPTCriticalSectionT* aHandle); 59 | 60 | KPT_LIB_SYSTEM 61 | KPTResultT 62 | KPT_CALL 63 | KPTCriticalSectionUnlock(KPTCriticalSectionT* aHandle); 64 | 65 | #ifdef __cplusplus 66 | } 67 | #endif /*__cplusplus */ 68 | 69 | #endif /* #ifndef H_KPTCRITSECTION_H */ 70 | -------------------------------------------------------------------------------- /include/pal/kptdirmanager.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptdirmanager.h 16 | * 17 | * @brief Directory manager. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_DIRMANAGER_H 27 | #define H_KPT_DIRMANAGER_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /*__cplusplus */ 35 | 36 | KPT_LIB_SYSTEM 37 | KPTResultT 38 | KPT_CALL 39 | KPTDirManagerDirExists(const KPTSysCharT* aPath, 40 | KPTBoolT* aDirExists); 41 | 42 | KPT_LIB_SYSTEM 43 | KPTResultT 44 | KPT_CALL 45 | KPTDirManagerCreateDir(const KPTSysCharT* aDirPath); 46 | 47 | KPT_LIB_SYSTEM 48 | KPTResultT 49 | KPT_CALL 50 | KPTDirManagerCreateDirPath(const KPTSysCharT* aDirPath); 51 | 52 | KPT_LIB_SYSTEM 53 | KPTResultT 54 | KPT_CALL 55 | KPTDirManagerDeleteDir(const KPTSysCharT* aDirPath); 56 | 57 | KPT_LIB_SYSTEM 58 | KPTResultT 59 | KPT_CALL 60 | KPTDirManagerDeleteTree(const KPTSysCharT* aPath); 61 | 62 | KPT_LIB_SYSTEM 63 | KPTResultT 64 | KPT_CALL 65 | KPTDirManagerMoveDir(const KPTSysCharT* aExistingDirName, 66 | const KPTSysCharT* aNewDirName, 67 | KPTBoolT aReplaceExisting); 68 | 69 | KPT_LIB_SYSTEM 70 | KPTResultT 71 | KPT_CALL 72 | KPTDirManagerRenameDir(const KPTSysCharT* aExistingDirName, 73 | const KPTSysCharT* aNewDirName, 74 | KPTBoolT aReplaceExisting); 75 | 76 | KPT_LIB_SYSTEM 77 | KPTResultT 78 | KPT_CALL 79 | KPTDirManagerCopyDir(const KPTSysCharT* aExistingDirName, 80 | const KPTSysCharT* aNewDirName, 81 | KPTBoolT aReplaceExisting); 82 | 83 | #ifdef __cplusplus 84 | } 85 | #endif /*__cplusplus */ 86 | 87 | #endif /* H_KPT_DIRMANAGER_H */ 88 | -------------------------------------------------------------------------------- /include/pal/kptdllloader.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptdllloader.h 16 | * 17 | * @brief DLL Loader. 18 | * 19 | * @details Loading DLL libraries dynamically. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTDLLLOADER_H 27 | #define H_KPTDLLLOADER_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /* __cplusplus*/ 35 | 36 | 37 | DECLARE_KPTHANDLE(KPTDllHandleT) 38 | 39 | typedef void (*KPTDllFunctionPointerT)(void); 40 | 41 | 42 | KPT_LIB_SYSTEM 43 | KPTResultT 44 | KPT_CALL 45 | KPTDllLoadLibrary(KPTDllHandleT** aModule, 46 | KPTHeapT* aHeap, 47 | const KPTSysCharT* aLibraryName); 48 | 49 | KPT_LIB_SYSTEM 50 | KPTResultT 51 | KPT_CALL 52 | KPTDllFreeLibrary(KPTDllHandleT** aModule); 53 | 54 | KPT_LIB_SYSTEM 55 | KPTBoolT 56 | KPT_CALL 57 | KPTDllLookupByOrdSupported(void); 58 | 59 | KPT_LIB_SYSTEM 60 | KPTBoolT 61 | KPT_CALL 62 | KPTDllLookupByNameSupported(void); 63 | 64 | KPT_LIB_SYSTEM 65 | KPTResultT 66 | KPT_CALL 67 | KPTDllLookupByOrd(const KPTDllHandleT* aModule, 68 | int aOrdinal, 69 | KPTDllFunctionPointerT* aFunction); 70 | 71 | KPT_LIB_SYSTEM 72 | KPTResultT 73 | KPT_CALL 74 | KPTDllLookupByName(const KPTDllHandleT* aModule, 75 | const KPTSysCharT* aFnName, 76 | KPTDllFunctionPointerT* aFunction); 77 | 78 | 79 | #ifdef __cplusplus 80 | } 81 | #endif /*__cplusplus*/ 82 | 83 | #endif /* #ifndef H_KPTDLLLOADER_H*/ 84 | -------------------------------------------------------------------------------- /include/pal/kptfilemanager.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfilemanager.h 16 | * 17 | * @brief File manager. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_FILEMANAGER_H 27 | #define H_KPT_FILEMANAGER_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /*__cplusplus */ 35 | 36 | #define FILE_OPERATION_ATTEMPTS 10 37 | #define FILE_OPERATION_INTERVAL 50 38 | 39 | /** 40 | * Attribute options for the file. 41 | */ 42 | enum KPTFileAttributesT 43 | { 44 | eKPTFileNormal = KPTBIT(0), /**< Set Normal attribute to file */ 45 | eKPTFileHidden = KPTBIT(1), /**< Set Hidden attribute to file */ 46 | eKPTFileReadOnly = KPTBIT(2) /**< Set Read only attribute to file */ 47 | }; 48 | typedef enum KPTFileAttributesT KPTFileAttributesT; 49 | 50 | KPT_LIB_SYSTEM 51 | KPTResultT 52 | KPT_CALL 53 | KPTFileManagerFileExists(const KPTSysCharT* aFileName, 54 | KPTBoolT* aFileExists); 55 | 56 | KPT_LIB_SYSTEM 57 | KPTResultT 58 | KPT_CALL 59 | KPTFileManagerDeleteFile(const KPTSysCharT* aFileToDelete, 60 | KPTBoolT aForceRemove); 61 | 62 | KPT_LIB_SYSTEM 63 | KPTResultT 64 | KPT_CALL 65 | KPTFileManagerRenameFile(const KPTSysCharT* aExistingFileName, 66 | const KPTSysCharT* aNewFileName, 67 | KPTBoolT aReplaceExisting); 68 | 69 | KPT_LIB_SYSTEM 70 | KPTResultT 71 | KPT_CALL 72 | KPTFileManagerMoveFile(const KPTSysCharT* aExistingFileName, 73 | const KPTSysCharT* aNewFileName, 74 | KPTBoolT aReplaceExisting); 75 | 76 | KPT_LIB_SYSTEM 77 | KPTResultT 78 | KPT_CALL 79 | KPTFileManagerCopyFile(const KPTSysCharT* aExistingFileName, 80 | const KPTSysCharT* aNewFileName, 81 | KPTBoolT aReplaceExisting); 82 | 83 | KPT_LIB_SYSTEM 84 | KPTResultT 85 | KPT_CALL 86 | KPTFileManagerSetAttributes(const KPTSysCharT* aFileName, 87 | uint32_t aOptions); 88 | 89 | #ifdef __cplusplus 90 | } 91 | #endif /*__cplusplus */ 92 | 93 | #endif /* H_KPT_FILEMANAGER_H */ 94 | -------------------------------------------------------------------------------- /include/pal/kptfletcher16.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfletcher16.h 16 | * 17 | * @brief Interface file for the Fletcher-16 algorithm. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTFLETCHER16_H 27 | #define H_KPTFLETCHER16_H 28 | 29 | #include "kptlibcode.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /* __cplusplus */ 35 | 36 | typedef struct KPTFletcher16T KPTFletcher16T; 37 | /** Management structure for Fletcher 16 checksum. */ 38 | struct KPTFletcher16T 39 | { 40 | uint16_t sum1; /**< Accumulator 1 */ 41 | uint32_t sum2; /**< Accumulator 2 */ 42 | }; 43 | 44 | 45 | KPT_LIB_CODE 46 | KPTResultT 47 | KPT_CALL 48 | KPTFletcher16Begin(KPTFletcher16T* aCheck); 49 | 50 | KPT_LIB_CODE 51 | void 52 | KPT_CALL 53 | KPTFletcher16Update(KPTFletcher16T* aCheck, 54 | const uint8_t* aData, 55 | size_t aSize); 56 | 57 | KPT_LIB_CODE 58 | uint16_t 59 | KPT_CALL 60 | KPTFletcher16End(KPTFletcher16T* aCheck); 61 | 62 | KPT_LIB_CODE 63 | uint16_t 64 | KPT_CALL 65 | KPTFletcher16Compute(const uint8_t* aData, 66 | size_t aSize); 67 | 68 | #ifdef __cplusplus 69 | } 70 | #endif /*__cplusplus */ 71 | 72 | #endif /* #ifndef H_KPTFLETCHER16_H */ 73 | 74 | -------------------------------------------------------------------------------- /include/pal/kptformat.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptformat.h 16 | * 17 | * @brief Printf-style formatting functions. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTFORMAT_H 27 | #define H_KPTFORMAT_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | #include "kptfmtspec.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | 38 | KPT_LIB_SYSTEM 39 | size_t 40 | KPT_CALL 41 | KPTFormatVN(char* aOut, 42 | size_t aBufferSize, 43 | const char* aFormatString, 44 | va_list aArgptr); 45 | 46 | KPT_LIB_SYSTEM 47 | size_t 48 | KPT_CALLV 49 | KPTFormatN(char* out, 50 | size_t aBufferSize, 51 | const char* aFormatString, 52 | ...); 53 | 54 | KPT_LIB_SYSTEM 55 | size_t 56 | KPT_CALL 57 | KPTFormatVW(wchar_t* aOut, 58 | size_t aBufferSize, 59 | const wchar_t* aFormatString, 60 | va_list aArgptr); 61 | 62 | KPT_LIB_SYSTEM 63 | size_t 64 | KPT_CALLV 65 | KPTFormatW(wchar_t* out, 66 | size_t aBufferSize, 67 | const wchar_t* aFormatString, 68 | ...); 69 | 70 | 71 | /** 72 | * \def KPTFormatVS 73 | * vprintf-style format function for KPTSysCharT. 74 | */ 75 | 76 | /** 77 | * \def KPTFormatS 78 | * printf-style format function for KPTSysCharT. 79 | */ 80 | 81 | #if KPT_TSYSCHAR_ISWIDE 82 | 83 | #define KPTFormatVS KPTFormatVW 84 | #define KPTFormatS KPTFormatW 85 | 86 | #else 87 | 88 | #define KPTFormatVS KPTFormatVN 89 | #define KPTFormatS KPTFormatN 90 | 91 | #endif 92 | 93 | 94 | #ifdef __cplusplus 95 | } 96 | #endif /*__cplusplus */ 97 | 98 | #endif /* H_KPTFORMAT_H */ 99 | -------------------------------------------------------------------------------- /include/pal/kpthandle.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpthandle.h 16 | * 17 | * @brief Support for interface definitions 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTHANDLE_H 27 | #define H_KPTHANDLE_H 28 | 29 | /** Macro for declaring opaque pointers with a private implementation of "name" */ 30 | #define DECLARE_KPTHANDLE(name) \ 31 | typedef struct name name; \ 32 | struct name; 33 | 34 | #endif /* #ifndef H_KPTHANDLE_H */ 35 | -------------------------------------------------------------------------------- /include/pal/kptid.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptid.h 16 | * 17 | * @brief Identifiers for all PAL interfaces. 18 | * 19 | * @details This file contains a list of all the KPT_CC_ definitions. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTID_H 27 | #define H_KPTID_H 28 | 29 | #define KPT_CC_HEAP 0x0001 30 | #define KPT_CC_PAL 0x0002 31 | #define KPT_CC_TIMER 0x0003 32 | #define KPT_CC_TESTHEAP 0x0004 33 | #define KPT_CC_ERRORSTACK 0x0005 34 | #define KPT_CC_TIME 0x0006 35 | #define KPT_CC_OUT 0x0007 36 | #define KPT_CC_FILEMANAGER 0x0008 37 | #define KPT_CC_LIST 0x0009 38 | #define KPT_CC_VECTOR 0x000A 39 | #define KPT_CC_SYSSTRINGCONTAINER 0x000B 40 | #define KPT_CC_CRITICALSECTION 0x000C 41 | #define KPT_CC_FILEHDR 0x000D 42 | #define KPT_CC_FILEPATH 0x000E 43 | #define KPT_CC_MEMORY 0x000F 44 | #define KPT_CC_FL16 0x0010 45 | #define KPT_CC_CRC 0x0011 46 | #define KPT_CC_TREE 0x0012 47 | #define KPT_CC_MAP 0x0013 48 | #define KPT_CC_UNICODEBINARYDATA 0x0014 49 | #define KPT_CC_UNICODE 0x0015 50 | #define KPT_CC_STRINGS 0x0016 51 | #define KPT_CC_UNISTRINGCONTAINER 0x0017 52 | #define KPT_CC_TEXTFILE 0x0018 53 | #define KPT_CC_BINARYFILE 0x0019 54 | #define KPT_CC_MEMORYFILE 0x001A 55 | #define KPT_CC_BINARYSTREAM 0x001B 56 | #define KPT_CC_BINARYSTORE 0x001C 57 | #define KPT_CC_MEMORYSHARE 0x001D 58 | #define KPT_CC_UNISTRING 0x001E 59 | #define KPT_CC_SYSSTRING 0x001F 60 | #define KPT_CC_STORAGE 0x0020 61 | #define KPT_CC_DIRMANAGER 0x0021 62 | #define KPT_CC_DIRSCAN 0x0022 63 | #define KPT_CC_DLLLOADER 0x0023 64 | #define KPT_CC_THREAD 0x0024 65 | #define KPT_CC_UTIL 0x0025 66 | 67 | /** Macro to get the component id associated with an interface */ 68 | #define KPT_CC(name) KPT_CC_##name 69 | 70 | #endif /* #ifndef H_KPTID_H */ 71 | -------------------------------------------------------------------------------- /include/pal/kptmemoryshare.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptmemoryshare.h 16 | * 17 | * @brief Platform structures to store information about shared memory. 18 | * 19 | * @details 20 | *****************************************************************************/ 21 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 22 | #pragma once 23 | #endif 24 | 25 | #ifndef H_KPTMEMORYSHARE_H 26 | #define H_KPTMEMORYSHARE_H 27 | 28 | #include "kptlibsysmem.h" 29 | 30 | #ifdef __cplusplus 31 | extern "C" { 32 | #endif /* __cplusplus */ 33 | 34 | DECLARE_KPTHANDLE(KPTMemoryShareT) 35 | 36 | /** 37 | * Creates & initialises a shared memory structure. 38 | */ 39 | KPT_LIB_SYSMEM 40 | KPTResultT 41 | KPT_CALL 42 | KPTMemoryShareCreate(KPTMemoryShareT** aHandle, 43 | KPTHeapT* aHeap, 44 | const KPTSysCharT* aName, 45 | size_t* aSize, 46 | KPTBoolT aWrite, 47 | KPTBoolT aNoCreate); 48 | 49 | /** 50 | * Closes & destroys the shared memory structure. 51 | */ 52 | KPT_LIB_SYSMEM 53 | KPTResultT 54 | KPT_CALL 55 | KPTMemoryShareDestroy(KPTMemoryShareT** aHandle, 56 | KPTHeapT* aHeap); 57 | 58 | /** 59 | * Gets access to the shared buffer. 60 | */ 61 | KPT_LIB_SYSMEM 62 | uint8_t* 63 | KPT_CALL 64 | KPTMemoryShareGetBuffer(KPTMemoryShareT* aHandle); 65 | 66 | #ifdef __cplusplus 67 | } 68 | #endif /*__cplusplus */ 69 | 70 | #endif /* #ifndef H_KPTMEMORYSHARE_H */ 71 | -------------------------------------------------------------------------------- /include/pal/kptrad32.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptrad32.h 16 | * 17 | * @brief Interface file for the rad32 algorithm. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTRAD32_H 27 | #define H_KPTRAD32_H 28 | 29 | #include "kptlibcode.h" 30 | #include "kptapi.h" 31 | 32 | #ifdef __cplusplus 33 | extern "C" { 34 | #endif /* __cplusplus */ 35 | 36 | #define KPTRAD32_GETVALERROR -1 37 | #define KPTRAD32_GETCHARERROR 255 38 | 39 | KPT_LIB_CODE 40 | KPTResultT 41 | KPT_CALL 42 | KPTRad32Convert16To(const uint16_t* aDataBuffer, 43 | size_t aDataBufferSize, 44 | char* aRadBuffer, 45 | size_t aRadBufferSize); 46 | 47 | KPT_LIB_CODE 48 | KPTResultT 49 | KPT_CALL 50 | KPTRad32Convert16From(const char* aRadBuffer, 51 | size_t aRadBufferSize, 52 | uint16_t* aDataBuffer, 53 | size_t aDataBufferSize); 54 | 55 | KPT_LIB_CODE 56 | char 57 | KPT_CALL 58 | KPTRad32GetChar(int aValue); 59 | 60 | KPT_LIB_CODE 61 | int 62 | KPT_CALL 63 | KPTRad32GetValue(char aChar); 64 | 65 | #ifdef __cplusplus 66 | } 67 | #endif /*__cplusplus */ 68 | 69 | #endif /* #ifndef H_KPTRAD32_H */ 70 | -------------------------------------------------------------------------------- /include/pal/kptstorage.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptstorage.h 16 | * 17 | * @brief Interface declaration for storage. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTSTORAGE_H 27 | #define H_KPTSTORAGE_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | #include "kptfilepath.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | KPT_LIB_SYSTEM 38 | KPTResultT 39 | KPT_CALL 40 | KPTStorageGetFreeSpaceFromString(const KPTSysCharT* aPath, 41 | uint64_t* aFreeSpace); 42 | 43 | KPT_LIB_SYSTEM 44 | KPTResultT 45 | KPT_CALL 46 | KPTStorageGetFreeSpaceFromPath(const KPTFilePathT* aFilePath, 47 | uint64_t* aFreeSpace); 48 | 49 | #ifdef __cplusplus 50 | } 51 | #endif /*__cplusplus */ 52 | 53 | #endif /* H_KPTSTORAGE_H */ 54 | -------------------------------------------------------------------------------- /include/pal/kptsysmemlibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptsysmemlibversion.h 16 | * 17 | * @brief Sysmem library version information. 18 | * 19 | * @details Sysmem library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptlibsysmem.h" 27 | 28 | #ifndef H_KPTSYSMEMLIBVERSION_H 29 | #define H_KPTSYSMEMLIBVERSION_H 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_SYSMEM 37 | KPTResultT 38 | KPT_CALL 39 | KPTSysMemLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTSYSMEMLIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kptsystemlibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptsysmemlibversion.h 16 | * 17 | * @brief System library version information. 18 | * 19 | * @details System library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptlibsystem.h" 27 | 28 | #ifndef H_KPTSYSTEMLIBVERSION_H 29 | #define H_KPTSYSTEMLIBVERSION_H 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_SYSMEM 37 | KPTResultT 38 | KPT_CALL 39 | KPTSystemLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTSYSTEMLIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kpttest.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttest.h 16 | * 17 | * @brief KPTTest interface. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTTEST_H 27 | #define H_KPTTEST_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif 32 | 33 | #include "kptlibtest.h" 34 | #include "cmockery.h" 35 | 36 | #ifdef __cplusplus 37 | } 38 | #endif /*__cplusplus */ 39 | 40 | #define KPT_SET_UNIT(u, f) { u->name = #f; u->function = f; u->function_type = UNIT_TEST_FUNCTION_TYPE_TEST; } 41 | #define KPT_SETUP_UNIT(u, f) { u->name = #f; u->function = f; u->function_type = UNIT_TEST_FUNCTION_TYPE_SETUP; } 42 | #define KPT_TEARDOWN_UNIT(u, f) { u->name = #f; u->function = f; u->function_type = UNIT_TEST_FUNCTION_TYPE_TEARDOWN; } 43 | 44 | static KPTINLINE 45 | int KPTTestCopyGroup(UnitTest* aTarget, 46 | size_t aTargetMax, 47 | size_t* aTargetIndex, 48 | UnitTest* aSource, 49 | size_t aSourceCount) 50 | { 51 | if ((*aTargetIndex + aSourceCount) >= aTargetMax) 52 | { 53 | return -1; 54 | } 55 | else 56 | { 57 | UnitTest* destination = aTarget + *aTargetIndex; 58 | size_t index = 0; 59 | for(; index < aSourceCount; ++index) 60 | { 61 | *destination++ = *aSource++; 62 | } 63 | *aTargetIndex += aSourceCount; 64 | } 65 | return 0; 66 | } 67 | 68 | #endif /* #ifndef H_KPTTEST_H */ 69 | -------------------------------------------------------------------------------- /include/pal/kpttestlibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttestlibversion.h 16 | * 17 | * @brief Test library version information. 18 | * 19 | * @details Test library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptlibtest.h" 27 | 28 | #ifndef H_KPTTESTLIBVERSION_H 29 | #define H_KPTTESTLIBVERSION_H 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_TEST 37 | KPTResultT 38 | KPT_CALL 39 | KPTTestLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTTESTLIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kpttextfilebomparser.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttextfilebomparser.h 16 | * 17 | * @brief Interface to BOM parser. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTTEXTFILEBOMPARSER_H 27 | #define H_KPTTEXTFILEBOMPARSER_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | #include "kptbinarystream.h" 32 | #include "kpttextfile.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif /* __cplusplus */ 37 | 38 | KPT_LIB_SYSTEM 39 | KPTBoolT 40 | KPT_CALL 41 | KPTIdentifyBinaryStreamBOM(KPTBinaryStreamT* aStream, 42 | KPTTextFileBOMT aUserSuppliedBOM, 43 | KPTTextFileBOMT* aBOM, 44 | KPTBoolT* aBOMFromData); 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif /*__cplusplus */ 49 | 50 | 51 | #endif /* H_KPTTEXTFILEBOMPARSER_H */ 52 | -------------------------------------------------------------------------------- /include/pal/kpttimer.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttimer.h 16 | * 17 | * @brief System timer interface. 18 | * 19 | * @details 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTTIMER_H 27 | #define H_KPTTIMER_H 28 | 29 | #include "kptlibsystem.h" 30 | #include "kptapi.h" 31 | #include "kptheap.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | /* timer */ 38 | DECLARE_KPTHANDLE(KPTTimerT) 39 | 40 | KPT_LIB_SYSTEM 41 | KPTResultT 42 | KPT_CALL 43 | KPTTimerCreate(KPTTimerT** aHandle, 44 | KPTHeapT* aHeap); 45 | 46 | KPT_LIB_SYSTEM 47 | KPTResultT 48 | KPT_CALL 49 | KPTTimerDestroy(KPTTimerT** aHandle); 50 | 51 | KPT_LIB_SYSTEM 52 | KPTResultT 53 | KPT_CALL 54 | KPTTimerStart(KPTTimerT* aHandle); 55 | 56 | KPT_LIB_SYSTEM 57 | KPTResultT 58 | KPT_CALL 59 | KPTTimerStop(KPTTimerT* aHandle); 60 | 61 | KPT_LIB_SYSTEM 62 | KPTResultT 63 | KPT_CALL 64 | KPTTimerReset(KPTTimerT* aHandle); 65 | 66 | KPT_LIB_SYSTEM 67 | KPTResultT 68 | KPT_CALL 69 | KPTTimerIsRunning(const KPTTimerT* aHandle, 70 | KPTBoolT* aIsRunning); 71 | 72 | KPT_LIB_SYSTEM 73 | KPTResultT 74 | KPT_CALL 75 | KPTTimerGetElapsed(const KPTTimerT* aHandle, 76 | double* aSeconds); 77 | 78 | KPT_LIB_SYSTEM 79 | KPTResultT 80 | KPT_CALL 81 | KPTTimerGetResolution(const KPTTimerT* aHandle, 82 | double* aSeconds); 83 | 84 | #ifdef __cplusplus 85 | } 86 | #endif /*__cplusplus */ 87 | 88 | #endif /* #ifndef H_KPTTIMER_H */ 89 | -------------------------------------------------------------------------------- /include/pal/kptunicodelibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptunicodelibversion.h 16 | * 17 | * @brief Unicode library version information. 18 | * 19 | * @details Unicode library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #include "kptlibunicode.h" 27 | 28 | #ifndef H_KPTUNICODELIBVERSION_H 29 | #define H_KPTUNICODELIBVERSION_H 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_UNICODE 37 | KPTResultT 38 | KPT_CALL 39 | KPTUnicodeLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTUNICODELIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/kptutillibversion.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptutillibversion.h 16 | * 17 | * @brief Utility library version information. 18 | * 19 | * @details Utility library version information. 20 | * 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTUTILLIBVERSION_H 27 | #define H_KPTUTILLIBVERSION_H 28 | 29 | #include "kptlibutil.h" 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif /* __cplusplus */ 34 | 35 | /* library version */ 36 | KPT_LIB_UTIL 37 | KPTResultT 38 | KPT_CALL 39 | KPTUtilLibGetVersion(uint16_t* aMajor, 40 | uint16_t* aMinor, 41 | uint16_t* aPatch, 42 | uint16_t* aBuild); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif /*__cplusplus */ 47 | 48 | #endif /* #ifndef H_KPTUTILLIBVERSION_H */ 49 | -------------------------------------------------------------------------------- /include/pal/private/android/kptpal_imp.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptpal_imp.h 17 | * 18 | * @brief Internal header file to retrieve application directory and temporary directory 19 | * 20 | * @details 21 | *****************************************************************************/ 22 | #ifndef H_PAL_IMP_H 23 | #define H_PAL_IMP_H 24 | 25 | #ifdef __cplusplus 26 | extern "C" { 27 | #endif /* __cplusplus */ 28 | 29 | KPT_LIB_SYSTEM 30 | KPTSysCharT * 31 | KPT_CALL 32 | KPTPalGetApplicationDirectory(); 33 | 34 | KPT_LIB_SYSTEM 35 | KPTSysCharT * 36 | KPT_CALL 37 | KPTPalGetTempDirectory(); 38 | 39 | #ifdef __cplusplus 40 | } 41 | #endif /*__cplusplus */ 42 | 43 | #endif /* #ifndef H_KPTSYMBIAN_GLOBAL_H */ 44 | -------------------------------------------------------------------------------- /include/pal/private/android/kptsystem.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptsystem.h 17 | * 18 | * @brief Platform specific defines and includes for Android. 19 | * 20 | * @details This file contains platform defines that are used internally. 21 | * - Each core source file should include this file. 22 | * - Each project should set the include path for the appropriate platform. 23 | * - This file should not be included by any other header file. 24 | * 25 | *****************************************************************************/ 26 | 27 | #ifndef H_KPTYSTEM_H 28 | #define H_KPTYSTEM_H 29 | 30 | /* 31 | * Platform includes 32 | */ 33 | 34 | #include 35 | #include 36 | #include 37 | #include 38 | #include 39 | #include 40 | #include 41 | #include 42 | #include 43 | #include 44 | #include 45 | 46 | /* KPT headers */ 47 | #include "kptid.h" 48 | #include "kptapi.h" 49 | #include "kptstatus.h" 50 | #include "kptbyte.h" 51 | #include "kptout.h" 52 | #include "kpterrorstack.h" 53 | #include "kpterr.h" 54 | #include "kptassert.h" 55 | 56 | #endif /* H_KPTYSTEM_H */ 57 | -------------------------------------------------------------------------------- /include/pal/private/cmockery_internal.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file cmockery_internal.h 17 | * 18 | * @brief internal cmockery header file declarations 19 | * 20 | * @details 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_CMOCKERY_SYM_H 27 | #define H_CMOCKERY_SYM_H 28 | 29 | /*#ifndef C_FILE_COMPILE_AS_CPP*/ 30 | #ifdef __cplusplus 31 | extern "C" { 32 | #endif /* __cplusplus */ 33 | /*#endif*/ 34 | 35 | int KPTTestCaptureExceptions(); 36 | void KPTTestRestoreExceptions(int aHandleExceptions); 37 | 38 | /*#ifndef C_FILE_COMPILE_AS_CPP*/ 39 | #ifdef __cplusplus 40 | } 41 | #endif /*__cplusplus */ 42 | /*#endif*/ 43 | 44 | #endif /* #ifndef H_CMOCKERY_SYM_H*/ 45 | -------------------------------------------------------------------------------- /include/pal/private/kptbinaryfile_internal.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptbinaryfile_internal.h 17 | * 18 | * @brief Internal binary file header declarations 19 | * 20 | * @details 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPTBINARYFILE_INTERNAL_H 27 | #define H_KPTBINARYFILE_INTERNAL_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /* __cplusplus */ 32 | 33 | /* 34 | * Function to hide the way that the platform gets a standard C file handle. 35 | */ 36 | FILE* KPTBinaryFileOpenPlatform(uint32_t aOptions, 37 | const KPTSysCharT* aPath, 38 | KPTResultT* result, 39 | uint32_t* aOSError); 40 | 41 | /* 42 | * Function to hide the way that the platform gets a file length. 43 | */ 44 | KPTResultT KPTBinaryFileGetLengthPlatform(FILE* aFile, 45 | size_t* aSize, 46 | uint32_t* aOSError); 47 | 48 | 49 | #ifdef __cplusplus 50 | } 51 | #endif /*__cplusplus */ 52 | 53 | #endif /* #ifndef H_KPTBINARYFILE_INTERNAL_H*/ 54 | -------------------------------------------------------------------------------- /include/pal/private/kptcrc32ieee_table.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptcrc32ieee_table.h 17 | * 18 | * @brief Private implementation structure for heap objects 19 | * 20 | * @details 21 | * 22 | *****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_KPTCRC32IEEE_TABLE_H 28 | #define H_KPTCRC32IEEE_TABLE_H 29 | 30 | #ifdef __cplusplus 31 | extern "C" { 32 | #endif /* __cplusplus */ 33 | 34 | extern 35 | const uint32_t* KPTCrc32IeeeGetTable(); 36 | 37 | #ifdef __cplusplus 38 | } 39 | #endif /*__cplusplus */ 40 | 41 | #endif /* #ifndef H_KPTCRC32IEEE_TABLE_H */ 42 | -------------------------------------------------------------------------------- /include/pal/private/kptdirscan_imp.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptdirlist_imp.h 17 | * 18 | * @brief Private implementation structure for the directory file list 19 | * 20 | * @details 21 | * 22 | *****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_KPTDIRLIST_IMP_H 28 | #define H_KPTDIRLIST_IMP_H 29 | 30 | #include "kptlibsystem.h" 31 | #include "kptapi.h" 32 | #include "kptlist.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif /* __cplusplus */ 37 | 38 | 39 | /** 40 | * Private implementation structure for directory listings 41 | */ 42 | struct KPTDirListT 43 | { 44 | KPTSysCharT* dirName; 45 | KPTHeapT* kptHeap; 46 | KPTListT* dirList; 47 | KPTListT* fileList; 48 | }; 49 | 50 | #ifdef __cplusplus 51 | } 52 | #endif /*__cplusplus */ 53 | 54 | #endif /* H_KPTDIRLIST_IMP_H*/ 55 | -------------------------------------------------------------------------------- /include/pal/private/kpterrorstack_imp.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kpterrorstack.h 17 | * 18 | * @brief Private implementation structure for the errorstack mechanism. 19 | * 20 | * @details 21 | * 22 | *****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_KPTERRORSTACK_IMP_H 28 | #define H_KPTERRORSTACK_IMP_H 29 | 30 | #include "kptlibsystem.h" 31 | #include "kptapi.h" 32 | #include "kpterrorstack.h" 33 | #include "kptcritsection.h" 34 | #include "kptout.h" 35 | 36 | #ifdef __cplusplus 37 | extern "C" { 38 | #endif /* __cplusplus */ 39 | 40 | /** 41 | * A single item in the error stack. 42 | */ 43 | typedef struct KPTErrorStackInternalT KPTErrorStackInternalT; 44 | struct KPTErrorStackInternalT 45 | { 46 | KPTErrorStackDetailsT data; /**< details for the error */ 47 | uint32_t id; /**< sequential identifier */ 48 | }; 49 | 50 | /** Output categories for error stack */ 51 | #ifndef KPT_CAT_ERRORSTACK 52 | #define KPT_CAT_ERRORSTACK KPT_LIBSYSTEM_CATEGORY 53 | #endif 54 | 55 | /** Maximum depth of error stack */ 56 | #ifndef KPTERRORSTACK_MAXDEPTH 57 | #define KPTERRORSTACK_MAXDEPTH 64 58 | #endif 59 | 60 | /** 61 | * Private implementation of KPTErrorStack. 62 | */ 63 | struct KPTErrorStackT 64 | { 65 | /* Shared values */ 66 | KPTHeapT* heap; /**< Heap that created the stack. */ 67 | KPTOutT* out; /**< The output mechanism for this stack, NULL = default. */ 68 | size_t maxDepth; /**< Size of the internal stack. */ 69 | size_t count; /**< Number of items in the internal stack. */ 70 | size_t options; /**< KPTErrorStackOptionsT. */ 71 | KPTBoolT enabled; /**< Enabled state. */ 72 | uint32_t nextId; /**< Identifier for next item on stack. */ 73 | KPTCriticalSectionT* criticalSection; /**< Thread safety. */ 74 | 75 | /* Stack array, 0 is the bottom */ 76 | KPTErrorStackInternalT stack[1]; 77 | }; 78 | 79 | 80 | #ifdef __cplusplus 81 | } 82 | #endif /*__cplusplus */ 83 | 84 | #endif /* #ifndef H_KPTERRORSTACK_IMP_H */ 85 | -------------------------------------------------------------------------------- /include/pal/private/kptfilepath_imp.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptfilepath_imp.h 17 | * 18 | * @brief Private implementation structure for the file path 19 | * 20 | * @details 21 | * 22 | *****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_KPTFILEPATH_IMP_H 28 | #define H_KPTFILEPATH_IMP_H 29 | 30 | #include "kptlibsystem.h" 31 | #include "kptapi.h" 32 | 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /* __cplusplus */ 36 | 37 | /** Implementation of KPTFilePath */ 38 | struct KPTFilePathT 39 | { 40 | /** Number of characters in the path (not including terminator) */ 41 | size_t length; 42 | 43 | /** Maximum number of characters in the path (not including terminator) */ 44 | size_t maxLength; 45 | 46 | /** The heap used to allocate memory for the buffer */ 47 | KPTHeapT* heap; 48 | 49 | /** Start of the character buffer. */ 50 | KPTSysCharT buffer[1]; 51 | }; 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif /*__cplusplus */ 56 | 57 | #endif /* H_KPTFILEPATH_IMP_H */ 58 | -------------------------------------------------------------------------------- /include/pal/private/kpttreefactory.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kpttreefactory.h 17 | * 18 | * @brief Object providing Factory Method for Tree construction. 19 | * 20 | * @details 21 | * 22 | ****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_TREE_FACTORY_H 28 | #define H_TREE_FACTORY_H 29 | 30 | 31 | #include "kptlibcollections.h" 32 | #include "kptapi.h" 33 | #include "kptiterator.h" 34 | #include "kpttree.h" 35 | #include "kpttreebase.h" 36 | 37 | #ifdef __cplusplus 38 | extern "C" { 39 | #endif /* __cplusplus */ 40 | 41 | 42 | /* 43 | Factory method to create tree based on type. 44 | */ 45 | KPTTreeBaseT* 46 | KPT_CALL 47 | KPTCreateTreeByType(KPTHeapT* aHeap, 48 | size_t aNodeSize, 49 | KPTTreeTypeT aTreeType, 50 | size_t aPreAllocs, 51 | KPTBoolT aIsUnique, 52 | KPTResultT *aRetStatus); 53 | 54 | /* 55 | Factory method to destroy tree based on type. 56 | */ 57 | void 58 | KPT_CALL 59 | KPTTreeFinalize(KPTTreeBaseT *aTree, 60 | KPTTreeTypeT aTreeType, 61 | KPTNodeDestructionFnT* aDestructFn); 62 | 63 | #ifdef __cplusplus 64 | } 65 | #endif /*__cplusplus */ 66 | 67 | #endif /* H_TREE_FACTORY_H */ 68 | -------------------------------------------------------------------------------- /include/pal/private/kptunicodebinarydata.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptunicodebinarydata.h 17 | * 18 | * @brief Parses the unicode binary file and sores the data in a heap array. 19 | * 20 | * @details 21 | * 22 | ****************************************************************************/ 23 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 24 | #pragma once 25 | #endif 26 | 27 | #ifndef H_KPT_UNICODEBINARYDATA_H__ 28 | #define H_KPT_UNICODEBINARYDATA_H__ 29 | 30 | #include "kptapi.h" 31 | #include "kptheap.h" 32 | #include "kptunicodetable.h" 33 | #ifdef __cplusplus 34 | extern "C" { 35 | #endif /*__cplusplus */ 36 | 37 | KPTResultT 38 | KPT_CALL 39 | KPTUnicodeBinaryDataParseFile(KPTPalUnicodeTableT* aUnicodeTable, KPTHeapT* aKptHeap); 40 | 41 | KPTResultT 42 | KPT_CALL 43 | KPTUnicodeBinaryDataDestroyTables(KPTPalUnicodeTableT* aUnicodeTable, KPTHeapT* aKptHeap); 44 | 45 | #ifdef __cplusplus 46 | } 47 | #endif /*__cplusplus */ 48 | 49 | #endif /* H_KPT_UNICODEBINARYDATA_H__ */ 50 | 51 | -------------------------------------------------------------------------------- /include/pal/private/symbian/kptglobal.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptglobal.h 17 | * 18 | * @brief Internal header file to retrieve global instances. 19 | * 20 | * @details 21 | *****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_GLOBAL_H 27 | #define H_GLOBAL_H 28 | 29 | #include 30 | 31 | /* Defines to convert uint to TPtr */ 32 | #define SYMBIAN_STR_8(symStr, str, length, maxLength) TPtr8 symStr((TUint8 *) (str), (length), (maxLength)) 33 | #define SYMBIAN_STR_EMPTY_8(symStr, str, maxLength) TPtr8 symStr((TUint8 *)(str), 0, (maxLength)) 34 | #define SYMBIAN_STR_16(symStr, str, length, maxLength) TPtr16 symStr((TUint16 *)(str), (length), (maxLength)) 35 | 36 | #ifdef __cplusplus 37 | extern "C" { 38 | #endif /* __cplusplus */ 39 | 40 | KPT_LIB_SYSTEM 41 | RFs& 42 | KPT_CALL 43 | KPTPalGetFileServer(); 44 | 45 | #ifdef __cplusplus 46 | } 47 | #endif /*__cplusplus */ 48 | 49 | #endif /* #ifndef H_KPTSYMBIAN_GLOBAL_H */ 50 | -------------------------------------------------------------------------------- /include/pal/private/symbian/kptsystem.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * 16 | * @file kptsystem.h 17 | * 18 | * @brief Platform specific defines and includes for Win32. 19 | * 20 | * @details This file contains platform defines that are used internally. 21 | * - Each core source file should include this file. 22 | * - Each project should set the include path for the appropriate platform. 23 | * - This file should not be included by any other header file. 24 | * 25 | *****************************************************************************/ 26 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 27 | #pragma once 28 | #endif 29 | 30 | 31 | #ifndef H_KPTYSTEM_H 32 | #define H_KPTYSTEM_H 33 | 34 | #pragma cplusplus on 35 | #include 36 | #include 37 | #include 38 | #include 39 | #include 40 | #include 41 | #include 42 | #include 43 | #include 44 | 45 | /* KPT headers */ 46 | #include "kptid.h" 47 | #include "kptapi.h" 48 | #include "kptstatus.h" 49 | #include "kptbyte.h" 50 | #include "kptout.h" 51 | #include "kpterrorstack.h" 52 | #include "kpterr.h" 53 | #include "kptassert.h" 54 | 55 | /* __offsetof__ is a GCC built in macro which is not defined in WINSCW 56 | * So define __offsetof for WINSCW without __offsetof__ macro. 57 | */ 58 | #if defined(__WINS__) || defined(__WINSCW__) 59 | #ifndef __offsetof__ 60 | #undef __offsetof 61 | #define __offsetof(type, field) \ 62 | ( (reinterpret_cast \ 63 | (&reinterpret_cast \ 64 | (static_cast (0)->field)))) 65 | 66 | #endif 67 | #endif 68 | 69 | #endif /* H_KPTYSTEM_H */ 70 | -------------------------------------------------------------------------------- /include/pal/symbian/kptfilepath_platform.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfilepath_platform.h 16 | * 17 | * @brief Platform-dependent file path defines. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_FILEPATHPLATFORM_H 27 | #define H_KPT_FILEPATHPLATFORM_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /*__cplusplus */ 32 | 33 | #ifndef KPT_DIR_DELIM_STD 34 | #define KPT_DIR_DELIM_STD KPT_TS('\\') 35 | #endif 36 | #ifndef KPT_DIR_DELIM_ALT 37 | #define KPT_DIR_DELIM_ALT KPT_TS('/') 38 | #endif 39 | 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif /*__cplusplus */ 44 | 45 | #endif /* H_KPT_FILEPATHPLATFORM_H */ 46 | -------------------------------------------------------------------------------- /include/pal/symbian/kptlibtest.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttestlib.h 16 | * 17 | * @brief Include file for KPT Test library 18 | * 19 | * @details This file is contains windows specific pragmas that will link to 20 | * the correct version of the library. 21 | * 22 | *****************************************************************************/ 23 | #pragma once 24 | #ifndef H_KPT_LIBTEST_H 25 | #define H_KPT_LIBTEST_H 26 | 27 | #include "kptcompile.h" 28 | 29 | #if defined KPT_LIBTEST_DLL 30 | 31 | /* Using library as a DLL */ 32 | #define KPT_LIB_TEST __declspec(dllimport) 33 | 34 | #if defined _MT 35 | 36 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 37 | #if defined _DLL 38 | 39 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 40 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 41 | #pragma comment(lib, "kpttestDMDd.lib") 42 | #else 43 | #pragma comment(lib, "kpttestDMD.lib") 44 | #endif 45 | 46 | #else 47 | 48 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 49 | #pragma comment(lib, "kpttestDMTd.lib") 50 | #else 51 | #pragma comment(lib, "kpttestDMT.lib") 52 | #endif 53 | 54 | #endif 55 | 56 | #endif 57 | 58 | #elif defined KPT_LIBTEST_CREATEDLL 59 | 60 | /* Creating library as a DLL */ 61 | #define KPT_LIB_TEST __declspec(dllexport) 62 | 63 | #elif defined KPT_LIBTEST_CREATELIB 64 | 65 | /* Creating library as a static library */ 66 | #define KPT_LIB_TEST 67 | 68 | #else 69 | 70 | /* Using library as a static library */ 71 | #define KPT_LIB_TEST 72 | 73 | #if defined _MT 74 | 75 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 76 | #if defined _DLL 77 | 78 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 79 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 80 | #pragma comment(lib, "kpttestSMDd.lib") 81 | #else 82 | #pragma comment(lib, "kpttestSMD.lib") 83 | #endif 84 | 85 | #else 86 | 87 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 88 | #pragma comment(lib, "kpttestSMTd.lib") 89 | #else 90 | #pragma comment(lib, "kpttestSMT.lib") 91 | #endif 92 | 93 | #endif 94 | 95 | #endif 96 | 97 | #endif 98 | 99 | #endif /* #ifndef H_KPT_LIBTEST_H */ 100 | -------------------------------------------------------------------------------- /include/pal/win32/kptfilepath_platform.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfilepath_platform.h 16 | * 17 | * @brief Platform-dependent file path defines. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_FILEPATHPLATFORM_H 27 | #define H_KPT_FILEPATHPLATFORM_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /*__cplusplus */ 32 | 33 | #ifndef KPT_DIR_DELIM_STD 34 | #define KPT_DIR_DELIM_STD KPT_TS('\\') 35 | #endif 36 | #ifndef KPT_DIR_DELIM_ALT 37 | #define KPT_DIR_DELIM_ALT KPT_TS('/') 38 | #endif 39 | 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif /*__cplusplus */ 44 | 45 | #endif /* H_KPT_FILEPATHPLATFORM_H */ 46 | -------------------------------------------------------------------------------- /include/pal/win32/kptlibtest.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttestlib.h 16 | * 17 | * @brief Include file for KPT Test library 18 | * 19 | * @details This file is contains windows specific pragmas that will link to 20 | * the correct version of the library. 21 | * 22 | *****************************************************************************/ 23 | #pragma once 24 | #ifndef H_KPT_LIBTEST_H 25 | #define H_KPT_LIBTEST_H 26 | 27 | #include "kptcompile.h" 28 | 29 | #if defined KPT_LIBTEST_DLL 30 | 31 | /* Using library as a DLL */ 32 | #define KPT_LIB_TEST __declspec(dllimport) 33 | 34 | #if defined _MT 35 | 36 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 37 | #if defined _DLL 38 | 39 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 40 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 41 | #pragma comment(lib, "kpttestDMDd.lib") 42 | #else 43 | #pragma comment(lib, "kpttestDMD.lib") 44 | #endif 45 | 46 | #else 47 | 48 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 49 | #pragma comment(lib, "kpttestDMTd.lib") 50 | #else 51 | #pragma comment(lib, "kpttestDMT.lib") 52 | #endif 53 | 54 | #endif 55 | 56 | #endif 57 | 58 | #elif defined KPT_LIBTEST_CREATEDLL 59 | 60 | /* Creating library as a DLL */ 61 | #define KPT_LIB_TEST __declspec(dllexport) 62 | 63 | #elif defined KPT_LIBTEST_CREATELIB 64 | 65 | /* Creating library as a static library */ 66 | #define KPT_LIB_TEST 67 | 68 | #else 69 | 70 | /* Using library as a static library */ 71 | #define KPT_LIB_TEST 72 | 73 | #if defined _MT 74 | 75 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 76 | #if defined _DLL 77 | 78 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 79 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 80 | #pragma comment(lib, "kpttestSMDd.lib") 81 | #else 82 | #pragma comment(lib, "kpttestSMD.lib") 83 | #endif 84 | 85 | #else 86 | 87 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 88 | #pragma comment(lib, "kpttestSMTd.lib") 89 | #else 90 | #pragma comment(lib, "kpttestSMT.lib") 91 | #endif 92 | 93 | #endif 94 | 95 | #endif 96 | 97 | #endif 98 | 99 | #endif /* #ifndef H_KPT_LIBTEST_H */ 100 | -------------------------------------------------------------------------------- /include/pal/winSD/kptfilepath_platform.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kptfilepath_platform.h 16 | * 17 | * @brief Platform-dependent file path defines. 18 | * 19 | * @details 20 | * 21 | ****************************************************************************/ 22 | #if defined (_MSC_VER) && (_MSC_VER >= 1020) 23 | #pragma once 24 | #endif 25 | 26 | #ifndef H_KPT_FILEPATHPLATFORM_H 27 | #define H_KPT_FILEPATHPLATFORM_H 28 | 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif /*__cplusplus */ 32 | 33 | #ifndef KPT_DIR_DELIM_STD 34 | #define KPT_DIR_DELIM_STD KPT_TS('\\') 35 | #endif 36 | #ifndef KPT_DIR_DELIM_ALT 37 | #define KPT_DIR_DELIM_ALT KPT_TS('/') 38 | #endif 39 | 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif /*__cplusplus */ 44 | 45 | #endif /* H_KPT_FILEPATHPLATFORM_H */ 46 | -------------------------------------------------------------------------------- /include/pal/winSD/kptlibtest.h: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * 3 | * Copyright 2011 KeyPoint Technologies (UK) Ltd. 4 | * All rights reserved. This program and the accompanying materials 5 | * are made available under the terms of the Eclipse Public License v1.0 6 | * which accompanies this distribution, and is available at 7 | * http://www.eclipse.org/legal/epl-v10.html 8 | 9 | * 10 | * Contributors: 11 | * KeyPoint Technologies (UK) Ltd - Initial API and implementation 12 | * 13 | *****************************************************************************/ 14 | /** 15 | * @file kpttestlib.h 16 | * 17 | * @brief Include file for KPT Test library 18 | * 19 | * @details This file is contains windows specific pragmas that will link to 20 | * the correct version of the library. 21 | * 22 | *****************************************************************************/ 23 | #pragma once 24 | #ifndef H_KPT_LIBTEST_H 25 | #define H_KPT_LIBTEST_H 26 | 27 | #include "kptcompile.h" 28 | 29 | #if defined KPT_LIBTEST_DLL 30 | 31 | /* Using library as a DLL */ 32 | #define KPT_LIB_TEST __declspec(dllimport) 33 | 34 | #if defined _MT 35 | 36 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 37 | #if defined _DLL 38 | 39 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 40 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 41 | #pragma comment(lib, "kpttestDMDd.lib") 42 | #else 43 | #pragma comment(lib, "kpttestDMD.lib") 44 | #endif 45 | 46 | #else 47 | 48 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 49 | #pragma comment(lib, "kpttestDMTd.lib") 50 | #else 51 | #pragma comment(lib, "kpttestDMT.lib") 52 | #endif 53 | 54 | #endif 55 | 56 | #endif 57 | 58 | #elif defined KPT_LIBTEST_CREATEDLL 59 | 60 | /* Creating library as a DLL */ 61 | #define KPT_LIB_TEST __declspec(dllexport) 62 | 63 | #elif defined KPT_LIBTEST_CREATELIB 64 | 65 | /* Creating library as a static library */ 66 | #define KPT_LIB_TEST 67 | 68 | #else 69 | 70 | /* Using library as a static library */ 71 | #define KPT_LIB_TEST 72 | 73 | #if defined _MT 74 | 75 | /* /MD or /MDd (Multithreaded DLL) or /MT or /MTd (Multithreaded) is specified. */ 76 | #if defined _DLL 77 | 78 | /* Defined when /MD or /MDd (Multithread DLL) is specified. */ 79 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 80 | #pragma comment(lib, "kpttestSMDd.lib") 81 | #else 82 | #pragma comment(lib, "kpttestSMD.lib") 83 | #endif 84 | 85 | #else 86 | 87 | #if defined(_DEBUG) || defined(KPT_LIBTEST_DEBUG) 88 | #pragma comment(lib, "kpttestSMTd.lib") 89 | #else 90 | #pragma comment(lib, "kpttestSMT.lib") 91 | #endif 92 | 93 | #endif 94 | 95 | #endif 96 | 97 | #endif 98 | 99 | #endif /* #ifndef H_KPT_LIBTEST_H */ 100 | -------------------------------------------------------------------------------- /include/servers/bootstrap_defs.h: -------------------------------------------------------------------------------- 1 | bootstrap.h -------------------------------------------------------------------------------- /include/servers/netname_defs.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. 3 | * 4 | * @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 5 | * 6 | * This file contains Original Code and/or Modifications of Original Code 7 | * as defined in and that are subject to the Apple Public Source License 8 | * Version 2.0 (the 'License'). You may not use this file except in 9 | * compliance with the License. The rights granted to you under the License 10 | * may not be used to create, or enable the creation or redistribution of, 11 | * unlawful or unlicensed copies of an Apple operating system, or to 12 | * circumvent, violate, or enable the circumvention or violation of, any 13 | * terms of an Apple operating system software license agreement. 14 | * 15 | * Please obtain a copy of the License at 16 | * http://www.opensource.apple.com/apsl/ and read it before using this file. 17 | * 18 | * The Original Code and all software distributed under the License are 19 | * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 20 | * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 21 | * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 22 | * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 23 | * Please see the License for the specific language governing rights and 24 | * limitations under the License. 25 | * 26 | * @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 27 | */ 28 | /* 29 | * Mach Operating System 30 | * Copyright (c) 1987 Carnegie-Mellon University 31 | * All rights reserved. The CMU software License Agreement specifies 32 | * the terms and conditions for use and redistribution. 33 | */ 34 | 35 | /* 36 | * Definitions for the mig interface to the network name service. 37 | */ 38 | 39 | /* 40 | * HISTORY: 41 | * 28-Jul-88 Mary R. Thompson (mrt) at Carnegie Mellon 42 | * Copied definitions of NAME_NOT_YOURS and NAME_NOT_CHECKED_IN 43 | * from the old netname_defs.h so that old code would not break 44 | * 45 | * 8-Mar-88 Daniel Julin (dpj) at Carnegie-Mellon University 46 | * Added NETNAME_INVALID_PORT. 47 | * 48 | * 28-Feb-88 Daniel Julin (dpj) at Carnegie-Mellon University 49 | * Added NETNAME_PENDING. 50 | * 51 | * 23-Dec-86 Robert Sansom (rds) at Carnegie Mellon University 52 | * Copied from the previous version of the network server. 53 | * 54 | */ 55 | 56 | #ifndef _NETNAME_DEFS_ 57 | #define _NETNAME_DEFS_ 58 | 59 | #define NETNAME_SUCCESS (0) 60 | #define NETNAME_PENDING (-1) 61 | #define NETNAME_NOT_YOURS (1000) 62 | #define NAME_NOT_YOURS (1000) 63 | #define NETNAME_NOT_CHECKED_IN (1001) 64 | #define NAME_NOT_CHECKED_IN (1001) 65 | #define NETNAME_NO_SUCH_HOST (1002) 66 | #define NETNAME_HOST_NOT_FOUND (1003) 67 | #define NETNAME_INVALID_PORT (1004) 68 | 69 | typedef char netname_name_t[80]; 70 | 71 | #endif /* NETNAME_DEFS_ */ 72 | -------------------------------------------------------------------------------- /include/servers/nm_defs.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. 3 | * 4 | * @APPLE_OSREFERENCE_LICENSE_HEADER_START@ 5 | * 6 | * This file contains Original Code and/or Modifications of Original Code 7 | * as defined in and that are subject to the Apple Public Source License 8 | * Version 2.0 (the 'License'). You may not use this file except in 9 | * compliance with the License. The rights granted to you under the License 10 | * may not be used to create, or enable the creation or redistribution of, 11 | * unlawful or unlicensed copies of an Apple operating system, or to 12 | * circumvent, violate, or enable the circumvention or violation of, any 13 | * terms of an Apple operating system software license agreement. 14 | * 15 | * Please obtain a copy of the License at 16 | * http://www.opensource.apple.com/apsl/ and read it before using this file. 17 | * 18 | * The Original Code and all software distributed under the License are 19 | * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 20 | * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 21 | * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 22 | * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 23 | * Please see the License for the specific language governing rights and 24 | * limitations under the License. 25 | * 26 | * @APPLE_OSREFERENCE_LICENSE_HEADER_END@ 27 | */ 28 | /* 29 | * Mach Operating System 30 | * Copyright (c) 1987 Carnegie-Mellon University 31 | * All rights reserved. The CMU software License Agreement specifies 32 | * the terms and conditions for use and redistribution. 33 | */ 34 | 35 | /* 36 | * Random definitions for the network service that everyone needs! 37 | */ 38 | 39 | /* 40 | * HISTORY: 41 | * 27-Mar-90 Gregg Kellogg (gk) at NeXT 42 | * include rather than 43 | * 44 | * 24-Aug-88 Daniel Julin (dpj) at Carnegie-Mellon University 45 | * Replace sys/mach_ipc_netport.h with kern/ipc_netport.h. Sigh. 46 | * 47 | * 24-May-88 Daniel Julin (dpj) at Carnegie-Mellon University 48 | * Replace mach_ipc_vmtp.h with mach_ipc_netport.h. 49 | * 50 | * 4-Sep-87 Daniel Julin (dpj) at Carnegie-Mellon University 51 | * Fixed for new kernel include files which declare a lot 52 | * of network server stuff internally, because of the NETPORT 53 | * option. 54 | * 55 | * 5-Nov-86 Robert Sansom (rds) at Carnegie-Mellon University 56 | * Started. 57 | * 58 | */ 59 | 60 | #ifndef _NM_DEFS_ 61 | #define _NM_DEFS_ 62 | 63 | /* 64 | * netaddr_t is declared with the kernel files, 65 | * in . 66 | */ 67 | #include 68 | 69 | #ifdef notdef 70 | typedef unsigned long netaddr_t; 71 | #endif /* notdef */ 72 | 73 | typedef union { 74 | struct { 75 | unsigned char ia_net_owner; 76 | unsigned char ia_net_node_type; 77 | unsigned char ia_host_high; 78 | unsigned char ia_host_low; 79 | } ia_bytes; 80 | netaddr_t ia_netaddr; 81 | } ip_addr_t; 82 | 83 | #endif /* _NM_DEFS_ */ 84 | 85 | -------------------------------------------------------------------------------- /include/types.hpp: -------------------------------------------------------------------------------- 1 | #if !defined LIBFACE_TYPES_HPP 2 | #define LIBFACE_TYPES_HPP 3 | 4 | #include 5 | #include 6 | #include 7 | #include 8 | 9 | #if !defined RMQ 10 | #define RMQ SegmentTree 11 | // #define RMQ SparseTable 12 | #endif 13 | 14 | typedef unsigned int uint_t; 15 | 16 | struct StringProxy { 17 | const char *mem_base; 18 | int len; 19 | 20 | StringProxy(const char *_mb = NULL, int _l = 0) 21 | : mem_base(_mb), len(_l) 22 | { } 23 | 24 | void 25 | assign(const char *_mb, int _l) { 26 | this->mem_base = _mb; 27 | this->len = _l; 28 | } 29 | 30 | size_t 31 | size() const { 32 | return this->len; 33 | } 34 | 35 | operator std::string() const { 36 | return std::string(this->mem_base, this->len); 37 | } 38 | 39 | void 40 | swap(StringProxy &rhs) { 41 | std::swap(this->mem_base, rhs.mem_base); 42 | std::swap(this->len, rhs.len); 43 | } 44 | 45 | }; 46 | 47 | 48 | struct phrase_t { 49 | uint_t weight; 50 | std::string phrase; 51 | StringProxy snippet; 52 | 53 | phrase_t(uint_t _w, std::string const& _p, StringProxy const& _s) 54 | : weight(_w), phrase(_p), snippet(_s) { 55 | } 56 | 57 | void 58 | swap(phrase_t& rhs) { 59 | std::swap(this->weight, rhs.weight); 60 | this->phrase.swap(rhs.phrase); 61 | this->snippet.swap(rhs.snippet); 62 | } 63 | 64 | bool 65 | operator<(phrase_t const& rhs) const { 66 | return this->phrase < rhs.phrase; 67 | } 68 | }; 69 | 70 | // Specialize std::swap for our type 71 | namespace std { 72 | inline void 73 | swap(phrase_t& lhs, phrase_t& rhs) { 74 | lhs.swap(rhs); 75 | } 76 | } 77 | 78 | typedef std::vector vp_t; 79 | typedef vp_t::iterator vpi_t; 80 | typedef std::pair pvpi_t; 81 | 82 | typedef std::pair pui_t; 83 | typedef std::vector vui_t; 84 | typedef std::vector vpui_t; 85 | typedef std::vector vvpui_t; 86 | 87 | typedef std::pair psui_t; 88 | typedef std::vector vpsui_t; 89 | typedef std::vector vs_t; 90 | typedef std::pair pvsi_t; 91 | typedef std::pair pvpsuii_t; 92 | 93 | 94 | #endif // LIBFACE_TYPES_HPP 95 | -------------------------------------------------------------------------------- /include/utils.hpp: -------------------------------------------------------------------------------- 1 | #if !defined LIBFACE_UTILS_HPP 2 | #define LIBFACE_UTILS_HPP 3 | 4 | #include 5 | #include 6 | #include 7 | 8 | #include "types.hpp" 9 | 10 | #if defined NDEBUG 11 | #define DCERR(X) 12 | #else 13 | #define DCERR(X) cerr< 1) { 20 | n /= 2; 21 | ++lg2; 22 | } 23 | return lg2; 24 | } 25 | 26 | const uint_t minus_one = (uint_t)0 - 1; 27 | 28 | template 29 | std::ostream& 30 | operator<<(std::ostream& out, std::vector const& vec) { 31 | for (size_t i = 0; i < vec.size(); ++i) { 32 | out< 38 | std::ostream& 39 | operator<<(std::ostream& out, std::pair const& p) { 40 | out<<"("<= 5.0), mobilesubstrate, preferenceloader (>= 2.0.4) 4 | Pre-Depends: com.ericasadun.utilities 5 | Conflicts: com.japaneatahand.manualcorrectpro, com.japaneatahand.manualcorrect 6 | Version: 1.0.5 7 | Architecture: iphoneos-arm 8 | Description: Type like an octopus! A license needed for activation. This is a pre-release build, when sending me an email, please mention that. Also note that I may not be able to respond to every email regarding pre-releases. 9 | Author: K3A 10 | Section: Tweaks 11 | Icon: file:///Library/PreferenceBundles/OKPrefs.bundle/OKIcon@2x.png 12 | -------------------------------------------------------------------------------- /layout/DEBIAN/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo "Restarting/loading daemon..." 4 | killall octopusd || true 5 | chown 0:0 /System/Library/LaunchDaemons/me.k3a.octopusd.plist 6 | launchctl load -w /System/Library/LaunchDaemons/me.k3a.octopusd.plist || true 7 | 8 | echo "Disabling autocorrection if enabled..." 9 | plutil -key KeyboardAutocorrection -value 0 -type bool /var/mobile/Library/Preferences/com.apple.Preferences.plist 10 | -------------------------------------------------------------------------------- /layout/DEBIAN/prerm: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo "Stopping the daemon..." 4 | launchctl unload -w /System/Library/LaunchDaemons/me.k3a.octopusd.plist || true 5 | killall octopusd || true 6 | 7 | -------------------------------------------------------------------------------- /lib/libcurl.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/lib/libcurl.a -------------------------------------------------------------------------------- /lib/libcurl_armv6.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/lib/libcurl_armv6.a -------------------------------------------------------------------------------- /lib/libkpt.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/lib/libkpt.a -------------------------------------------------------------------------------- /octopus_mach_types.h: -------------------------------------------------------------------------------- 1 | 2 | #include 3 | #include 4 | 5 | typedef char string_t[1024]; 6 | 7 | 8 | typedef struct { 9 | mach_msg_header_t head; 10 | 11 | // The following fields do not represent the actual layout of the request 12 | // and reply messages that MIG will use. However, a request or reply 13 | // message will not be larger in size than the sum of the sizes of these 14 | // fields. We need the size to put an upper bound on the size of an 15 | // incoming message in a mach_msg() call. 16 | NDR_record_t NDR; 17 | union { 18 | string_t string; 19 | //other types 20 | } data; 21 | 22 | kern_return_t RetCode; 23 | mach_msg_trailer_t trailer; 24 | } msg_octopus_t; 25 | 26 | #define OCTOPUS_SERVICE "me.k3a.octopusd" -------------------------------------------------------------------------------- /octopuscore/ATXProfile/ConfigSettings.dat: -------------------------------------------------------------------------------- 1 | 1 2 | [SuggConfig_fieldMask] 3 | FF1 4 | [SuggConfig_maxNumSuggestions] 5 | 14 6 | [SuggConfig_numElisionCompletions] 7 | 0 8 | [SuggConfig_suggestionThreshold] 9 | 0 10 | [SuggConfig_proximitySuggestionOn] 11 | 0 12 | [SuggConfig_errorCorrectionOn] 13 | 0 14 | [SuggConfig_completionOn] 15 | 1 16 | [SuggConfig_useStoredCaps] 17 | 1 18 | [SuggConfig_forceLower] 19 | 0 20 | [SuggConfig_forceUpper] 21 | 0 22 | [SuggConfig_useSentenceCase] 23 | 1 24 | [SuggConfig_honourUserCaps] 25 | 1 26 | [InpMgrConfig_fieldMask] 27 | 1 28 | [InpMgrConfig_mergeCRLFOn] 29 | 1 30 | [LearnConfig_options] 31 | 1 32 | -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Context/User_0.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/Context/User_0.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Context/User_1.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/Context/User_1.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Context/User_2.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/Context/User_2.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Default_Profile.ata: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/Default_Profile.ata -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Dictionaries/User.atu: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/Dictionaries/User.atu -------------------------------------------------------------------------------- /octopuscore/ATXProfile/KPTUnicodeData.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/KPTUnicodeData.bin -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Lang/v2_keymap0.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 7 6 | 3 7 | 1 8 | 1 9 | 26 10 | 1 11 | 0,0 12 | 2 13 | 0x80051 14 | 0x71 15 | 2 16 | 0,1 17 | 2 18 | 0x80057 19 | 0x77 20 | 3 21 | 0,2 22 | 6 23 | 0x80045 24 | 0x65 25 | 0xE9 26 | 0xE8 27 | 0xEA 28 | 0xEB 29 | 4 30 | 0,3 31 | 2 32 | 0x80052 33 | 0x72 34 | 5 35 | 0,4 36 | 2 37 | 0x80054 38 | 0x74 39 | 6 40 | 0,5 41 | 3 42 | 0x80059 43 | 0x79 44 | 0xFF 45 | 7 46 | 0,6 47 | 6 48 | 0x80055 49 | 0x75 50 | 0xFA 51 | 0xF9 52 | 0xFB 53 | 0xFC 54 | 8 55 | 0,7 56 | 6 57 | 0x80049 58 | 0x69 59 | 0xED 60 | 0xEC 61 | 0xEE 62 | 0xEF 63 | 9 64 | 0,8 65 | 7 66 | 0x8004F 67 | 0x6F 68 | 0xF3 69 | 0xF2 70 | 0xF4 71 | 0xF6 72 | 0x153 73 | 10 74 | 0,9 75 | 2 76 | 0x80050 77 | 0x70 78 | 11 79 | 1,0 80 | 7 81 | 0x80041 82 | 0x61 83 | 0xE1 84 | 0xE0 85 | 0xE2 86 | 0xE6 87 | 0xE4 88 | 12 89 | 1,1 90 | 3 91 | 0x80053 92 | 0x73 93 | 0xDF 94 | 13 95 | 1,2 96 | 2 97 | 0x80044 98 | 0x64 99 | 14 100 | 1,3 101 | 2 102 | 0x80046 103 | 0x66 104 | 15 105 | 1,4 106 | 2 107 | 0x80047 108 | 0x67 109 | 16 110 | 1,5 111 | 2 112 | 0x80048 113 | 0x68 114 | 17 115 | 1,6 116 | 2 117 | 0x8004A 118 | 0x6A 119 | 18 120 | 1,7 121 | 2 122 | 0x8004B 123 | 0x6B 124 | 19 125 | 1,8 126 | 2 127 | 0x8004C 128 | 0x6C 129 | 20 130 | 2,0 131 | 2 132 | 0x8005A 133 | 0x7A 134 | 21 135 | 2,1 136 | 2 137 | 0x80058 138 | 0x78 139 | 22 140 | 2,2 141 | 3 142 | 0x80043 143 | 0x63 144 | 0xE7 145 | 23 146 | 2,3 147 | 2 148 | 0x80056 149 | 0x76 150 | 24 151 | 2,4 152 | 2 153 | 0x80042 154 | 0x62 155 | 25 156 | 2,5 157 | 2 158 | 0x8004E 159 | 0x6E 160 | 26 161 | 2,6 162 | 2 163 | 0x8004D 164 | 0x6D 165 | -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Lang/v2_keymap1.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 7 6 | 3 7 | 1 8 | 1 9 | 26 10 | 1 11 | 0,0 12 | 2 13 | 0x80051 14 | 0x71 15 | 2 16 | 0,1 17 | 2 18 | 0x80057 19 | 0x77 20 | 3 21 | 0,2 22 | 6 23 | 0x80045 24 | 0x65 25 | 0xE9 26 | 0xE8 27 | 0xEA 28 | 0xEB 29 | 4 30 | 0,3 31 | 2 32 | 0x80052 33 | 0x72 34 | 5 35 | 0,4 36 | 2 37 | 0x80054 38 | 0x74 39 | 6 40 | 0,5 41 | 3 42 | 0x80059 43 | 0x79 44 | 0xFF 45 | 7 46 | 0,6 47 | 6 48 | 0x80055 49 | 0x75 50 | 0xFA 51 | 0xF9 52 | 0xFB 53 | 0xFC 54 | 8 55 | 0,7 56 | 6 57 | 0x80049 58 | 0x69 59 | 0xED 60 | 0xEC 61 | 0xEE 62 | 0xEF 63 | 9 64 | 0,8 65 | 7 66 | 0x8004F 67 | 0x6F 68 | 0xF3 69 | 0xF2 70 | 0xF4 71 | 0xF6 72 | 0x153 73 | 10 74 | 0,9 75 | 2 76 | 0x80050 77 | 0x70 78 | 11 79 | 1,0 80 | 7 81 | 0x80041 82 | 0x61 83 | 0xE1 84 | 0xE0 85 | 0xE2 86 | 0xE6 87 | 0xE4 88 | 12 89 | 1,1 90 | 3 91 | 0x80053 92 | 0x73 93 | 0xDF 94 | 13 95 | 1,2 96 | 2 97 | 0x80044 98 | 0x64 99 | 14 100 | 1,3 101 | 2 102 | 0x80046 103 | 0x66 104 | 15 105 | 1,4 106 | 2 107 | 0x80047 108 | 0x67 109 | 16 110 | 1,5 111 | 2 112 | 0x80048 113 | 0x68 114 | 17 115 | 1,6 116 | 2 117 | 0x8004A 118 | 0x6A 119 | 18 120 | 1,7 121 | 2 122 | 0x8004B 123 | 0x6B 124 | 19 125 | 1,8 126 | 2 127 | 0x8004C 128 | 0x6C 129 | 20 130 | 2,0 131 | 2 132 | 0x8005A 133 | 0x7A 134 | 21 135 | 2,1 136 | 2 137 | 0x80058 138 | 0x78 139 | 22 140 | 2,2 141 | 3 142 | 0x80043 143 | 0x63 144 | 0xE7 145 | 23 146 | 2,3 147 | 2 148 | 0x80056 149 | 0x76 150 | 24 151 | 2,4 152 | 2 153 | 0x80042 154 | 0x62 155 | 25 156 | 2,5 157 | 2 158 | 0x8004E 159 | 0x6E 160 | 26 161 | 2,6 162 | 2 163 | 0x8004D 164 | 0x6D 165 | -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Profile.ata: -------------------------------------------------------------------------------- 1 | [PROFILEVER] 2 | 1 3 | -------------------------------------------------------------------------------- /octopuscore/ATXProfile/Profile.ata.bak: -------------------------------------------------------------------------------- 1 | [PROFILEVER] 2 | 1 3 | [DICTNAME] 4 | enggb 5 | -------------------------------------------------------------------------------- /octopuscore/ATXProfile/cmplst.dat: -------------------------------------------------------------------------------- 1 | RGMCN -------------------------------------------------------------------------------- /octopuscore/ATXProfile/language.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfile/language.bin -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/ConfigSettings.dat: -------------------------------------------------------------------------------- 1 | 1 2 | [SuggConfig_fieldMask] 3 | FF1 4 | [SuggConfig_maxNumSuggestions] 5 | 14 6 | [SuggConfig_numElisionCompletions] 7 | 0 8 | [SuggConfig_suggestionThreshold] 9 | 0 10 | [SuggConfig_proximitySuggestionOn] 11 | 0 12 | [SuggConfig_errorCorrectionOn] 13 | 0 14 | [SuggConfig_completionOn] 15 | 1 16 | [SuggConfig_useStoredCaps] 17 | 1 18 | [SuggConfig_forceLower] 19 | 0 20 | [SuggConfig_forceUpper] 21 | 0 22 | [SuggConfig_useSentenceCase] 23 | 1 24 | [SuggConfig_honourUserCaps] 25 | 1 26 | [InpMgrConfig_fieldMask] 27 | 1 28 | [InpMgrConfig_mergeCRLFOn] 29 | 1 30 | [LearnConfig_options] 31 | 1 32 | -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/User_0.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/User_0.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/User_1.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/User_1.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/User_2.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/User_2.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/czecz_1.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/czecz_1.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/czecz_2.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/czecz_2.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/enggb_0.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/enggb_0.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/enggb_1.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/enggb_1.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Context/enggb_2.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Context/enggb_2.atc -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Default_Profile.ata: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Default_Profile.ata -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/User.atu: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/User.atu -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/czecz.abn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/czecz.abn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/czecz.atd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/czecz.atd -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/czecz001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/czecz001.atn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/czecz_v2_keymap0001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/czecz_v2_keymap0001.atn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/enggb.abn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/enggb.abn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/enggb.atd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/enggb.atd -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/enggb001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/enggb001.atn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/enggb_v2_keymap0001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/enggb_v2_keymap0001.atn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Dictionaries/enggb_v2_keymap1001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Dictionaries/enggb_v2_keymap1001.atn -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/KPTUnicodeData.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/KPTUnicodeData.bin -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Lang/api_kmp_en-GB_KPTTestManu_KPTTestDev.atz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/Lang/api_kmp_en-GB_KPTTestManu_KPTTestDev.atz -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Lang/v2_keymap0.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 7 6 | 3 7 | 1 8 | 1 9 | 26 10 | 1 11 | 0,0 12 | 2 13 | 0x80051 14 | 0x71 15 | 2 16 | 0,1 17 | 2 18 | 0x80057 19 | 0x77 20 | 3 21 | 0,2 22 | 6 23 | 0x80045 24 | 0x65 25 | 0xE9 26 | 0xE8 27 | 0xEA 28 | 0xEB 29 | 4 30 | 0,3 31 | 2 32 | 0x80052 33 | 0x72 34 | 5 35 | 0,4 36 | 2 37 | 0x80054 38 | 0x74 39 | 6 40 | 0,5 41 | 3 42 | 0x80059 43 | 0x79 44 | 0xFF 45 | 7 46 | 0,6 47 | 6 48 | 0x80055 49 | 0x75 50 | 0xFA 51 | 0xF9 52 | 0xFB 53 | 0xFC 54 | 8 55 | 0,7 56 | 6 57 | 0x80049 58 | 0x69 59 | 0xED 60 | 0xEC 61 | 0xEE 62 | 0xEF 63 | 9 64 | 0,8 65 | 7 66 | 0x8004F 67 | 0x6F 68 | 0xF3 69 | 0xF2 70 | 0xF4 71 | 0xF6 72 | 0x153 73 | 10 74 | 0,9 75 | 2 76 | 0x80050 77 | 0x70 78 | 11 79 | 1,0 80 | 7 81 | 0x80041 82 | 0x61 83 | 0xE1 84 | 0xE0 85 | 0xE2 86 | 0xE6 87 | 0xE4 88 | 12 89 | 1,1 90 | 3 91 | 0x80053 92 | 0x73 93 | 0xDF 94 | 13 95 | 1,2 96 | 2 97 | 0x80044 98 | 0x64 99 | 14 100 | 1,3 101 | 2 102 | 0x80046 103 | 0x66 104 | 15 105 | 1,4 106 | 2 107 | 0x80047 108 | 0x67 109 | 16 110 | 1,5 111 | 2 112 | 0x80048 113 | 0x68 114 | 17 115 | 1,6 116 | 2 117 | 0x8004A 118 | 0x6A 119 | 18 120 | 1,7 121 | 2 122 | 0x8004B 123 | 0x6B 124 | 19 125 | 1,8 126 | 2 127 | 0x8004C 128 | 0x6C 129 | 20 130 | 2,0 131 | 2 132 | 0x8005A 133 | 0x7A 134 | 21 135 | 2,1 136 | 2 137 | 0x80058 138 | 0x78 139 | 22 140 | 2,2 141 | 3 142 | 0x80043 143 | 0x63 144 | 0xE7 145 | 23 146 | 2,3 147 | 2 148 | 0x80056 149 | 0x76 150 | 24 151 | 2,4 152 | 2 153 | 0x80042 154 | 0x62 155 | 25 156 | 2,5 157 | 2 158 | 0x8004E 159 | 0x6E 160 | 26 161 | 2,6 162 | 2 163 | 0x8004D 164 | 0x6D 165 | -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Lang/v2_keymap1.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 7 6 | 3 7 | 1 8 | 1 9 | 26 10 | 1 11 | 0,0 12 | 2 13 | 0x80051 14 | 0x71 15 | 2 16 | 0,1 17 | 2 18 | 0x80057 19 | 0x77 20 | 3 21 | 0,2 22 | 6 23 | 0x80045 24 | 0x65 25 | 0xE9 26 | 0xE8 27 | 0xEA 28 | 0xEB 29 | 4 30 | 0,3 31 | 2 32 | 0x80052 33 | 0x72 34 | 5 35 | 0,4 36 | 2 37 | 0x80054 38 | 0x74 39 | 6 40 | 0,5 41 | 3 42 | 0x80059 43 | 0x79 44 | 0xFF 45 | 7 46 | 0,6 47 | 6 48 | 0x80055 49 | 0x75 50 | 0xFA 51 | 0xF9 52 | 0xFB 53 | 0xFC 54 | 8 55 | 0,7 56 | 6 57 | 0x80049 58 | 0x69 59 | 0xED 60 | 0xEC 61 | 0xEE 62 | 0xEF 63 | 9 64 | 0,8 65 | 7 66 | 0x8004F 67 | 0x6F 68 | 0xF3 69 | 0xF2 70 | 0xF4 71 | 0xF6 72 | 0x153 73 | 10 74 | 0,9 75 | 2 76 | 0x80050 77 | 0x70 78 | 11 79 | 1,0 80 | 7 81 | 0x80041 82 | 0x61 83 | 0xE1 84 | 0xE0 85 | 0xE2 86 | 0xE6 87 | 0xE4 88 | 12 89 | 1,1 90 | 3 91 | 0x80053 92 | 0x73 93 | 0xDF 94 | 13 95 | 1,2 96 | 2 97 | 0x80044 98 | 0x64 99 | 14 100 | 1,3 101 | 2 102 | 0x80046 103 | 0x66 104 | 15 105 | 1,4 106 | 2 107 | 0x80047 108 | 0x67 109 | 16 110 | 1,5 111 | 2 112 | 0x80048 113 | 0x68 114 | 17 115 | 1,6 116 | 2 117 | 0x8004A 118 | 0x6A 119 | 18 120 | 1,7 121 | 2 122 | 0x8004B 123 | 0x6B 124 | 19 125 | 1,8 126 | 2 127 | 0x8004C 128 | 0x6C 129 | 20 130 | 2,0 131 | 2 132 | 0x8005A 133 | 0x7A 134 | 21 135 | 2,1 136 | 2 137 | 0x80058 138 | 0x78 139 | 22 140 | 2,2 141 | 3 142 | 0x80043 143 | 0x63 144 | 0xE7 145 | 23 146 | 2,3 147 | 2 148 | 0x80056 149 | 0x76 150 | 24 151 | 2,4 152 | 2 153 | 0x80042 154 | 0x62 155 | 25 156 | 2,5 157 | 2 158 | 0x8004E 159 | 0x6E 160 | 26 161 | 2,6 162 | 2 163 | 0x8004D 164 | 0x6D 165 | -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/Profile.ata: -------------------------------------------------------------------------------- 1 | [PROFILEVER] 2 | 1 3 | [DICTNAME] 4 | enggb 5 | -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/atxspchr.txt: -------------------------------------------------------------------------------- 1 | 0x1a 2 | 0x0061 3 | 0x14 4 | 0x00e0 5 | 0x00e1 6 | 0x00e2 7 | 0x00e3 8 | 0x00e4 9 | 0x00e5 10 | 0x00e6 11 | 0x0101 12 | 0x0103 13 | 0x0105 14 | 0x1ea1 15 | 0x1ea3 16 | 0x1ea5 17 | 0x1ea9 18 | 0x1eab 19 | 0x1ead 20 | 0x1eaf 21 | 0x1eb3 22 | 0x1eb5 23 | 0x1eb7 24 | 0x0063 25 | 0x3 26 | 0x00e7 27 | 0x0107 28 | 0x010d 29 | 0x0064 30 | 0x3 31 | 0x010f 32 | 0x0111 33 | 0x00f0 34 | 0x0065 35 | 0xf 36 | 0x00e8 37 | 0x00e9 38 | 0x00ea 39 | 0x00eb 40 | 0x0113 41 | 0x0117 42 | 0x0119 43 | 0x011b 44 | 0x0451 45 | 0x1eb9 46 | 0x1ebb 47 | 0x1ebf 48 | 0x1ec3 49 | 0x1ec5 50 | 0x1ec7 51 | 0x0067 52 | 0x2 53 | 0x011f 54 | 0x0123 55 | 0x0069 56 | 0xc 57 | 0x00ec 58 | 0x00ed 59 | 0x00ee 60 | 0x00ef 61 | 0x0129 62 | 0x012b 63 | 0x012f 64 | 0x0131 65 | 0x0456 66 | 0x0457 67 | 0x1ecb 68 | 0x1ec9 69 | 0x006b 70 | 0x1 71 | 0x0137 72 | 0x006c 73 | 0x4 74 | 0x013a 75 | 0x013c 76 | 0x013e 77 | 0x0142 78 | 0x006e 79 | 0x4 80 | 0x00f1 81 | 0x0144 82 | 0x0146 83 | 0x0148 84 | 0x006f 85 | 0x13 86 | 0x00f2 87 | 0x00f3 88 | 0x00f4 89 | 0x00f5 90 | 0x00f6 91 | 0x00f8 92 | 0x01a1 93 | 0x0151 94 | 0x0153 95 | 0x1ecd 96 | 0x1ecf 97 | 0x1ed1 98 | 0x1ed5 99 | 0x1ed7 100 | 0x1ed9 101 | 0x1edb 102 | 0x1edd 103 | 0x1ee1 104 | 0x1ee3 105 | 0x0072 106 | 0x2 107 | 0x0155 108 | 0x0159 109 | 0x0073 110 | 0x4 111 | 0x015b 112 | 0x015f 113 | 0x0161 114 | 0x00df 115 | 0x0074 116 | 0x3 117 | 0x00fe 118 | 0x0163 119 | 0x0165 120 | 0x0075 121 | 0xf 122 | 0x00f9 123 | 0x00fa 124 | 0x00fb 125 | 0x00fc 126 | 0x016b 127 | 0x016f 128 | 0x0171 129 | 0x0173 130 | 0x01b0 131 | 0x1ee5 132 | 0x1ee7 133 | 0x1ee9 134 | 0x1eed 135 | 0x1eef 136 | 0x1ef1 137 | 0x0079 138 | 0x6 139 | 0x00fd 140 | 0x1ef3 141 | 0x1ef5 142 | 0x1ef7 143 | 0x1ef9 144 | 0x00ff 145 | 0x007a 146 | 0x3 147 | 0x017a 148 | 0x017c 149 | 0x017e 150 | 0x043b 151 | 0x1 152 | 0x0459 153 | 0x043d 154 | 0x1 155 | 0x045a 156 | 0x0433 157 | 0x1 158 | 0x0491 159 | 0x03b1 160 | 0x1 161 | 0x03ac 162 | 0x03b5 163 | 0x1 164 | 0x03ad 165 | 0x03b7 166 | 0x1 167 | 0x03ae 168 | 0x03b9 169 | 0x3 170 | 0x03af 171 | 0x03ca 172 | 0x0390 173 | 0x03c5 174 | 0x3 175 | 0x03cd 176 | 0x03cb 177 | 0x03b0 178 | 0x03bf 179 | 0x1 180 | 0x03cc 181 | 0x03c9 182 | 0x1 183 | 0x03ce 184 | 0x16 185 | 0x0061 186 | 0x0065 187 | 0x0068 188 | 0x0069 189 | 0x006f 190 | 0x0075 191 | 0x0079 192 | 0x00e0 193 | 0x00e1 194 | 0x00e8 195 | 0x00e9 196 | 0x00ea 197 | 0x00eb 198 | 0x00ec 199 | 0x00ee 200 | 0x00ef 201 | 0x00f2 202 | 0x00f4 203 | 0x00f9 204 | 0x00fb 205 | 0x00fc 206 | 0x0153 207 | -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/cmplst.dat: -------------------------------------------------------------------------------- 1 | RGMCN   -------------------------------------------------------------------------------- /octopuscore/ATXProfileBig/language.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/ATXProfileBig/language.bin -------------------------------------------------------------------------------- /octopuscore/KPTAPIUserGuide.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/KPTAPIUserGuide.pdf -------------------------------------------------------------------------------- /octopuscore/Makefile: -------------------------------------------------------------------------------- 1 | GO_EASY_ON_ME=1 2 | #DEBUG = 1 3 | NO_RESPRING = 1 4 | 5 | export TARGET=iphone:latest:5.0 6 | export ARCHS = armv7 7 | 8 | include theos/makefiles/common.mk 9 | 10 | TOOL_NAME = octopusd 11 | octopusd_FILES = OctopusDaemon/main.mm OctopusDaemon/TextInput.mm OctopusDaemon/Layouts.mm OctopusDaemon/octopusServer.c OctopusDaemon/octopusUser.c OctopusDaemon/examples.mm 12 | octopusd_FRAMEWORKS = AddressBook 13 | octopusd_CFLAGS = -g0 -fvisibility=hidden -Wno-multichar -DIOS=1 -I. -I../include -I../include/pal -I../include/pal/android -I../include/kptapi -I../include/kptapi/android 14 | octopusd_LDFLAGS = -Wl,-s -Xlinker -s -L../lib -lkpt -lsqlite3 15 | 16 | include $(THEOS_MAKE_PATH)/tool.mk 17 | 18 | before-all:: 19 | 20 | OctopusDaemon/octopusServer.c: OctopusDaemon/octopus.defs 21 | echo "Compiling MIG..." 22 | mig -header OctopusDaemon/octopus.h -server OctopusDaemon/octopusServer.c -user OctopusDaemon/octopusUser.c OctopusDaemon/octopus.defs 23 | 24 | test: distclean package install 25 | ssh ufoxy "killall octopusd" 26 | 27 | distclean: 28 | rm *.deb || true 29 | 30 | -------------------------------------------------------------------------------- /octopuscore/OctopusDaemon.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /octopuscore/OctopusDaemon/AntiGDB.h: -------------------------------------------------------------------------------- 1 | // 2 | // AntiGDB.h 3 | // 4 | // Created by K3A on 2/9/12. 5 | // Copyright (c) 2012 K3A. All rights reserved. 6 | // 7 | #pragma once 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | 19 | static __attribute__((always_inline)) bool gdb_disable(){return true;}; 20 | static __attribute__((always_inline)) bool gdb_check(bool terminateIfYes=true){return false;}; 21 | -------------------------------------------------------------------------------- /octopuscore/OctopusDaemon/Layouts.h: -------------------------------------------------------------------------------- 1 | // 2 | // Layouts.h 3 | // OctopusDaemon 4 | // 5 | // Created by K3A on 5/20/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #ifndef OctopusDaemon_Layouts_h 10 | #define OctopusDaemon_Layouts_h 11 | 12 | #include // size_t etc 13 | #include 14 | #include 15 | 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | 22 | extern const struct KPTKeyMapLayoutT s_layout_iphone_en_US; 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /octopuscore/OctopusDaemon/examples.h: -------------------------------------------------------------------------------- 1 | // 2 | // examples.h 3 | // CoreRegressSystem 4 | // 5 | // Created by K3A on 5/19/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #ifndef CoreRegressSystem_examples_h 10 | #define CoreRegressSystem_examples_h 11 | 12 | #include // uint8_t etc 13 | #include "kptresult.h" 14 | 15 | KPTResultT 16 | Example_KPTCMD_SUGGS_GETSUGGESTIONS(void); 17 | 18 | KPTResultT 19 | Example_KPTCMD_KEYMAP_GETAVAILABLE(void); 20 | 21 | KPTResultT 22 | Example_KPTCMD_COMPONENT_GETAVAILABLE(void); 23 | 24 | KPTResultT 25 | Example_KPTCMD_KEYMAP_GETLAYOUT(void); 26 | 27 | KPTResultT 28 | Example_KPTCMD_KEYMAP_QUERY(void); 29 | 30 | KPTResultT 31 | Example_KPTCMD_ERROR_POPSTACK(void); 32 | 33 | KPTResultT 34 | Example_KPTCMD_DICTIONARY_GETLANGLIST(void); 35 | 36 | KPTResultT 37 | Example_KPTCMD_DICTIONARY_GETLIST(void); 38 | 39 | KPTResultT 40 | Example_KPTCMD_INPUTMGR_GETCURRWORD(void); 41 | 42 | #endif 43 | -------------------------------------------------------------------------------- /octopuscore/OctopusDaemon/main.h: -------------------------------------------------------------------------------- 1 | // 2 | // main.h 3 | // OctopusDaemon 4 | // 5 | // Created by K3A on 5/23/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #ifndef OctopusDaemon_main_h 10 | #define OctopusDaemon_main_h 11 | 12 | #import 13 | 14 | #define PREF_FILE "/var/mobile/Library/Preferences/me.k3a.OctopusKeyboard.plist" 15 | BOOL prefsLoad(); 16 | NSString* prefString(NSString* key, NSString* def=@""); 17 | int prefInt(NSString* key, int def=0); 18 | 19 | void OLog(int level, const char* format, ...); 20 | void OErr(const char* format, ...); 21 | 22 | #endif 23 | -------------------------------------------------------------------------------- /octopuscore/OctopusTest/main.cpp: -------------------------------------------------------------------------------- 1 | // 2 | // main.cpp 3 | // OctopusTest 4 | // 5 | // Created by K3A on 5/20/12. 6 | // Copyright (c) 2012 K3A. All rights reserved. 7 | // 8 | 9 | #include 10 | #include 11 | 12 | #include "octopus.h" 13 | #include 14 | 15 | int main (int argc, const char * argv[]) 16 | { 17 | printf("Client Test\n"); 18 | 19 | kern_return_t kr; 20 | mach_port_t server_port; 21 | 22 | // look up the service to find the server's port 23 | if ((kr = bootstrap_look_up(bootstrap_port, OCTOPUS_SERVICE, 24 | &server_port)) != BOOTSTRAP_SUCCESS) { 25 | mach_error("bootstrap_look_up:", kr); 26 | exit(1); 27 | } 28 | 29 | string_t str; 30 | kr = hello(server_port, str); 31 | printf("RESP: '%s'\n", str); 32 | 33 | mach_port_deallocate(mach_task_self(), server_port); 34 | 35 | return 0; 36 | } 37 | 38 | -------------------------------------------------------------------------------- /octopuscore/layout/DEBIAN/control: -------------------------------------------------------------------------------- 1 | Package: k3a.me.octopusd 2 | Name: OctopusDaemon 3 | Depends: 4 | Version: 0.0.1 5 | Architecture: iphoneos-arm 6 | Description: Daemon for Octopus Keyboard 7 | Maintainer: K3A 8 | Author: K3A 9 | Section: System 10 | -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/ConfigSettings.dat: -------------------------------------------------------------------------------- 1 | 1 2 | [SuggConfig_fieldMask] 3 | FF1 4 | [SuggConfig_maxNumSuggestions] 5 | 8 6 | [SuggConfig_numElisionCompletions] 7 | 0 8 | [SuggConfig_suggestionThreshold] 9 | 2 10 | [SuggConfig_proximitySuggestionOn] 11 | 1 12 | [SuggConfig_errorCorrectionOn] 13 | 1 14 | [SuggConfig_completionOn] 15 | 1 16 | [SuggConfig_useStoredCaps] 17 | 1 18 | [SuggConfig_forceLower] 19 | 0 20 | [SuggConfig_forceUpper] 21 | 0 22 | [SuggConfig_useSentenceCase] 23 | 0 24 | [SuggConfig_honourUserCaps] 25 | 1 26 | [InpMgrConfig_fieldMask] 27 | 1 28 | [InpMgrConfig_mergeCRLFOn] 29 | 1 30 | [LearnConfig_options] 31 | 1 32 | -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_0.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_0.atc -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_1.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_1.atc -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_2.atc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Context/engus_2.atc -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Default_Profile.ata: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Default_Profile.ata -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus.abn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus.abn -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus.atd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus.atd -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus001.atn -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus_v2_keymap0001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus_v2_keymap0001.atn -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus_v2_keymap1001.atn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/Dictionaries/engus_v2_keymap1001.atn -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/KPTUnicodeData.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/KPTUnicodeData.bin -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Lang/v2_keymap0.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 7 6 | 3 7 | 1 8 | 1 9 | 26 10 | 1 11 | 0,0 12 | 2 13 | 0x80051 14 | 0x71 15 | 2 16 | 0,1 17 | 2 18 | 0x80057 19 | 0x77 20 | 3 21 | 0,2 22 | 6 23 | 0x80045 24 | 0x65 25 | 0xE9 26 | 0xE8 27 | 0xEA 28 | 0xEB 29 | 4 30 | 0,3 31 | 2 32 | 0x80052 33 | 0x72 34 | 5 35 | 0,4 36 | 2 37 | 0x80054 38 | 0x74 39 | 6 40 | 0,5 41 | 3 42 | 0x80059 43 | 0x79 44 | 0xFF 45 | 7 46 | 0,6 47 | 6 48 | 0x80055 49 | 0x75 50 | 0xFA 51 | 0xF9 52 | 0xFB 53 | 0xFC 54 | 8 55 | 0,7 56 | 6 57 | 0x80049 58 | 0x69 59 | 0xED 60 | 0xEC 61 | 0xEE 62 | 0xEF 63 | 9 64 | 0,8 65 | 7 66 | 0x8004F 67 | 0x6F 68 | 0xF3 69 | 0xF2 70 | 0xF4 71 | 0xF6 72 | 0x153 73 | 10 74 | 0,9 75 | 2 76 | 0x80050 77 | 0x70 78 | 11 79 | 1,0 80 | 7 81 | 0x80041 82 | 0x61 83 | 0xE1 84 | 0xE0 85 | 0xE2 86 | 0xE6 87 | 0xE4 88 | 12 89 | 1,1 90 | 3 91 | 0x80053 92 | 0x73 93 | 0xDF 94 | 13 95 | 1,2 96 | 2 97 | 0x80044 98 | 0x64 99 | 14 100 | 1,3 101 | 2 102 | 0x80046 103 | 0x66 104 | 15 105 | 1,4 106 | 2 107 | 0x80047 108 | 0x67 109 | 16 110 | 1,5 111 | 2 112 | 0x80048 113 | 0x68 114 | 17 115 | 1,6 116 | 2 117 | 0x8004A 118 | 0x6A 119 | 18 120 | 1,7 121 | 2 122 | 0x8004B 123 | 0x6B 124 | 19 125 | 1,8 126 | 2 127 | 0x8004C 128 | 0x6C 129 | 20 130 | 2,0 131 | 2 132 | 0x8005A 133 | 0x7A 134 | 21 135 | 2,1 136 | 2 137 | 0x80058 138 | 0x78 139 | 22 140 | 2,2 141 | 3 142 | 0x80043 143 | 0x63 144 | 0xE7 145 | 23 146 | 2,3 147 | 2 148 | 0x80056 149 | 0x76 150 | 24 151 | 2,4 152 | 2 153 | 0x80042 154 | 0x62 155 | 25 156 | 2,5 157 | 2 158 | 0x8004E 159 | 0x6E 160 | 26 161 | 2,6 162 | 2 163 | 0x8004D 164 | 0x6D 165 | -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Lang/v2_keymap1.atm: -------------------------------------------------------------------------------- 1 | 5 2 | API-Converted 3 | 0x00000000 4 | 0 5 | 11 6 | 3 7 | 1 8 | 1 9 | 27 10 | 1 11 | 0,11 12 | 2 13 | 0x80071 14 | 0x71 15 | 2 16 | 32,11 17 | 2 18 | 0x80077 19 | 0x77 20 | 3 21 | 64,11 22 | 9 23 | 0x90065 24 | 0x65 25 | 0x1C3A8 26 | 0x1C3A9 27 | 0x1C3AA 28 | 0x1C3AB 29 | 0x1C493 30 | 0x1C497 31 | 0x1C499 32 | 4 33 | 96,11 34 | 2 35 | 0x80072 36 | 0x72 37 | 5 38 | 128,11 39 | 2 40 | 0x80074 41 | 0x74 42 | 6 43 | 160,11 44 | 3 45 | 0x90079 46 | 0x79 47 | 0x1C5B8 48 | 7 49 | 192,11 50 | 7 51 | 0x90075 52 | 0x75 53 | 0x1C3BB 54 | 0x1C3BC 55 | 0x1C3B9 56 | 0x1C3BA 57 | 0x1C5AB 58 | 8 59 | 224,11 60 | 8 61 | 0x90069 62 | 0x69 63 | 0x1C3AE 64 | 0x1C3AF 65 | 0x1C3AD 66 | 0x1C4AB 67 | 0x1C4AF 68 | 0x1C3AC 69 | 9 70 | 256,11 71 | 11 72 | 0x9006F 73 | 0x6F 74 | 0x1C3B4 75 | 0x1C3B6 76 | 0x1C3B2 77 | 0x1C3B2 78 | 0x1C3B3 79 | 0x1C593 80 | 0x1C3B8 81 | 0x1C58D 82 | 0x1C3B5 83 | 10 84 | 288,11 85 | 2 86 | 0x80070 87 | 0x70 88 | 11 89 | 17,65 90 | 10 91 | 0x90061 92 | 0x61 93 | 0x1C3A0 94 | 0x1C3A1 95 | 0x1C3A2 96 | 0x1C3A4 97 | 0x1C3A6 98 | 0x1C3A3 99 | 0x1C3A5 100 | 0x1C481 101 | 12 102 | 48,65 103 | 5 104 | 0x90073 105 | 0x73 106 | 0x1C39F 107 | 0x1C59B 108 | 0x1C5A1 109 | 13 110 | 80,65 111 | 2 112 | 0x80064 113 | 0x64 114 | 14 115 | 112,65 116 | 2 117 | 0x80066 118 | 0x66 119 | 15 120 | 144,65 121 | 2 122 | 0x80067 123 | 0x67 124 | 16 125 | 176,65 126 | 2 127 | 0x80068 128 | 0x68 129 | 17 130 | 208,65 131 | 2 132 | 0x8006A 133 | 0x6A 134 | 18 135 | 240,65 136 | 2 137 | 0x8006B 138 | 0x6B 139 | 19 140 | 272,65 141 | 3 142 | 0x9006C 143 | 0x6C 144 | 0x1C582 145 | 20 146 | 48,119 147 | 5 148 | 0x9007A 149 | 0x7A 150 | 0x1C5BE 151 | 0x1C5BA 152 | 0x1C5BC 153 | 21 154 | 80,119 155 | 2 156 | 0x80078 157 | 0x78 158 | 22 159 | 112,119 160 | 5 161 | 0x90063 162 | 0x63 163 | 0x1C3A7 164 | 0x1C487 165 | 0x1C48D 166 | 23 167 | 144,119 168 | 2 169 | 0x80076 170 | 0x76 171 | 24 172 | 176,119 173 | 2 174 | 0x80062 175 | 0x62 176 | 25 177 | 208,119 178 | 4 179 | 0x9006E 180 | 0x6E 181 | 0x1C3B1 182 | 0x1C584 183 | 26 184 | 240,119 185 | 2 186 | 0x8006D 187 | 0x6D 188 | 27 189 | 120,173 190 | 2 191 | 0x80020 192 | 0x20 193 | -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/Profile.ata: -------------------------------------------------------------------------------- 1 | [PROFILEVER] 2 | 1 3 | [DICTNAME] 4 | enggb 5 | -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/cmplst.dat: -------------------------------------------------------------------------------- 1 | RGMCN -------------------------------------------------------------------------------- /octopuscore/layout/Library/Application Support/OctopusKeyboard/language.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/layout/Library/Application Support/OctopusKeyboard/language.bin -------------------------------------------------------------------------------- /octopuscore/layout/System/Library/LaunchDaemons/me.k3a.octopusd.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | KeepAlive 6 | 7 | RunAtLoad 8 | 9 | EnvironmentVariables 10 | 11 | DYLD_INSERT_LIBRARIES 12 | 13 | 14 | Label 15 | me.k3a.octopusd 16 | ProgramArguments 17 | 18 | /usr/bin/octopusd 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /octopuscore/mig_manual.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/k3a/OctopusKeyboard/b60998ca6e31bc187c115c441947b62a0b7ca8ff/octopuscore/mig_manual.pdf -------------------------------------------------------------------------------- /octopuscore/theos: -------------------------------------------------------------------------------- 1 | /opt/theos -------------------------------------------------------------------------------- /theos: -------------------------------------------------------------------------------- 1 | /theos --------------------------------------------------------------------------------