rhoconnect-client 5.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/CHANGELOG.md +9 -0
- data/CREDITS +0 -0
- data/LICENSE +9 -0
- data/README.md +47 -0
- data/ext/rhoconnect-client/RhoConnectClient.rb +190 -0
- data/ext/rhoconnect-client/ext/RhoConnectClient.xml +726 -0
- data/ext/rhoconnect-client/ext/build +26 -0
- data/ext/rhoconnect-client/ext/build.bat +30 -0
- data/ext/rhoconnect-client/ext/platform/android/ext_java.files +1 -0
- data/ext/rhoconnect-client/ext/platform/android/ext_native.files +14 -0
- data/ext/rhoconnect-client/ext/platform/android/src/com/rhoconnectclient/RhoconnectClient.java +1 -0
- data/ext/rhoconnect-client/ext/platform/iphone/.gitignore +1 -0
- data/ext/rhoconnect-client/ext/platform/iphone/Rakefile +74 -0
- data/ext/rhoconnect-client/ext/platform/iphone/RhoconnectClient.xcodeproj/project.pbxproj +390 -0
- data/ext/rhoconnect-client/ext/platform/iphone/RhoconnectClient_Prefix.pch +7 -0
- data/ext/rhoconnect-client/ext/platform/iphone/impl/readme.txt +7 -0
- data/ext/rhoconnect-client/ext/platform/qt/Rakefile +35 -0
- data/ext/rhoconnect-client/ext/platform/qt/rhoconnect-client.pro +88 -0
- data/ext/rhoconnect-client/ext/platform/wm/Rhoconnect-client.sln +36 -0
- data/ext/rhoconnect-client/ext/platform/wm/Rhoconnect-client.vcproj +774 -0
- data/ext/rhoconnect-client/ext/platform/wm/Rhoconnect-client.vsprops +15 -0
- data/ext/rhoconnect-client/ext/platform/wm/src/rhoconnectclient_wm.cpp +40 -0
- data/ext/rhoconnect-client/ext/platform/wm/src/rhoconnectclient_wm.h +2 -0
- data/ext/rhoconnect-client/ext/platform/wp8/Rhoconnect-client.props +22 -0
- data/ext/rhoconnect-client/ext/platform/wp8/Rhoconnect-client.sln +32 -0
- data/ext/rhoconnect-client/ext/platform/wp8/Rhoconnect-client.vcxproj +220 -0
- data/ext/rhoconnect-client/ext/platform/wp8/Rhoconnect-client.vcxproj.filters +103 -0
- data/ext/rhoconnect-client/ext/shared/RhoConnectClientImpl.cpp +273 -0
- data/ext/rhoconnect-client/ext/shared/RhoConnectClientImpl.h +60 -0
- data/ext/rhoconnect-client/ext/shared/RhoConnectClientSingletonImpl.h +53 -0
- data/ext/rhoconnect-client/ext/shared/initRhoconnectClient.cpp +207 -0
- data/ext/rhoconnect-client/ext/shared/rhoconnectclient.c +18 -0
- data/ext/rhoconnect-client/ext/shared/sync/ClientRegister.cpp +398 -0
- data/ext/rhoconnect-client/ext/shared/sync/ClientRegister.h +147 -0
- data/ext/rhoconnect-client/ext/shared/sync/ISyncProtocol.h +91 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncEngine.cpp +1245 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncEngine.h +213 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncNotify.cpp +737 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncNotify.h +209 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncProtocol_3.h +220 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncProtocol_4.h +259 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncSource.cpp +1694 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncSource.h +212 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncThread.cpp +583 -0
- data/ext/rhoconnect-client/ext/shared/sync/SyncThread.h +250 -0
- data/ext/rhoconnect-client/ext.yml +12 -0
- data/lib/build/run_rhoconnect_spec.rb +135 -0
- data/lib/rhoconnect-client.rb +3 -0
- data/platform/shared/RhoConnectClient/RhoConnectClient.cpp +1673 -0
- data/platform/shared/RhoConnectClient/RhoConnectClient.h +181 -0
- data/platform/shared/RhoConnectClient/RhoError.h +77 -0
- data/rhoconnect-client/C++/Tests/RhoConnectClientTest.cpp +830 -0
- data/rhoconnect-client/C++/Tests/win32/.gitignore +3 -0
- data/rhoconnect-client/C++/Tests/win32/RhoConnectClient.sln +65 -0
- data/rhoconnect-client/C++/Tests/win32/RhoConnectClient.vcproj +634 -0
- data/rhoconnect-client/C++/Tests/win32/RhoConnectClientTest/RhoConnectClientTest.vcproj +222 -0
- data/rhoconnect-client/C++/Tests/win32/RhoConnectClientTest/stdafx.h +65 -0
- data/rhoconnect-client/C++/Tests/win32/stdafx.h +65 -0
- data/rhoconnect-client/CHANGELOG +18 -0
- data/rhoconnect-client/Java/Android/build/android.rake +387 -0
- data/rhoconnect-client/Java/Android/build/android_sdk.rb +582 -0
- data/rhoconnect-client/Java/Android/build/libcurl_build.files +73 -0
- data/rhoconnect-client/Java/Android/build/libjson_build.files +9 -0
- data/rhoconnect-client/Java/Android/build/librhocommon_build.files +14 -0
- data/rhoconnect-client/Java/Android/build/librhodb_build.files +5 -0
- data/rhoconnect-client/Java/Android/build/librhoimpl_build.files +13 -0
- data/rhoconnect-client/Java/Android/build/librholog_build.files +4 -0
- data/rhoconnect-client/Java/Android/build/libsqlite_build.files +1 -0
- data/rhoconnect-client/Java/Android/build/libsync_build.files +7 -0
- data/rhoconnect-client/Java/Android/build/libunzip_build.files +1 -0
- data/rhoconnect-client/Java/Android/build/rhoconnectclient_build.files +3 -0
- data/rhoconnect-client/Java/Android/build/rhoimpljava_build.files +21 -0
- data/rhoconnect-client/Java/Android/src/com/rhomobile/rhodes/Capabilities.java +63 -0
- data/rhoconnect-client/Java/Android/src/com/rhomobile/rhodes/MemoryInfoCollector.java +79 -0
- data/rhoconnect-client/Java/Android/src/com/rhomobile/rhodes/util/ContextFactory.java +63 -0
- data/rhoconnect-client/Java/Android/test/.classpath +9 -0
- data/rhoconnect-client/Java/Android/test/.project +33 -0
- data/rhoconnect-client/Java/Android/test/AndroidManifest.xml +14 -0
- data/rhoconnect-client/Java/Android/test/assets/apps/androidtest.png +0 -0
- data/rhoconnect-client/Java/Android/test/assets/apps/rhoconfig.txt +19 -0
- data/rhoconnect-client/Java/Android/test/assets/apps/rhoconfig.txt.timestamp +1 -0
- data/rhoconnect-client/Java/Android/test/assets/db/syncdb.schema +44 -0
- data/rhoconnect-client/Java/Android/test/assets/db/syncdb.triggers +10 -0
- data/rhoconnect-client/Java/Android/test/assets/db/syncdb_java.triggers +21 -0
- data/rhoconnect-client/Java/Android/test/assets/rho.dat +9 -0
- data/rhoconnect-client/Java/Android/test/proguard.cfg +36 -0
- data/rhoconnect-client/Java/Android/test/project.properties +11 -0
- data/rhoconnect-client/Java/Android/test/res/drawable-hdpi/icon.png +0 -0
- data/rhoconnect-client/Java/Android/test/res/drawable-ldpi/icon.png +0 -0
- data/rhoconnect-client/Java/Android/test/res/drawable-mdpi/icon.png +0 -0
- data/rhoconnect-client/Java/Android/test/res/layout/main.xml +12 -0
- data/rhoconnect-client/Java/Android/test/res/values/strings.xml +5 -0
- data/rhoconnect-client/Java/Android/test/rhoimpl.jar +0 -0
- data/rhoconnect-client/Java/Android/test/src/com/rhomobile/rhoconnect_client_test/TestRhoConnectClient.java +343 -0
- data/rhoconnect-client/Java/Android/test/src/com/rhomobile/rhoconnect_client_test/TestRhoConnectClientBlobs.java +219 -0
- data/rhoconnect-client/Java/RhoConnect/.classpath +6 -0
- data/rhoconnect-client/Java/RhoConnect/.project +93 -0
- data/rhoconnect-client/Java/RhoConnect/assets/apps/rhoconfig.txt +19 -0
- data/rhoconnect-client/Java/RhoConnect/assets/apps/rhoconfig.txt.timestamp +1 -0
- data/rhoconnect-client/Java/RhoConnect/assets/db/syncdb.schema +44 -0
- data/rhoconnect-client/Java/RhoConnect/assets/db/syncdb.triggers +10 -0
- data/rhoconnect-client/Java/RhoConnect/assets/db/syncdb_java.triggers +21 -0
- data/rhoconnect-client/Java/RhoConnect/assets/rho.dat +8 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/RhoConnectJniNotify.h +61 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhoConnectClient.h +181 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhoConnectNotify.h +13 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhoConnectNotify_IDelegate.h +13 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhoConnectObjectNotify.h +13 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhoConnectObjectNotify_IDelegate.h +13 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/com_rhomobile_rhoconnect_RhomModel.h +103 -0
- data/rhoconnect-client/Java/RhoConnect/jni/include/rhojava.inc +76 -0
- data/rhoconnect-client/Java/RhoConnect/jni/src/RhoConnectJniClient.cpp +401 -0
- data/rhoconnect-client/Java/RhoConnect/jni/src/RhoConnectJniModel.cpp +332 -0
- data/rhoconnect-client/Java/RhoConnect/jni/src/RhoConnectJniNotify.cpp +223 -0
- data/rhoconnect-client/Java/RhoConnect/jni/src/RhoConnectUtil.cpp +82 -0
- data/rhoconnect-client/Java/RhoConnect/jni/src/RhodesApp.cpp +114 -0
- data/rhoconnect-client/Java/RhoConnect/src/com/rhomobile/rhoconnect/RhoConnectClient.java +108 -0
- data/rhoconnect-client/Java/RhoConnect/src/com/rhomobile/rhoconnect/RhoConnectNotify.java +78 -0
- data/rhoconnect-client/Java/RhoConnect/src/com/rhomobile/rhoconnect/RhoConnectObjectNotify.java +71 -0
- data/rhoconnect-client/Java/RhoConnect/src/com/rhomobile/rhoconnect/RhomModel.java +195 -0
- data/rhoconnect-client/JavaScript/.classpath +10 -0
- data/rhoconnect-client/JavaScript/.gitignore +4 -0
- data/rhoconnect-client/JavaScript/.project +17 -0
- data/rhoconnect-client/JavaScript/README.textile +1 -0
- data/rhoconnect-client/JavaScript/build.xml +185 -0
- data/rhoconnect-client/JavaScript/doc/fsm-sample.js +44 -0
- data/rhoconnect-client/JavaScript/doc/fsm-sample.png +0 -0
- data/rhoconnect-client/JavaScript/src/RhoSyncJS.gwt.xml +21 -0
- data/rhoconnect-client/JavaScript/stubs/RhoSyncStubsJS.gwt.xml +21 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/Capabilities.java +7 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/IRhoRubyHelper.java +7 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/Mutex.java +5 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoAppAdapter.java +39 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoClassFactory.java +29 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoConf.java +100 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoEmptyLogger.java +7 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoEmptyProfiler.java +5 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoLogger.java +32 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhoProfiler.java +27 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/RhodesApp.java +25 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/TimeInterval.java +22 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/Tokenizer.java +23 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/db/DBAdapter.java +174 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/db/DBAttrManager.java +15 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/db/DBException.java +5 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/db/IDBResult.java +27 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/file/IFileAccess.java +7 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/file/SimpleFile.java +15 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/net/IHttpConnection.java +22 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/net/NetRequest.java +324 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/net/NetResponse.java +51 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/net/URI.java +64 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/ClientRegister.java +15 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/JSONArrayIterator.java +37 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/JSONEntry.java +48 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/JSONStructIterator.java +41 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/SyncNotify.java +98 -0
- data/rhoconnect-client/JavaScript/stubs/com/rho/sync/SyncThread.java +92 -0
- data/rhoconnect-client/JavaScript/war/WEB-INF/lib/gwt-servlet-deps.jar +0 -0
- data/rhoconnect-client/JavaScript/war/WEB-INF/lib/gwt-servlet.jar +0 -0
- data/rhoconnect-client/JavaScript/war/js/fsm-sample.js +54 -0
- data/rhoconnect-client/JavaScript/war/js/rhosync-api.js +237 -0
- data/rhoconnect-client/JavaScript/war/js/rhosync-fsm.js +307 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/4C71D69C9BBC9E6F05C6BA49B01BCBC1.cache.html +3122 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/5146F4FFF34511C8BB2661E920B49E3A.cache.html +3254 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/5248C67481D9D27AD0703D15CDBD2A1C.cache.html +3147 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/EE1DC2692C9C32367B53A39E2358AF23.cache.html +3195 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/clear.cache.gif +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/corner.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/corner_ie6.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/hborder.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/hborder_ie6.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/corner_dialog_topleft.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/corner_dialog_topright.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/hborder_blue_shadow.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/hborder_gray_shadow.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/vborder_blue_shadow.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/ie6/vborder_gray_shadow.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/splitPanelThumb.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/vborder.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/images/vborder_ie6.png +0 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/standard.css +1144 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/gwt/standard/standard_rtl.css +1145 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/hosted.html +350 -0
- data/rhoconnect-client/JavaScript/war/rhosyncjs/rhosyncjs.nocache.js +314 -0
- data/rhoconnect-client/JavaScript/war/test/SpecRunner.html +35 -0
- data/rhoconnect-client/JavaScript/war/test/dbtest.html +38 -0
- data/rhoconnect-client/JavaScript/war/test/lib/jasmine-1.0.1/MIT.LICENSE +20 -0
- data/rhoconnect-client/JavaScript/war/test/lib/jasmine-1.0.1/jasmine-html.js +188 -0
- data/rhoconnect-client/JavaScript/war/test/lib/jasmine-1.0.1/jasmine.css +166 -0
- data/rhoconnect-client/JavaScript/war/test/lib/jasmine-1.0.1/jasmine.js +2421 -0
- data/rhoconnect-client/JavaScript/war/test/spec/SpecHelper.js +7 -0
- data/rhoconnect-client/JavaScript/war/test/spec/SyncApiSpec.js +573 -0
- data/rhoconnect-client/JavaScript/war/test/spec/samples/PlayerSpec.js +58 -0
- data/rhoconnect-client/JavaScript/war/test/worker-test.js +17 -0
- data/rhoconnect-client/LICENSE +41 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectClient.h +118 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectClient.m +641 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectClient.xcodeproj/project.pbxproj +1434 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectNotify.h +83 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectNotify.m +181 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectObjectNotify.h +65 -0
- data/rhoconnect-client/ObjectiveC/RhoConnectObjectNotify.m +73 -0
- data/rhoconnect-client/ObjectiveC/RhomModel.h +101 -0
- data/rhoconnect-client/ObjectiveC/RhomModel.m +320 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/MainWindow.xib +198 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/RhoConnectClientTest-Info.plist +30 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/RhoConnectClientTest.xcodeproj/project.pbxproj +373 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/RhoConnectClientTestAppDelegate.h +58 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/RhoConnectClientTestAppDelegate.m +84 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/RhoConnectClientTest_Prefix.pch +8 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/invalid_import_db.zip +0 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/main.m +1096 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/test.png +0 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/test2.png +0 -0
- data/rhoconnect-client/ObjectiveC/Tests/RhoConnectClientTest/valid_import_db.zip +0 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/Classes/ptestsAppDelegate.h +62 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/Classes/ptestsAppDelegate.m +35 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/Classes/ptestsViewController.h +78 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/Classes/ptestsViewController.m +549 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/MainWindow.xib +227 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/main.m +17 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/ptests-Info.plist +30 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/ptests.xcodeproj/project.pbxproj +363 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/ptestsViewController.xib +641 -0
- data/rhoconnect-client/ObjectiveC/Tests/ptests/ptests_Prefix.pch +8 -0
- data/rhoconnect-client/README.textile +23 -0
- data/rhoconnect-client/Rakefile +20 -0
- data/rhoconnect-client/Samples/Java/android_store/.classpath +8 -0
- data/rhoconnect-client/Samples/Java/android_store/.project +33 -0
- data/rhoconnect-client/Samples/Java/android_store/AndroidManifest.xml +24 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/apps/rhoconfig.txt +19 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/apps/rhoconfig.txt.timestamp +1 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/db/syncdb.schema +44 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/db/syncdb.triggers +10 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/db/syncdb_java.triggers +21 -0
- data/rhoconnect-client/Samples/Java/android_store/assets/rho.dat +8 -0
- data/rhoconnect-client/Samples/Java/android_store/default.properties +11 -0
- data/rhoconnect-client/Samples/Java/android_store/project.properties +14 -0
- data/rhoconnect-client/Samples/Java/android_store/res/drawable-hdpi/icon.png +0 -0
- data/rhoconnect-client/Samples/Java/android_store/res/drawable-ldpi/icon.png +0 -0
- data/rhoconnect-client/Samples/Java/android_store/res/drawable-mdpi/icon.png +0 -0
- data/rhoconnect-client/Samples/Java/android_store/res/layout/main.xml +12 -0
- data/rhoconnect-client/Samples/Java/android_store/res/values/strings.xml +5 -0
- data/rhoconnect-client/Samples/Java/android_store/rhoimpl.jar +0 -0
- data/rhoconnect-client/Samples/Java/android_store/src/com/rhomobile/android_store/StoreActivity.java +68 -0
- data/rhoconnect-client/Samples/Java/android_store/src/com/rhomobile/android_store/StoreApplication.java +15 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/LoginViewController.h +70 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/LoginViewController.m +94 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/RhoConnectEngine.h +82 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/RhoConnectEngine.m +119 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/RootViewController.h +63 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/RootViewController.m +314 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/WaitLoginController.h +65 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/WaitLoginController.m +110 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/storeAppDelegate.h +61 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/Classes/storeAppDelegate.m +171 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/LoginViewController.xib +779 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/MainWindow.xib +580 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/RootViewController.xib +384 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/WaitLoginController.xib +557 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/icon.png +0 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/main.m +22 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/store-Info.plist +30 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/store.xcodeproj/project.pbxproj +367 -0
- data/rhoconnect-client/Samples/ObjectiveC/store/store_Prefix.pch +14 -0
- data/rhoconnect-client/build.yml +3 -0
- data/rhoconnect-client/version +1 -0
- metadata +314 -0
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/*------------------------------------------------------------------------
|
|
2
|
+
* (The MIT License)
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) 2008-2011 Rhomobile, Inc.
|
|
5
|
+
*
|
|
6
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
* in the Software without restriction, including without limitation the rights
|
|
9
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
* furnished to do so, subject to the following conditions:
|
|
12
|
+
*
|
|
13
|
+
* The above copyright notice and this permission notice shall be included in
|
|
14
|
+
* all copies or substantial portions of the Software.
|
|
15
|
+
*
|
|
16
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
22
|
+
* THE SOFTWARE.
|
|
23
|
+
*
|
|
24
|
+
* http://rhomobile.com
|
|
25
|
+
|
|
26
|
+
* Copyright (c) 2011-2016 Symbol Technologies, Inc.
|
|
27
|
+
*
|
|
28
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
29
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
30
|
+
* in the Software without restriction, including without limitation the rights
|
|
31
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
32
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
33
|
+
* furnished to do so, subject to the following conditions:
|
|
34
|
+
*
|
|
35
|
+
* The above copyright notice and this permission notice shall be included in
|
|
36
|
+
* all copies or substantial portions of the Software.
|
|
37
|
+
*
|
|
38
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
39
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
40
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
41
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
42
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
43
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
44
|
+
* THE SOFTWARE.
|
|
45
|
+
*
|
|
46
|
+
* http://symbol.com
|
|
47
|
+
*------------------------------------------------------------------------*/
|
|
48
|
+
|
|
49
|
+
#import <Foundation/Foundation.h>
|
|
50
|
+
|
|
51
|
+
#include "RhoConnectClient/RhoConnectClient.h"
|
|
52
|
+
|
|
53
|
+
@interface RhoConnectNotify : NSObject {
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
@property int total_count;
|
|
57
|
+
@property int processed_count;
|
|
58
|
+
@property int cumulative_count;
|
|
59
|
+
@property int source_id;
|
|
60
|
+
@property int error_code;
|
|
61
|
+
@property(readonly) NSString* source_name;
|
|
62
|
+
@property(readonly) NSString* status;
|
|
63
|
+
@property(readonly) NSString* sync_type;
|
|
64
|
+
@property(readonly) NSString* bulk_status;
|
|
65
|
+
@property(readonly) NSString* partition;
|
|
66
|
+
@property(readonly) NSString* error_message;
|
|
67
|
+
@property(readonly) NSString* callback_params;
|
|
68
|
+
@property(readonly) NSMutableDictionary* create_errors;
|
|
69
|
+
@property(readonly) NSMutableDictionary* update_errors;
|
|
70
|
+
@property(readonly) NSMutableDictionary* delete_errors;
|
|
71
|
+
@property(readonly) RHO_CONNECT_NOTIFY notify_data;
|
|
72
|
+
|
|
73
|
+
- (id) init: (RHO_CONNECT_NOTIFY*) data;
|
|
74
|
+
- (void)dealloc;
|
|
75
|
+
|
|
76
|
+
- (Boolean) hasCreateErrors;
|
|
77
|
+
- (Boolean) hasUpdateErrors;
|
|
78
|
+
- (Boolean) hasDeleteErrors;
|
|
79
|
+
- (Boolean) isUnknownClientError;
|
|
80
|
+
|
|
81
|
+
- (RHO_CONNECT_NOTIFY*)getNotifyPtr;
|
|
82
|
+
|
|
83
|
+
@end
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
//
|
|
2
|
+
// RhoConnectNotify.m
|
|
3
|
+
// SyncClientTest
|
|
4
|
+
//
|
|
5
|
+
// Created by evgeny vovchenko on 8/23/10.
|
|
6
|
+
// Copyright 2010 RhoMobile. All rights reserved.
|
|
7
|
+
// Copyright 2011-2016 Symbol Technologies. All rights reserved.
|
|
8
|
+
//
|
|
9
|
+
|
|
10
|
+
#import "RhoConnectNotify.h"
|
|
11
|
+
|
|
12
|
+
@implementation RhoConnectNotify
|
|
13
|
+
|
|
14
|
+
@synthesize total_count;
|
|
15
|
+
@synthesize processed_count;
|
|
16
|
+
@synthesize cumulative_count;
|
|
17
|
+
@synthesize source_id;
|
|
18
|
+
@synthesize error_code;
|
|
19
|
+
@synthesize source_name;
|
|
20
|
+
@synthesize status;
|
|
21
|
+
@synthesize sync_type;
|
|
22
|
+
@synthesize bulk_status;
|
|
23
|
+
@synthesize partition;
|
|
24
|
+
@synthesize error_message;
|
|
25
|
+
@synthesize callback_params;
|
|
26
|
+
@synthesize notify_data;
|
|
27
|
+
@synthesize create_errors;
|
|
28
|
+
@synthesize update_errors;
|
|
29
|
+
@synthesize delete_errors;
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
int enum_errors_messages_func(const char *szKey, const char *szValue, void *pThis)
|
|
33
|
+
{
|
|
34
|
+
NSMutableDictionary *data = (NSMutableDictionary *)pThis;
|
|
35
|
+
|
|
36
|
+
[data setValue:[NSString stringWithUTF8String:szValue] forKey:[NSString stringWithUTF8String:szKey]];
|
|
37
|
+
return 1;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
- (id)init:(RHO_CONNECT_NOTIFY *)data
|
|
41
|
+
{
|
|
42
|
+
self = [super init];
|
|
43
|
+
|
|
44
|
+
notify_data = *data;
|
|
45
|
+
total_count = data->total_count;
|
|
46
|
+
processed_count = data->processed_count;
|
|
47
|
+
cumulative_count = data->cumulative_count;
|
|
48
|
+
source_id = data->source_id;
|
|
49
|
+
error_code = data->error_code;
|
|
50
|
+
|
|
51
|
+
if (data->source_name)
|
|
52
|
+
{
|
|
53
|
+
source_name = [[NSString alloc] initWithUTF8String:data->source_name];
|
|
54
|
+
}
|
|
55
|
+
if (data->status)
|
|
56
|
+
{
|
|
57
|
+
status = [[NSString alloc] initWithUTF8String:data->status];
|
|
58
|
+
}
|
|
59
|
+
if (data->sync_type)
|
|
60
|
+
{
|
|
61
|
+
sync_type = [[NSString alloc] initWithUTF8String:data->sync_type];
|
|
62
|
+
}
|
|
63
|
+
if (data->bulk_status)
|
|
64
|
+
{
|
|
65
|
+
bulk_status = [[NSString alloc] initWithUTF8String:data->bulk_status];
|
|
66
|
+
}
|
|
67
|
+
if (data->partition)
|
|
68
|
+
{
|
|
69
|
+
partition = [[NSString alloc] initWithUTF8String:data->partition];
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
if (data->error_message)
|
|
73
|
+
{
|
|
74
|
+
error_message = [[NSString alloc] initWithUTF8String:data->error_message];
|
|
75
|
+
}
|
|
76
|
+
if (data->callback_params)
|
|
77
|
+
{
|
|
78
|
+
callback_params = [[NSString alloc] initWithUTF8String:data->callback_params];
|
|
79
|
+
}
|
|
80
|
+
if (data->create_errors_messages)
|
|
81
|
+
{
|
|
82
|
+
create_errors = [[NSMutableDictionary alloc] init];
|
|
83
|
+
rho_connectclient_hash_enumerate(data->create_errors_messages, &enum_errors_messages_func, create_errors);
|
|
84
|
+
}
|
|
85
|
+
if (data->update_errors_messages)
|
|
86
|
+
{
|
|
87
|
+
update_errors = [[NSMutableDictionary alloc] init];
|
|
88
|
+
rho_connectclient_hash_enumerate(data->update_errors_messages, &enum_errors_messages_func, update_errors);
|
|
89
|
+
}
|
|
90
|
+
if (data->delete_errors_messages)
|
|
91
|
+
{
|
|
92
|
+
delete_errors = [[NSMutableDictionary alloc] init];
|
|
93
|
+
rho_connectclient_hash_enumerate(data->delete_errors_messages, &enum_errors_messages_func, delete_errors);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
return self;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
- (void)dealloc
|
|
100
|
+
{
|
|
101
|
+
rho_connectclient_free_syncnotify(¬ify_data);
|
|
102
|
+
|
|
103
|
+
if (source_name)
|
|
104
|
+
{
|
|
105
|
+
[source_name release];
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
if (status)
|
|
109
|
+
{
|
|
110
|
+
[status release];
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
if (sync_type)
|
|
114
|
+
{
|
|
115
|
+
[sync_type release];
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
if (bulk_status)
|
|
119
|
+
{
|
|
120
|
+
[bulk_status release];
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
if (partition)
|
|
124
|
+
{
|
|
125
|
+
[partition release];
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
if (error_message)
|
|
129
|
+
{
|
|
130
|
+
[error_message release];
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
if (callback_params)
|
|
134
|
+
{
|
|
135
|
+
[callback_params release];
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
if (create_errors)
|
|
139
|
+
{
|
|
140
|
+
[create_errors release];
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
if (update_errors)
|
|
144
|
+
{
|
|
145
|
+
[update_errors release];
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
if (delete_errors)
|
|
149
|
+
{
|
|
150
|
+
[delete_errors release];
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
[super dealloc];
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
- (RHO_CONNECT_NOTIFY *)getNotifyPtr
|
|
157
|
+
{
|
|
158
|
+
return ¬ify_data;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
- (Boolean)hasCreateErrors
|
|
162
|
+
{
|
|
163
|
+
return notify_data.create_errors_messages != 0;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
- (Boolean)hasUpdateErrors
|
|
167
|
+
{
|
|
168
|
+
return (notify_data.update_errors_obj != 0) || (notify_data.update_errors_messages != 0);
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
- (Boolean)hasDeleteErrors
|
|
172
|
+
{
|
|
173
|
+
return (notify_data.delete_errors_obj != 0) || (notify_data.delete_errors_obj != 0);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
- (Boolean)isUnknownClientError
|
|
177
|
+
{
|
|
178
|
+
return [error_message caseInsensitiveCompare:@"unknown client"] == 0;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
@end
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/*------------------------------------------------------------------------
|
|
2
|
+
* (The MIT License)
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) 2008-2011 Rhomobile, Inc.
|
|
5
|
+
*
|
|
6
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
* in the Software without restriction, including without limitation the rights
|
|
9
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
* furnished to do so, subject to the following conditions:
|
|
12
|
+
*
|
|
13
|
+
* The above copyright notice and this permission notice shall be included in
|
|
14
|
+
* all copies or substantial portions of the Software.
|
|
15
|
+
*
|
|
16
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
22
|
+
* THE SOFTWARE.
|
|
23
|
+
*
|
|
24
|
+
* http://rhomobile.com
|
|
25
|
+
|
|
26
|
+
* Copyright (c) 2011-2016 Symbol Technologies, Inc.
|
|
27
|
+
*
|
|
28
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
29
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
30
|
+
* in the Software without restriction, including without limitation the rights
|
|
31
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
32
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
33
|
+
* furnished to do so, subject to the following conditions:
|
|
34
|
+
*
|
|
35
|
+
* The above copyright notice and this permission notice shall be included in
|
|
36
|
+
* all copies or substantial portions of the Software.
|
|
37
|
+
*
|
|
38
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
39
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
40
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
41
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
42
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
43
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
44
|
+
* THE SOFTWARE.
|
|
45
|
+
*
|
|
46
|
+
* http://symbol.com
|
|
47
|
+
*------------------------------------------------------------------------*/
|
|
48
|
+
|
|
49
|
+
#import <Foundation/Foundation.h>
|
|
50
|
+
#include "RhoConnectClient/RhoConnectClient.h"
|
|
51
|
+
|
|
52
|
+
@interface RhoConnectObjectNotify : NSObject {
|
|
53
|
+
}
|
|
54
|
+
@property(readonly) NSMutableArray *deleted_objects;
|
|
55
|
+
@property(readonly) NSMutableArray *updated_objects;
|
|
56
|
+
@property(readonly) NSMutableArray *created_objects;
|
|
57
|
+
|
|
58
|
+
@property(readonly) NSMutableArray *deleted_source_ids;
|
|
59
|
+
@property(readonly) NSMutableArray *updated_source_ids;
|
|
60
|
+
@property(readonly) NSMutableArray *created_source_ids;
|
|
61
|
+
|
|
62
|
+
- (id)init:(RHO_CONNECT_OBJECT_NOTIFY *)data;
|
|
63
|
+
- (void)dealloc;
|
|
64
|
+
|
|
65
|
+
@end
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
//
|
|
2
|
+
// RhoConnectObjectNotify.m
|
|
3
|
+
// SyncClient
|
|
4
|
+
//
|
|
5
|
+
// Created by evgeny vovchenko on 4/22/11.
|
|
6
|
+
// Copyright 2011 RhoMobile. All rights reserved.
|
|
7
|
+
// Copyright 2011-2016 Symbol Technologies. All rights reserved.
|
|
8
|
+
//
|
|
9
|
+
|
|
10
|
+
#import "RhoConnectObjectNotify.h"
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@implementation RhoConnectObjectNotify
|
|
14
|
+
|
|
15
|
+
@synthesize deleted_objects;
|
|
16
|
+
@synthesize updated_objects;
|
|
17
|
+
@synthesize created_objects;
|
|
18
|
+
|
|
19
|
+
@synthesize deleted_source_ids;
|
|
20
|
+
@synthesize updated_source_ids;
|
|
21
|
+
@synthesize created_source_ids;
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
- (id)init:(RHO_CONNECT_OBJECT_NOTIFY *)data
|
|
25
|
+
{
|
|
26
|
+
self = [super init];
|
|
27
|
+
|
|
28
|
+
if (data->deleted_count)
|
|
29
|
+
{
|
|
30
|
+
deleted_objects = [[NSMutableArray alloc] initWithCapacity:data->deleted_count];
|
|
31
|
+
deleted_source_ids = [[NSMutableArray alloc] initWithCapacity:data->deleted_count];
|
|
32
|
+
|
|
33
|
+
for (int i = 0; i < data->deleted_count; i++)
|
|
34
|
+
{
|
|
35
|
+
[deleted_objects addObject:[NSString stringWithUTF8String:data->deleted_objects[i]]];
|
|
36
|
+
[deleted_source_ids addObject:[NSNumber numberWithInt:data->deleted_source_ids[i]]];
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
if (data->updated_count)
|
|
41
|
+
{
|
|
42
|
+
updated_objects = [[NSMutableArray alloc] initWithCapacity:data->updated_count];
|
|
43
|
+
updated_source_ids = [[NSMutableArray alloc] initWithCapacity:data->updated_count];
|
|
44
|
+
|
|
45
|
+
for (int i = 0; i < data->updated_count; i++)
|
|
46
|
+
{
|
|
47
|
+
[updated_objects addObject:[NSString stringWithUTF8String:data->updated_objects[i]]];
|
|
48
|
+
[updated_source_ids addObject:[NSNumber numberWithInt:data->updated_source_ids[i]]];
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
if (data->created_count)
|
|
53
|
+
{
|
|
54
|
+
created_objects = [[NSMutableArray alloc] initWithCapacity:data->created_count];
|
|
55
|
+
created_source_ids = [[NSMutableArray alloc] initWithCapacity:data->created_count];
|
|
56
|
+
|
|
57
|
+
for (int i = 0; i < data->created_count; i++)
|
|
58
|
+
{
|
|
59
|
+
[created_objects addObject:[NSString stringWithUTF8String:data->created_objects[i]]];
|
|
60
|
+
[created_source_ids addObject:[NSNumber numberWithInt:data->created_source_ids[i]]];
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
rho_connectclient_free_sync_objectnotify(data);
|
|
65
|
+
return self;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
- (void)dealloc
|
|
69
|
+
{
|
|
70
|
+
[super dealloc];
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
@end
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/*------------------------------------------------------------------------
|
|
2
|
+
* (The MIT License)
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) 2008-2011 Rhomobile, Inc.
|
|
5
|
+
*
|
|
6
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
* in the Software without restriction, including without limitation the rights
|
|
9
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
* furnished to do so, subject to the following conditions:
|
|
12
|
+
*
|
|
13
|
+
* The above copyright notice and this permission notice shall be included in
|
|
14
|
+
* all copies or substantial portions of the Software.
|
|
15
|
+
*
|
|
16
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
22
|
+
* THE SOFTWARE.
|
|
23
|
+
*
|
|
24
|
+
* http://rhomobile.com
|
|
25
|
+
|
|
26
|
+
* Copyright (c) 2011-2016 Symbol Technologies, Inc.
|
|
27
|
+
*
|
|
28
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
29
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
30
|
+
* in the Software without restriction, including without limitation the rights
|
|
31
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
32
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
33
|
+
* furnished to do so, subject to the following conditions:
|
|
34
|
+
*
|
|
35
|
+
* The above copyright notice and this permission notice shall be included in
|
|
36
|
+
* all copies or substantial portions of the Software.
|
|
37
|
+
*
|
|
38
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
39
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
40
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
41
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
42
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
43
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
44
|
+
* THE SOFTWARE.
|
|
45
|
+
*
|
|
46
|
+
* http://symbol.com
|
|
47
|
+
*------------------------------------------------------------------------*/
|
|
48
|
+
|
|
49
|
+
#import <Foundation/Foundation.h>
|
|
50
|
+
|
|
51
|
+
#import "RhoConnectNotify.h"
|
|
52
|
+
|
|
53
|
+
@interface RhomModel : NSObject {
|
|
54
|
+
NSString *name;
|
|
55
|
+
NSString *partition;
|
|
56
|
+
int sync_type;
|
|
57
|
+
int model_type;
|
|
58
|
+
int source_id; // generated when insert to database
|
|
59
|
+
|
|
60
|
+
NSDictionary *associations;
|
|
61
|
+
NSMutableString *blob_attribs;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
@property(retain) NSString *name;
|
|
65
|
+
@property(retain) NSString *partition;
|
|
66
|
+
@property(assign) int sync_type;
|
|
67
|
+
@property(assign) int source_id;
|
|
68
|
+
@property(assign) int model_type;
|
|
69
|
+
@property(retain) NSDictionary *associations;
|
|
70
|
+
@property(retain, readonly) NSString *blob_attribs;
|
|
71
|
+
|
|
72
|
+
- (id)init;
|
|
73
|
+
- (void)dealloc;
|
|
74
|
+
|
|
75
|
+
- (RhoConnectNotify *)sync;
|
|
76
|
+
- (void)sync:(SEL)callback target:(id)target;
|
|
77
|
+
|
|
78
|
+
- (void)setNotification:(SEL)callback target:(id)target;
|
|
79
|
+
- (void)clearNotification;
|
|
80
|
+
|
|
81
|
+
- (void)add_blob_attribute:(NSString *)attr_name;
|
|
82
|
+
- (void)add_blob_attribute:(NSString *)attr_name overwrite:(BOOL)attr_overwrite;
|
|
83
|
+
|
|
84
|
+
- (void)create:(NSMutableDictionary *)data;
|
|
85
|
+
- (NSMutableDictionary *)find:(NSString *)object_id;
|
|
86
|
+
- (NSMutableDictionary *)find_first:(NSDictionary *)cond;
|
|
87
|
+
- (NSMutableArray *)find_all:(NSDictionary *)cond;
|
|
88
|
+
- (NSMutableArray *)find_bysql:(NSString *)sql args:(NSArray *)sql_args;
|
|
89
|
+
|
|
90
|
+
- (void)save:(NSDictionary *)data;
|
|
91
|
+
- (void)destroy:(NSDictionary *)data;
|
|
92
|
+
|
|
93
|
+
- (void)startBulkUpdate;
|
|
94
|
+
- (void)stopBulkUpdate;
|
|
95
|
+
|
|
96
|
+
- (BOOL)is_changed;
|
|
97
|
+
|
|
98
|
+
- (void)setSyncType:(int)type;
|
|
99
|
+
- (void)pushChanges;
|
|
100
|
+
|
|
101
|
+
@end
|