rhodes 2.3.2 → 2.4.0.beta.1
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +18 -0
- data/CREDITS +38 -0
- data/README.md +2 -2
- data/Rakefile +60 -2
- data/bin/set-rhodes-sdk.bat +1 -0
- data/doc/application.txt +11 -0
- data/doc/build.txt +156 -39
- data/doc/configuration.txt +1 -10
- data/doc/connect-to-web-services.txt +6 -6
- data/doc/device-caps.txt +48 -5
- data/doc/extensions.txt +8 -1
- data/doc/rhom.txt +16 -0
- data/doc/synchronization.txt +56 -14
- data/doc/ui.txt +23 -2
- data/installer/instant-rhodes.nsi +6 -6
- data/lib/extensions/barcode/ext/barcode/platform/iphone/Barcode.xcodeproj/project.pbxproj +4 -2
- data/lib/extensions/barcode/ext/barcode/platform/wm/Rakefile +1 -1
- data/lib/extensions/digest-md5/ext/Rakefile +3 -3
- data/lib/extensions/digest-md5/ext/build +0 -1
- data/lib/extensions/digest-sha1/ext/Rakefile +1 -1
- data/lib/extensions/digest-sha1/ext/build +0 -1
- data/lib/extensions/digest/ext/Rakefile +3 -3
- data/lib/extensions/digest/ext/build +0 -1
- data/lib/extensions/fcntl/ext/Rakefile +1 -1
- data/lib/extensions/mspec/mspec/guards/guard.rb +4 -0
- data/lib/extensions/mspec/mspec/helpers/environment.rb +4 -0
- data/lib/extensions/nfc/ext.yml +2 -0
- data/lib/extensions/nfc/ext/build +12 -0
- data/lib/extensions/nfc/ext/build.bat +8 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/AndroidManifest.xml +25 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/Rakefile +94 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/ext_build.files +4 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/jni/src/nfc.cpp +404 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/src/com/nfc/Nfc.java +138 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/src/com/nfc/NfcMessage.java +34 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/src/com/nfc/NfcMessagePack.java +33 -0
- data/lib/extensions/nfc/ext/nfc/platform/android/src/com/nfc/NfcRecord.java +149 -0
- data/lib/extensions/nfc/ext/nfc/shared/ruby/nfc.i +22 -0
- data/lib/extensions/nfc/ext/nfc/shared/ruby/nfc_wrap.c +2034 -0
- data/lib/extensions/nfc/nfc.rb +120 -0
- data/lib/extensions/rholang/{lang_ca.rb → rholang/lang_ca.rb} +0 -0
- data/lib/extensions/rholang/{lang_cf.rb → rholang/lang_cf.rb} +0 -0
- data/lib/extensions/rholang/{lang_chef.rb → rholang/lang_chef.rb} +0 -0
- data/lib/extensions/rholang/{lang_cs.rb → rholang/lang_cs.rb} +0 -0
- data/lib/extensions/rholang/{lang_da.rb → rholang/lang_da.rb} +0 -0
- data/lib/extensions/rholang/{lang_de.rb → rholang/lang_de.rb} +0 -0
- data/lib/extensions/rholang/{lang_es.rb → rholang/lang_es.rb} +0 -0
- data/lib/extensions/rholang/{lang_es_ar.rb → rholang/lang_es_ar.rb} +0 -0
- data/lib/extensions/rholang/{lang_fi.rb → rholang/lang_fi.rb} +0 -0
- data/lib/extensions/rholang/{lang_fr.rb → rholang/lang_fr.rb} +0 -0
- data/lib/extensions/rholang/{lang_it.rb → rholang/lang_it.rb} +0 -0
- data/lib/extensions/rholang/{lang_ko.rb → rholang/lang_ko.rb} +0 -0
- data/lib/extensions/rholang/{lang_nl.rb → rholang/lang_nl.rb} +0 -0
- data/lib/extensions/rholang/{lang_no.rb → rholang/lang_no.rb} +0 -0
- data/lib/extensions/rholang/{lang_pt.rb → rholang/lang_pt.rb} +0 -0
- data/lib/extensions/rholang/{lang_pt_br.rb → rholang/lang_pt_br.rb} +0 -0
- data/lib/extensions/rholang/{lang_ru.rb → rholang/lang_ru.rb} +0 -0
- data/lib/extensions/rholang/{lang_se.rb → rholang/lang_se.rb} +0 -0
- data/lib/extensions/rholang/{lang_sr.rb → rholang/lang_sr.rb} +0 -0
- data/lib/extensions/rholang/{rhoerror_ru.rb → rholang/rhoerror_ru.rb} +0 -0
- data/lib/extensions/rholang/{rhomsg_ru.rb → rholang/rhomsg_ru.rb} +0 -0
- data/lib/framework/date/format.rb +2 -0
- data/lib/framework/dateOrig.rb +17 -8
- data/lib/framework/rational18.rb +532 -0
- data/lib/framework/res/back_btn.wp7.png +0 -0
- data/lib/framework/res/blue_pushpin.wp7.png +0 -0
- data/lib/framework/res/blue_pushpin_small.wp7.png +0 -0
- data/lib/framework/res/callout.wp7.png +0 -0
- data/lib/framework/res/callout_link.wp7.png +0 -0
- data/lib/framework/res/esri.wp7.png +0 -0
- data/lib/framework/res/forward_btn.wp7.png +0 -0
- data/lib/framework/res/home_btn.wp7.png +0 -0
- data/lib/framework/res/options_btn.wp7.png +0 -0
- data/lib/framework/res/refresh_btn.wp7.png +0 -0
- data/lib/framework/rho/render.rb +8 -1
- data/lib/framework/rho/rho.rb +30 -7
- data/lib/framework/rho/rhoapplication.rb +9 -4
- data/lib/framework/rho/rhofsconnector.rb +5 -1
- data/lib/framework/rho/rhotabbar.rb +8 -0
- data/lib/framework/rho/rhotoolbar.rb +1 -1
- data/lib/framework/rho/rhoviewhelpers.rb +18 -1
- data/lib/framework/rhodes.rb +1 -1
- data/lib/framework/rhoframework.rb +46 -1
- data/lib/framework/rholang/localization_simplified.rb +17 -16
- data/lib/framework/rhom/rhom_db_adapter.rb +2 -2
- data/lib/framework/rhom/rhom_object_factory.rb +115 -12
- data/lib/framework/rhosystem.rb +135 -0
- data/lib/framework/version.rb +1 -1
- data/lib/rhodes.rb +1 -1
- data/lib/test/apps/rhoconfig.txt +23 -23
- data/platform/android/Rhodes/AndroidManifest.full.xml +101 -0
- data/platform/android/Rhodes/AndroidManifest.xml +10 -15
- data/platform/android/Rhodes/default.properties +11 -0
- data/platform/android/Rhodes/gen/com/rhomobile/rhodes/R.java +59 -53
- data/platform/android/Rhodes/jni/include/rhodes.h +1 -0
- data/platform/android/Rhodes/jni/include/rhodes/jni/com_rhomobile_rhodes_RhodesApplication.h +21 -0
- data/platform/android/Rhodes/jni/include/rhodes/jni/com_rhomobile_rhodes_alert_PopupActivity.h +21 -0
- data/platform/android/Rhodes/jni/include/rhodes/jni/com_rhomobile_rhodes_file_RhoFileApi.h +10 -2
- data/platform/android/Rhodes/jni/src/alert.cpp +2 -1
- data/platform/android/Rhodes/jni/src/datetimepicker.cpp +2 -0
- data/platform/android/Rhodes/jni/src/fileapi.cpp +671 -84
- data/platform/android/Rhodes/jni/src/nativebar.cpp +18 -0
- data/platform/android/Rhodes/jni/src/rhodes.cpp +92 -1
- data/platform/android/Rhodes/res/values/styles.xml +7 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/BaseActivity.java +35 -2
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/Capabilities.java +12 -13
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/LocalFileProvider.java +130 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/NativeBar.java +6 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/PushReceiver.java +5 -1
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/PushService.java +6 -2
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/RhoMenu.java +7 -36
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/RhodesActivity.java +43 -20
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/RhodesApplication.java +2 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/RhodesService.java +63 -28
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/Utils.java +2 -2
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/WebView.java +6 -2
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/alert/Alert.java +19 -282
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/alert/PopupActivity.java +354 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/datetime/DateTimePickerScreen.java +4 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/event/EventStore.java +1 -2
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/file/RhoFileApi.java +71 -5
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/geolocation/GeoLocationImpl.java +107 -37
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/mainview/SimpleMainView.java +10 -7
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/mainview/TabbedMainView.java +156 -56
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/mapview/MapView.java +0 -1
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/phonebook/ContactAccessorNew.java +40 -32
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/signature/SignatureView.java +1 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/uri/ExternalHttpHandler.java +14 -6
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/uri/LocalFileHandler.java +46 -0
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/uri/MailUriHandler.java +4 -24
- data/platform/android/Rhodes/src/com/rhomobile/rhodes/uri/UriHandler.java +3 -1
- data/platform/android/build/RhodesSRC_build.files +28 -25
- data/platform/android/build/android.rake +230 -54
- data/platform/android/build/androidcommon.rb +1 -1
- data/platform/android/build/librhocommon_build.files +1 -0
- data/platform/bb/Hsqldb/BlackBerry_App_Descriptor.xml +20 -0
- data/platform/bb/Hsqldb/src/com/rho/db/HsqlDBResult.java +1 -5
- data/platform/bb/Hsqldb/src/com/rho/db/HsqlDBStorage.java +6 -1
- data/platform/bb/Hsqldb/src/org/hsqldb/rowio/RowOutputBase.java +1 -1
- data/platform/bb/Hsqldb/src/org/hsqldb/rowio/RowOutputBinary.java +1 -1
- data/platform/bb/RubyVM/BlackBerry_App_Descriptor.xml +20 -0
- data/platform/bb/RubyVM/src/com/rho/IRhoRubyHelper.java +2 -0
- data/platform/bb/RubyVM/src/com/rho/RhoLogOutputSink.java +0 -1
- data/platform/bb/RubyVM/src/com/rho/RhoLogger.java +12 -10
- data/platform/bb/RubyVM/src/com/rho/RhoThread.java +16 -0
- data/platform/bb/RubyVM/src/com/rho/RhoTimer.java +89 -0
- data/platform/bb/RubyVM/src/com/rho/RhodesApp.java +20 -13
- data/platform/bb/RubyVM/src/com/rho/SplashScreen.java +1 -2
- data/platform/bb/RubyVM/src/com/rho/ThreadQueue.java +2 -2
- data/platform/bb/RubyVM/src/com/rho/TimeInterval.java +5 -0
- data/platform/bb/RubyVM/src/com/rho/db/DBAdapter.java +54 -48
- data/platform/bb/RubyVM/src/com/rho/db/IDBResult.java +0 -1
- data/platform/bb/RubyVM/src/com/rho/db/IDBStorage.java +1 -0
- data/platform/bb/RubyVM/src/com/rho/net/AsyncHttp.java +1 -1
- data/platform/bb/RubyVM/src/com/rho/sync/ClientRegister.java +1 -1
- data/platform/bb/RubyVM/src/com/rho/sync/JSONStructIterator.java +1 -1
- data/platform/bb/RubyVM/src/com/rho/sync/SyncEngine.java +16 -8
- data/platform/bb/RubyVM/src/com/rho/sync/SyncNotify.java +2 -2
- data/platform/bb/RubyVM/src/com/rho/sync/SyncSource.java +52 -29
- data/platform/bb/RubyVM/src/com/rho/sync/SyncThread.java +1 -3
- data/platform/bb/build/RubyVM_build.files +1 -0
- data/platform/bb/build/bb.rake +29 -9
- data/platform/bb/rhodes/BlackBerry_App_Descriptor.xml +23 -0
- data/platform/bb/rhodes/platform/5.0/com/rho/RhodesApplicationPlatform.java +1 -1
- data/platform/bb/rhodes/platform/5.0/com/rho/db/SqliteCopyResult.java +0 -4
- data/platform/bb/rhodes/platform/5.0/com/rho/db/SqliteResult.java +13 -20
- data/platform/bb/rhodes/platform/5.0/com/rho/db/SqliteStorage.java +183 -157
- data/platform/bb/rhodes/src/com/rho/RhoRubyHelper.java +22 -0
- data/platform/bb/rhodes/src/com/rho/RhodesApplicationPlatform.java +1 -1
- data/platform/bb/rhodes/src/com/rho/db/SqliteCopyResult.java +0 -4
- data/platform/bb/rhodes/src/com/rho/db/SqliteResult.java +13 -20
- data/platform/bb/rhodes/src/com/rho/db/SqliteStorage.java +183 -157
- data/platform/bb/rhodes/src/com/rho/rubyext/System.java +46 -1
- data/platform/bb/rhodes/src/rhomobile/RhodesApplication.java +8 -1
- data/platform/bb/rhodes/src/rhomobile/camera/CameraFilesListener.java +13 -3
- data/platform/iphone/Classes/AppManager/AppManager.h +5 -1
- data/platform/iphone/Classes/AppManager/AppManager.m +170 -7
- data/platform/iphone/Classes/DateTimePicker.m +14 -1
- data/platform/iphone/Classes/DateTimePickerDelegate.h +2 -0
- data/platform/iphone/Classes/DateTimePickerDelegate.m +36 -2
- data/platform/iphone/Classes/NativeBar.h +1 -0
- data/platform/iphone/Classes/NativeBar.m +15 -3
- data/platform/iphone/Classes/Phonebook/phonebook.m +8 -9
- data/platform/iphone/Classes/Rhodes.m +50 -6
- data/platform/iphone/Classes/SimpleMainView.m +7 -6
- data/platform/iphone/Classes/SplitView/RightViewController.h +3 -1
- data/platform/iphone/Classes/SplitView/RightViewController.m +14 -1
- data/platform/iphone/Classes/TabbedMainView.h +4 -0
- data/platform/iphone/Classes/TabbedMainView.m +43 -26
- data/platform/iphone/Info.plist +1 -1
- data/platform/iphone/RhoLib/RhoLib.xcodeproj/project.pbxproj +4 -0
- data/platform/iphone/curl/curl.xcodeproj/project.pbxproj +3 -3
- data/platform/iphone/rbuild/iphone.rake +168 -119
- data/platform/iphone/rhoextlib/rhoextlib.xcodeproj/project.pbxproj +4 -2
- data/platform/iphone/rhorubylib/rhorubylib.xcodeproj/project.pbxproj +3 -3
- data/platform/iphone/rhorunner.xcodeproj/project.pbxproj +2 -2
- data/platform/iphone/rhosynclib/rhosynclib.xcodeproj/project.pbxproj +3 -3
- data/platform/shared/SyncClient/SyncClient.cpp +20 -8
- data/platform/shared/SyncClient/SyncClient.h +2 -1
- data/platform/shared/common/RhoDefs.h +4 -0
- data/platform/shared/common/RhoPort.h +22 -0
- data/platform/shared/common/RhoStd.h +5 -0
- data/platform/shared/common/RhoTime.cpp +73 -0
- data/platform/shared/common/RhoTime.h +26 -53
- data/platform/shared/common/RhodesApp.cpp +29 -28
- data/platform/shared/common/RhodesApp.h +4 -1
- data/platform/shared/common/StringConverter.h +37 -10
- data/platform/shared/common/app_build_capabilities.h +2 -0
- data/platform/shared/common/rhoparams.cpp +25 -12
- data/platform/shared/common/rhoparams.h +10 -8
- data/platform/shared/db/DBAdapter.cpp +0 -22
- data/platform/shared/json/RJSONTokener.c +15 -23
- data/platform/shared/net/AsyncHttp.cpp +9 -8
- data/platform/shared/net/HttpServer.cpp +61 -19
- data/platform/shared/net/HttpServer.h +2 -0
- data/platform/shared/ruby/ext/datetimepicker/datetimepicker.i +3 -0
- data/platform/shared/ruby/ext/datetimepicker/datetimepicker_wrap.c +151 -402
- data/platform/shared/ruby/ext/nativebar/nativebar.i +3 -0
- data/platform/shared/ruby/ext/nativebar/nativebar_wrap.c +154 -403
- data/platform/shared/ruby/ext/rho/rhoruby.c +4 -0
- data/platform/shared/ruby/ext/rho/rhoruby.h +2 -0
- data/platform/shared/ruby/ext/system/system.i +8 -0
- data/platform/shared/ruby/ext/system/system_wrap.c +80 -5
- data/platform/shared/ruby/file.c +6 -4
- data/platform/shared/ruby/gc.c +1 -1
- data/platform/shared/ruby/linux/ruby/config.h +7 -2
- data/platform/shared/ruby/missing/acosh.c +3 -3
- data/platform/shared/ruby/wince/_time.h +1 -1
- data/platform/shared/ruby/wince/stdlib.c +1 -1
- data/platform/shared/ruby/wince/string_wce.c +2 -2
- data/platform/shared/ruby/wince/sys/timeb.c +1 -0
- data/platform/shared/ruby/wince/time_wce.c +8 -0
- data/platform/shared/ruby/wince/wince.c +7 -7
- data/platform/shared/ruby/wince/wince.h +22 -0
- data/platform/shared/rubyext/System.cpp +19 -1
- data/platform/shared/sqlite/sqlite3.c +18993 -8129
- data/platform/shared/sqlite/sqlite3.h +953 -358
- data/platform/shared/sqlite/sqlite3ext.h +42 -0
- data/platform/shared/sync/SyncEngine.cpp +10 -0
- data/platform/shared/sync/SyncSource.cpp +41 -19
- data/platform/shared/sync/SyncSource.h +1 -1
- data/platform/shared/tcmalloc/rhomem.h +7 -2
- data/platform/shared/tcmalloc/windows/port.h +2 -0
- data/platform/shared/unzip/unzip.cpp +1 -0
- data/platform/shared/xruby/src/com/xruby/compiler/parser/RubyParser.java +11 -1
- data/platform/wm/RhoLib/RhoLib.vcproj +182 -24
- data/platform/wm/build/wm.rake +16 -3
- data/platform/wm/rhodes.sln +106 -113
- data/platform/wm/rhodes/Alert.cpp +6 -7
- data/platform/wm/rhodes/AppManager.cpp +8 -17
- data/platform/wm/rhodes/DateTimePicker.cpp +3 -0
- data/platform/wm/rhodes/DateTimePicker.h +2 -0
- data/platform/wm/rhodes/MainWindow.cpp +36 -16
- data/platform/wm/rhodes/MainWindow.h +6 -3
- data/platform/wm/rhodes/OutlookApp.cpp +3 -3
- data/platform/wm/rhodes/Rhodes.cpp +46 -27
- data/platform/wm/rhodes/Rhodes.rc +16 -3
- data/platform/wm/rhodes/RingtoneManager.cpp +7 -7
- data/platform/wm/rhodes/RingtoneManager.h +1 -1
- data/platform/wm/rhodes/Utils.cpp +2 -1
- data/platform/wm/rhodes/bluetooth/Bluetooth.cpp +1 -13
- data/platform/wm/rhodes/bluetooth/Bluetooth.h +1 -2
- data/platform/wm/rhodes/camera/Camera.cpp +6 -12
- data/platform/wm/rhodes/phonebook/phonebook.cpp +11 -11
- data/platform/wm/rhodes/phonebook/phonebook.h +1 -1
- data/platform/wm/rhodes/resource.h +3 -1
- data/platform/wm/rhodes/rho/net/NetRequestImpl.cpp +7 -5
- data/platform/wm/rhodes/rho/rubyext/GeoLocationImpl.cpp +6 -6
- data/platform/wm/rhodes/rho/rubyext/GeoLocationImpl.h +1 -1
- data/platform/wm/rhodes/rho/rubyext/NativeToolbar.cpp +6 -1
- data/platform/wm/rhodes/rho/rubyext/SystemImpl.cpp +84 -19
- data/platform/wm/rhodes/rho/rubyext/calendar.cpp +2 -2
- data/platform/wm/rhodes/rhodes.vcproj +316 -73
- data/platform/wm/rhodes/signature/Signature.cpp +336 -6
- data/platform/wm/rhodes/signature/Signature.h +55 -0
- data/platform/wm/rhodes/stdafx.h +7 -4
- data/platform/wm/rubylib/rubylib.vcproj +261 -91
- data/platform/wm/sqlite3/sqlite3.vcproj +223 -69
- data/platform/wm/syncengine/syncengine.vcproj +220 -66
- data/platform/wm/tcmalloc/tcmalloc.vcproj +197 -43
- data/platform/wp7/IronRuby/Languages/Ruby/Ruby/Builtins/ConsoleStream.cs +107 -0
- data/platform/wp7/IronRuby/Languages/Ruby/Ruby/Runtime/Loader.cs +1037 -0
- data/platform/wp7/IronRuby/Languages/Ruby/Ruby/Runtime/RubyUtils.cs +1476 -0
- data/platform/wp7/RhoAppRunner/Program.cs +55 -0
- data/platform/wp7/RhoAppRunner/Properties/AssemblyInfo.cs +36 -0
- data/platform/wp7/RhoAppRunner/RhoAppRunner.csproj +69 -0
- data/platform/wp7/RhoRubyExtGen/GenerateInitializers.cmd +7 -0
- data/platform/wp7/RhoRubyExtGen/Properties/AssemblyInfo.cs +36 -0
- data/platform/wp7/RhoRubyExtGen/RhoAsyncHttp.cs +38 -0
- data/platform/wp7/RhoRubyExtGen/RhoDatabase.cs +93 -0
- data/platform/wp7/RhoRubyExtGen/RhoJSON.cs +37 -0
- data/platform/wp7/RhoRubyExtGen/RhoNativeBar.cs +106 -0
- data/platform/wp7/RhoRubyExtGen/RhoRubyExtGen.csproj +75 -0
- data/platform/wp7/RhoRubyExtGen/RhoSyncEngine.cs +123 -0
- data/platform/wp7/RhoRubyExtGen/RhoWebView.cs +42 -0
- data/platform/wp7/RhoRubyLib/Initializers.Generated.cs +309 -0
- data/platform/wp7/RhoRubyLib/Properties/AssemblyInfo.cs +36 -0
- data/platform/wp7/RhoRubyLib/RhoAppAdapter.cs +96 -0
- data/platform/wp7/RhoRubyLib/RhoRuby.cs +296 -0
- data/platform/wp7/RhoRubyLib/RhoRubyLib.csproj +155 -0
- data/platform/wp7/RhoRubyLib/WP_PlatformAdaptationLayer.cs +107 -0
- data/platform/wp7/RhoRubyLib/common/IInputStream.cs +21 -0
- data/platform/wp7/RhoRubyLib/common/Mutex.cs +30 -0
- data/platform/wp7/RhoRubyLib/common/RhoConf.cs +389 -0
- data/platform/wp7/RhoRubyLib/common/RhoEmptyProfiler.cs +27 -0
- data/platform/wp7/RhoRubyLib/common/RhoFile.cs +332 -0
- data/platform/wp7/RhoRubyLib/common/RhoFilePath.cs +89 -0
- data/platform/wp7/RhoRubyLib/common/RhoParamArray.cs +33 -0
- data/platform/wp7/RhoRubyLib/common/RhoParams.cs +66 -0
- data/platform/wp7/RhoRubyLib/common/RhoProfiler.cs +145 -0
- data/platform/wp7/RhoRubyLib/common/RhoResourceMap.cs +68 -0
- data/platform/wp7/RhoRubyLib/common/RhoStd.cs +205 -0
- data/platform/wp7/RhoRubyLib/common/RhoThread.cs +114 -0
- data/platform/wp7/RhoRubyLib/common/RhodesApp.cs +504 -0
- data/platform/wp7/RhoRubyLib/common/ThreadQueue.cs +199 -0
- data/platform/wp7/RhoRubyLib/common/TimeInterval.cs +56 -0
- data/platform/wp7/RhoRubyLib/common/Tokenizer.cs +52 -0
- data/platform/wp7/RhoRubyLib/db/DBAdapter.cs +1129 -0
- data/platform/wp7/RhoRubyLib/db/DBAttrManager.cs +92 -0
- data/platform/wp7/RhoRubyLib/db/DBException.cs +35 -0
- data/platform/wp7/RhoRubyLib/db/IDBCallback.cs +10 -0
- data/platform/wp7/RhoRubyLib/db/IDBResult.cs +33 -0
- data/platform/wp7/RhoRubyLib/db/IDBStorage.cs +32 -0
- data/platform/wp7/RhoRubyLib/db/SqliteCopyResult.cs +79 -0
- data/platform/wp7/RhoRubyLib/db/SqliteResult.cs +267 -0
- data/platform/wp7/RhoRubyLib/db/SqliteStorage.cs +319 -0
- data/platform/wp7/RhoRubyLib/json/JSONArrayIterator.cs +63 -0
- data/platform/wp7/RhoRubyLib/json/JSONEntry.cs +96 -0
- data/platform/wp7/RhoRubyLib/json/JSONStructIterator.cs +77 -0
- data/platform/wp7/RhoRubyLib/json/JsonParser.cs +483 -0
- data/platform/wp7/RhoRubyLib/json/RJSONTokener.cs +406 -0
- data/platform/wp7/RhoRubyLib/logging/IRhoLogSink.cs +12 -0
- data/platform/wp7/RhoRubyLib/logging/RhoLogConf.cs +161 -0
- data/platform/wp7/RhoRubyLib/logging/RhoLogFileSink.cs +174 -0
- data/platform/wp7/RhoRubyLib/logging/RhoLogger.cs +320 -0
- data/platform/wp7/RhoRubyLib/net/AsyncHttp.cs +362 -0
- data/platform/wp7/RhoRubyLib/net/HttpServer.cs +466 -0
- data/platform/wp7/RhoRubyLib/net/NetRequest.cs +717 -0
- data/platform/wp7/RhoRubyLib/net/NetResponse.cs +64 -0
- data/platform/wp7/RhoRubyLib/net/URI.cs +187 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoAsyncHttp.cs +43 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoDatabase.cs +177 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoJSON.cs +39 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoKernelOps.cs +19 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoNativeBar.cs +117 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoSyncEngine.cs +199 -0
- data/platform/wp7/RhoRubyLib/rubyext/RhoWebView.cs +49 -0
- data/platform/wp7/RhoRubyLib/sync/ClientRegister.cs +142 -0
- data/platform/wp7/RhoRubyLib/sync/ISyncProtocol.cs +23 -0
- data/platform/wp7/RhoRubyLib/sync/ISyncStatusListener.cs +10 -0
- data/platform/wp7/RhoRubyLib/sync/SyncEngine.cs +1051 -0
- data/platform/wp7/RhoRubyLib/sync/SyncNotify.cs +651 -0
- data/platform/wp7/RhoRubyLib/sync/SyncProtocol_3.cs +79 -0
- data/platform/wp7/RhoRubyLib/sync/SyncSource.cs +1105 -0
- data/platform/wp7/RhoRubyLib/sync/SyncThread.cs +301 -0
- data/platform/wp7/WPApplication.sln +50 -0
- data/platform/wp7/WPApplication/App.xaml +19 -0
- data/platform/wp7/WPApplication/App.xaml.cs +211 -0
- data/platform/wp7/WPApplication/ApplicationIcon.png +0 -0
- data/platform/wp7/WPApplication/Background.png +0 -0
- data/platform/wp7/WPApplication/MainPage.xaml +44 -0
- data/platform/wp7/WPApplication/MainPage.xaml.cs +132 -0
- data/platform/wp7/WPApplication/Properties/AppManifest.xml +6 -0
- data/platform/wp7/WPApplication/Properties/AssemblyInfo.cs +35 -0
- data/platform/wp7/WPApplication/Properties/WMAppManifest.xml +32 -0
- data/platform/wp7/WPApplication/SplashScreenImage.jpg +0 -0
- data/platform/wp7/WPApplication/WPApplication.csproj +201 -0
- data/platform/wp7/WPApplication/WP_PlatformAdaptationLayer.cs +88 -0
- data/platform/wp7/WPApplication/app_manifest.txt +1 -0
- data/platform/wp7/WPApplication/readme.htm +40 -0
- data/platform/wp7/WPApplication/readme2.htm +37 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/edit.bb.erb +29 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/edit.erb +32 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/index.bb.erb +21 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/index.erb +26 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/model1.rb +10 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/model1_controller.rb +58 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/new.bb.erb +29 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/new.erb +31 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/show.bb.erb +26 -0
- data/platform/wp7/WPApplication/rho/apps/app/Model1/show.erb +28 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/controller.rb +75 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/home.bb.erb +17 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/home.erb +20 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/index.bb.erb +32 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/index.erb +30 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/login.bb.erb +35 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/login.erb +27 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/reset.bb.erb +15 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/reset.erb +17 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/wait.bb.erb +3 -0
- data/platform/wp7/WPApplication/rho/apps/app/Settings/wait.erb +5 -0
- data/platform/wp7/WPApplication/rho/apps/app/application.rb +16 -0
- data/platform/wp7/WPApplication/rho/apps/app/helpers/application_helper.rb +126 -0
- data/platform/wp7/WPApplication/rho/apps/app/helpers/browser_helper.rb +18 -0
- data/platform/wp7/WPApplication/rho/apps/app/index.bb.erb +26 -0
- data/platform/wp7/WPApplication/rho/apps/app/index.erb +26 -0
- data/platform/wp7/WPApplication/rho/apps/app/layout.erb +45 -0
- data/platform/wp7/WPApplication/rho/apps/app/loading.html +11 -0
- data/platform/wp7/WPApplication/rho/apps/app_manifest.txt +1 -0
- data/platform/wp7/WPApplication/rho/apps/public/css/android.css +330 -0
- data/platform/wp7/WPApplication/rho/apps/public/css/blackberry.css +115 -0
- data/platform/wp7/WPApplication/rho/apps/public/css/iphone.css +410 -0
- data/platform/wp7/WPApplication/rho/apps/public/css/windows_mobile.css +222 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/IUI_LICENSE.txt +21 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/btn_check_off.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/btn_check_on.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/btn_radio_off.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/btn_radio_on.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/disclosure.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/android/ic_menu_more.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/backButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/blueButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/cancel.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/grayButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/disclosure.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/disclosure_detail.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/backButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/blueButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/cancel.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/chevron.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/grayButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/listArrowSel.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/listGroup.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/loading.gif +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/on_off.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/pinstripes.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/selection.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/thumb.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/toggle.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/toggleOn.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/toolButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/toolbar.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/jqtouch/whiteButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/radiobutton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/select.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iphone/switch.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/iui-logo-touch-icon.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/listArrow.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/listArrowDown.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/listArrowSel.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/listGroup.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/loading.gif +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/pinstripes.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/right_button.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/selection.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/thumb.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/toggle.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/toggleOn.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/toolButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/toolButton_new.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/toolbar.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/images/whiteButton.png +0 -0
- data/platform/wp7/WPApplication/rho/apps/public/jqtouch/jqtouch-iphone.css +9 -0
- data/platform/wp7/WPApplication/rho/apps/public/jqtouch/jqtouch.css +374 -0
- data/platform/wp7/WPApplication/rho/apps/public/jqtouch/jqtouch.js +742 -0
- data/platform/wp7/WPApplication/rho/apps/public/jqtouch/jqtouch.transitions.js +60 -0
- data/platform/wp7/WPApplication/rho/apps/public/jqtouch/jquery.1.3.2.min.js +19 -0
- data/platform/wp7/WPApplication/rho/apps/public/js/application.js +1 -0
- data/platform/wp7/WPApplication/rho/apps/public/js/rho.js +4 -0
- data/platform/wp7/WPApplication/rho/apps/public/js/rhogeolocation-wm.js +59 -0
- data/platform/wp7/WPApplication/rho/apps/public/js/rhogeolocation.js +11 -0
- data/platform/wp7/WPApplication/rho/apps/rhoconfig.txt +32 -0
- data/platform/wp7/WPApplication/rhoconfig.txt +32 -0
- data/platform/wp7/WPApplication/windows_mobile.css +222 -0
- data/platform/wp7/build/wp.rake +261 -0
- data/platform/wp7/rhodes.sln +79 -0
- data/platform/wp7/rhodes/App.xaml +19 -0
- data/platform/wp7/rhodes/App.xaml.cs +144 -0
- data/platform/wp7/rhodes/Background.png +0 -0
- data/platform/wp7/rhodes/MainPage.xaml +44 -0
- data/platform/wp7/rhodes/MainPage.xaml.cs +98 -0
- data/platform/wp7/rhodes/Properties/AppManifest.xml +6 -0
- data/platform/wp7/rhodes/Properties/AssemblyInfo.cs +35 -0
- data/platform/wp7/rhodes/Properties/WMAppManifest.xml +31 -0
- data/platform/wp7/rhodes/Rhodes.csproj +127 -0
- data/platform/wp7/rhodes/SplashScreenImage.jpg +0 -0
- data/platform/wp7/rhodes/icon.png +0 -0
- data/platform/wp7/sqlite3/Properties/AssemblyInfo.cs +35 -0
- data/platform/wp7/sqlite3/SQLiteClient.cs +550 -0
- data/platform/wp7/sqlite3/SqliteWrapper/BtreeInt_h.cs +774 -0
- data/platform/wp7/sqlite3/SqliteWrapper/Btree_h.cs +280 -0
- data/platform/wp7/sqlite3/SqliteWrapper/ClassDiagram1.cd +1306 -0
- data/platform/wp7/sqlite3/SqliteWrapper/Delagates.cs +365 -0
- data/platform/wp7/sqlite3/SqliteWrapper/Hash_h.cs +133 -0
- data/platform/wp7/sqlite3/SqliteWrapper/VdbeInt_h.cs +620 -0
- data/platform/wp7/sqlite3/SqliteWrapper/Vdbe_h.cs +302 -0
- data/platform/wp7/sqlite3/SqliteWrapper/_Custom.cs +449 -0
- data/platform/wp7/sqlite3/SqliteWrapper/alter_c.cs +872 -0
- data/platform/wp7/sqlite3/SqliteWrapper/analyze_c.cs +757 -0
- data/platform/wp7/sqlite3/SqliteWrapper/attach_c.cs +628 -0
- data/platform/wp7/sqlite3/SqliteWrapper/auth_c.cs +268 -0
- data/platform/wp7/sqlite3/SqliteWrapper/backup_c.cs +737 -0
- data/platform/wp7/sqlite3/SqliteWrapper/bitvec_c.cs +509 -0
- data/platform/wp7/sqlite3/SqliteWrapper/btmutex_c.cs +379 -0
- data/platform/wp7/sqlite3/SqliteWrapper/btree_c.cs +9138 -0
- data/platform/wp7/sqlite3/SqliteWrapper/build_c.cs +4189 -0
- data/platform/wp7/sqlite3/SqliteWrapper/callback_c.cs +548 -0
- data/platform/wp7/sqlite3/SqliteWrapper/complete_c.cs +342 -0
- data/platform/wp7/sqlite3/SqliteWrapper/ctime_cs.cs +408 -0
- data/platform/wp7/sqlite3/SqliteWrapper/date_c.cs +1317 -0
- data/platform/wp7/sqlite3/SqliteWrapper/delete_c.cs +726 -0
- data/platform/wp7/sqlite3/SqliteWrapper/expr_c.cs +4406 -0
- data/platform/wp7/sqlite3/SqliteWrapper/fault_c.cs +115 -0
- data/platform/wp7/sqlite3/SqliteWrapper/fkey_c.cs +1330 -0
- data/platform/wp7/sqlite3/SqliteWrapper/func_c.cs +2025 -0
- data/platform/wp7/sqlite3/SqliteWrapper/global_c.cs +228 -0
- data/platform/wp7/sqlite3/SqliteWrapper/hash_c.cs +351 -0
- data/platform/wp7/sqlite3/SqliteWrapper/hwtime_c.cs +101 -0
- data/platform/wp7/sqlite3/SqliteWrapper/insert_c.cs +2122 -0
- data/platform/wp7/sqlite3/SqliteWrapper/journal_c.cs +247 -0
- data/platform/wp7/sqlite3/SqliteWrapper/keywordhash_h.cs +302 -0
- data/platform/wp7/sqlite3/SqliteWrapper/legacy_c.cs +223 -0
- data/platform/wp7/sqlite3/SqliteWrapper/loadext_c.cs +683 -0
- data/platform/wp7/sqlite3/SqliteWrapper/main_c.cs +2716 -0
- data/platform/wp7/sqlite3/SqliteWrapper/malloc_c.cs +977 -0
- data/platform/wp7/sqlite3/SqliteWrapper/mem_Pool.cs +394 -0
- data/platform/wp7/sqlite3/SqliteWrapper/memjournal_c.cs +315 -0
- data/platform/wp7/sqlite3/SqliteWrapper/mutex_c.cs +182 -0
- data/platform/wp7/sqlite3/SqliteWrapper/mutex_h.cs +91 -0
- data/platform/wp7/sqlite3/SqliteWrapper/mutex_noop_c.cs +202 -0
- data/platform/wp7/sqlite3/SqliteWrapper/mutex_w32.cs +344 -0
- data/platform/wp7/sqlite3/SqliteWrapper/notify_c.cs +347 -0
- data/platform/wp7/sqlite3/SqliteWrapper/opcodes_c.cs +171 -0
- data/platform/wp7/sqlite3/SqliteWrapper/opcodes_h.cs +346 -0
- data/platform/wp7/sqlite3/SqliteWrapper/os_c.cs +367 -0
- data/platform/wp7/sqlite3/SqliteWrapper/os_common_h.cs +174 -0
- data/platform/wp7/sqlite3/SqliteWrapper/os_h.cs +295 -0
- data/platform/wp7/sqlite3/SqliteWrapper/os_win_c.cs +1255 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pager_c.cs +6078 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pager_h.cs +188 -0
- data/platform/wp7/sqlite3/SqliteWrapper/parse_c.cs +4045 -0
- data/platform/wp7/sqlite3/SqliteWrapper/parse_h.cs +331 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pcache1_c.cs +969 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pcache_c.cs +712 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pcache_h.cs +213 -0
- data/platform/wp7/sqlite3/SqliteWrapper/pragma_c.cs +1767 -0
- data/platform/wp7/sqlite3/SqliteWrapper/prepare_c.cs +1015 -0
- data/platform/wp7/sqlite3/SqliteWrapper/printf_c.cs +1300 -0
- data/platform/wp7/sqlite3/SqliteWrapper/random_c.cs +201 -0
- data/platform/wp7/sqlite3/SqliteWrapper/resolve_c.cs +1396 -0
- data/platform/wp7/sqlite3/SqliteWrapper/rowset_c.cs +519 -0
- data/platform/wp7/sqlite3/SqliteWrapper/select_c.cs +4878 -0
- data/platform/wp7/sqlite3/SqliteWrapper/sqlite3_h.cs +6253 -0
- data/platform/wp7/sqlite3/SqliteWrapper/sqlite3ext_h.cs +397 -0
- data/platform/wp7/sqlite3/SqliteWrapper/sqliteInt_h.cs +4075 -0
- data/platform/wp7/sqlite3/SqliteWrapper/sqliteLimit_h.cs +214 -0
- data/platform/wp7/sqlite3/SqliteWrapper/sqliteicu_h.cs +39 -0
- data/platform/wp7/sqlite3/SqliteWrapper/status_c.cs +155 -0
- data/platform/wp7/sqlite3/SqliteWrapper/table_c.cs +222 -0
- data/platform/wp7/sqlite3/SqliteWrapper/tokenize_c.cs +673 -0
- data/platform/wp7/sqlite3/SqliteWrapper/trigger_c.cs +1219 -0
- data/platform/wp7/sqlite3/SqliteWrapper/update_c.cs +766 -0
- data/platform/wp7/sqlite3/SqliteWrapper/utf_c.cs +612 -0
- data/platform/wp7/sqlite3/SqliteWrapper/util_c.cs +1476 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vacuum_c.cs +382 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbe_c.cs +6566 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbeapi_c.cs +1557 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbeaux_c.cs +4019 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbeblob_c.cs +396 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbemem_c.cs +1480 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vdbetrace_c.cs +181 -0
- data/platform/wp7/sqlite3/SqliteWrapper/vtab_c.cs +957 -0
- data/platform/wp7/sqlite3/SqliteWrapper/walker_c.cs +174 -0
- data/platform/wp7/sqlite3/SqliteWrapper/where_c.cs +4651 -0
- data/platform/wp7/sqlite3/sqlite3.csproj +155 -0
- data/rakefile.rb +60 -2
- data/res/build-tools/7za.exe +0 -0
- data/res/build-tools/RhoAppRunner.exe +0 -0
- data/res/build-tools/xruby-0.3.3.jar +0 -0
- data/res/generators/rhogen.rb +9 -1
- data/res/generators/templates/application/app/Settings/reset.erb +1 -1
- data/res/generators/templates/application/app/layout.erb +17 -10
- data/res/generators/templates/application/build.yml +5 -3
- data/res/generators/templates/application/public/jqtouch/changes.txt +20 -0
- data/res/generators/templates/application/public/jqtouch/jqtouch.js +12 -4
- data/res/generators/templates/application/public/jqtouch/jquery.1.3.2.min.js +1 -1
- data/res/generators/templates/application/public/js/wp7.js +7 -0
- data/res/generators/templates/model/controller.rb +5 -6
- data/rhobuild.yml.example +1 -0
- data/rhodes.gemspec +2 -1
- data/spec/framework_spec/app/spec/core/dir/close_spec.rb +1 -1
- data/spec/framework_spec/app/spec/core/dir/shared/pwd.rb +13 -11
- data/spec/framework_spec/app/spec/core/env/shared/store.rb +12 -10
- data/spec/framework_spec/app/spec/core/env/update_spec.rb +1 -0
- data/spec/framework_spec/app/spec/core/file/expand_path_spec.rb +3 -2
- data/spec/framework_spec/app/spec/core/file/fixtures/file_types.rb +7 -1
- data/spec/framework_spec/app/spec/core/file/flock_spec.rb +8 -1
- data/spec/framework_spec/app/spec/core/file/ftype_spec.rb +5 -3
- data/spec/framework_spec/app/spec/core/file/lchmod_spec.rb +1 -1
- data/spec/framework_spec/app/spec/core/file/setgid_spec.rb +1 -1
- data/spec/framework_spec/app/spec/core/file/setuid_spec.rb +1 -1
- data/spec/framework_spec/app/spec/core/file/stat/ftype_spec.rb +6 -4
- data/spec/framework_spec/app/spec/core/file/truncate_spec.rb +5 -1
- data/spec/framework_spec/app/spec/core/float/to_s_spec.rb +1 -1
- data/spec/framework_spec/app/spec/core/process/gid_spec.rb +5 -3
- data/spec/framework_spec/app/spec/core/process/groups_spec.rb +11 -9
- data/spec/framework_spec/app/spec/core/process/uid_spec.rb +5 -3
- data/spec/framework_spec/app/spec/language/execution_spec.rb +10 -6
- data/spec/framework_spec/app/spec/shared/file/directory.rb +6 -1
- data/spec/framework_spec/app/spec/shared/file/executable.rb +7 -1
- data/spec/framework_spec/app/spec/shared/file/file.rb +6 -1
- data/spec/framework_spec/app/spec/shared/file/readable.rb +13 -4
- data/spec/framework_spec/app/spec/shared/file/writable.rb +6 -1
- data/spec/phone_spec/app/spec/rho_controller_spec.rb +11 -0
- data/spec/phone_spec/app/spec/rho_spec.rb +11 -0
- data/spec/phone_spec/app/spec/rhom_object_spec.rb +102 -6
- data/spec/phone_spec/app/spec/string/end_with_spec.rb +4 -1
- data/spec/phone_spec/app/spec/string/slice_spec.rb +5 -1
- data/spec/phone_spec/app/spec/string/start_with_spec.rb +4 -0
- data/spec/phone_spec/app/spec/syncengine_spec.rb +73 -6
- data/spec/phone_spec/app/spec_runner.rb +7 -3
- metadata +380 -41
- data/Manifest.txt +0 -5819
- data/platform/bb/Hsqldb/Hsqldb.cso +0 -5
- data/platform/bb/Hsqldb/Hsqldb.jdp +0 -197
- data/platform/bb/RhoBundle/RhoBundle.cso +0 -5
- data/platform/bb/RhoBundle/RhoBundle.jdp +0 -42
- data/platform/bb/RubyVM/RubyVM.cso +0 -5
- data/platform/bb/RubyVM/RubyVM.jdp +0 -467
- data/platform/bb/rhodes/rhodes.csl +0 -3
- data/platform/bb/rhodes/rhodes.cso +0 -5
- data/platform/bb/rhodes/rhodes.jdp +0 -104
@@ -0,0 +1,223 @@
|
|
1
|
+
using System;
|
2
|
+
using System.Diagnostics;
|
3
|
+
using System.Text;
|
4
|
+
|
5
|
+
namespace Community.CsharpSqlite
|
6
|
+
{
|
7
|
+
using sqlite3_callback = Sqlite3.dxCallback;
|
8
|
+
using sqlite3_stmt = Sqlite3.Vdbe;
|
9
|
+
|
10
|
+
public partial class Sqlite3
|
11
|
+
{
|
12
|
+
/*
|
13
|
+
** 2001 September 15
|
14
|
+
**
|
15
|
+
** The author disclaims copyright to this source code. In place of
|
16
|
+
** a legal notice, here is a blessing:
|
17
|
+
**
|
18
|
+
** May you do good and not evil.
|
19
|
+
** May you find forgiveness for yourself and forgive others.
|
20
|
+
** May you share freely, never taking more than you give.
|
21
|
+
**
|
22
|
+
*************************************************************************
|
23
|
+
** Main file for the SQLite library. The routines in this file
|
24
|
+
** implement the programmer interface to the library. Routines in
|
25
|
+
** other files are for internal use by SQLite and should not be
|
26
|
+
** accessed by users of the library.
|
27
|
+
*************************************************************************
|
28
|
+
** Included in SQLite3 port to C#-SQLite; 2008 Noah B Hart
|
29
|
+
** C#-SQLite is an independent reimplementation of the SQLite software library
|
30
|
+
**
|
31
|
+
** SQLITE_SOURCE_ID: 2010-03-09 19:31:43 4ae453ea7be69018d8c16eb8dabe05617397dc4d
|
32
|
+
**
|
33
|
+
** $Header$
|
34
|
+
*************************************************************************
|
35
|
+
*/
|
36
|
+
|
37
|
+
//#include "sqliteInt.h"
|
38
|
+
|
39
|
+
/*
|
40
|
+
** Execute SQL code. Return one of the SQLITE_ success/failure
|
41
|
+
** codes. Also write an error message into memory obtained from
|
42
|
+
** malloc() and make pzErrMsg point to that message.
|
43
|
+
**
|
44
|
+
** If the SQL is a query, then for each row in the query result
|
45
|
+
** the xCallback() function is called. pArg becomes the first
|
46
|
+
** argument to xCallback(). If xCallback=NULL then no callback
|
47
|
+
** is invoked, even for queries.
|
48
|
+
*/
|
49
|
+
//C# Alias
|
50
|
+
static public int exec( sqlite3 db, /* The database on which the SQL executes */ string zSql, /* The SQL to be executed */ int NoCallback, int NoArgs, int NoErrors )
|
51
|
+
{ string Errors = ""; return sqlite3_exec( db, zSql, null, null, ref Errors ); }
|
52
|
+
|
53
|
+
static public int exec( sqlite3 db, /* The database on which the SQL executes */ string zSql, /* The SQL to be executed */ sqlite3_callback xCallback, /* Invoke this callback routine */ object pArg, /* First argument to xCallback() */ int NoErrors )
|
54
|
+
{ string Errors = ""; return sqlite3_exec( db, zSql, xCallback, pArg, ref Errors ); }
|
55
|
+
static public int exec( sqlite3 db, /* The database on which the SQL executes */ string zSql, /* The SQL to be executed */ sqlite3_callback xCallback, /* Invoke this callback routine */ object pArg, /* First argument to xCallback() */ ref string pzErrMsg /* Write error messages here */)
|
56
|
+
{ return sqlite3_exec(db, zSql, xCallback, pArg, ref pzErrMsg); }
|
57
|
+
|
58
|
+
//OVERLOADS
|
59
|
+
static public int sqlite3_exec(
|
60
|
+
sqlite3 db, /* The database on which the SQL executes */
|
61
|
+
string zSql, /* The SQL to be executed */
|
62
|
+
int NoCallback, int NoArgs, int NoErrors
|
63
|
+
)
|
64
|
+
{
|
65
|
+
string Errors = "";
|
66
|
+
return sqlite3_exec( db, zSql, null, null, ref Errors );
|
67
|
+
}
|
68
|
+
|
69
|
+
static public int sqlite3_exec(
|
70
|
+
sqlite3 db, /* The database on which the SQL executes */
|
71
|
+
string zSql, /* The SQL to be executed */
|
72
|
+
sqlite3_callback xCallback, /* Invoke this callback routine */
|
73
|
+
object pArg, /* First argument to xCallback() */
|
74
|
+
int NoErrors
|
75
|
+
)
|
76
|
+
{
|
77
|
+
string Errors = "";
|
78
|
+
return sqlite3_exec( db, zSql, xCallback, pArg, ref Errors );
|
79
|
+
}
|
80
|
+
static public int sqlite3_exec(
|
81
|
+
sqlite3 db, /* The database on which the SQL executes */
|
82
|
+
string zSql, /* The SQL to be executed */
|
83
|
+
sqlite3_callback xCallback, /* Invoke this callback routine */
|
84
|
+
object pArg, /* First argument to xCallback() */
|
85
|
+
ref string pzErrMsg /* Write error messages here */
|
86
|
+
)
|
87
|
+
{
|
88
|
+
|
89
|
+
int rc = SQLITE_OK; /* Return code */
|
90
|
+
string zLeftover = ""; /* Tail of unprocessed SQL */
|
91
|
+
sqlite3_stmt pStmt = null; /* The current SQL statement */
|
92
|
+
string[] azCols = null; /* Names of result columns */
|
93
|
+
int nRetry = 0; /* Number of retry attempts */
|
94
|
+
int callbackIsInit; /* True if callback data is initialized */
|
95
|
+
|
96
|
+
if (!sqlite3SafetyCheckOk(db)) return SQLITE_MISUSE_BKPT();
|
97
|
+
|
98
|
+
if ( zSql == null ) zSql = "";
|
99
|
+
|
100
|
+
sqlite3_mutex_enter( db.mutex );
|
101
|
+
sqlite3Error( db, SQLITE_OK, 0 );
|
102
|
+
while ( ( rc == SQLITE_OK || ( rc == SQLITE_SCHEMA && ( ++nRetry ) < 2 ) ) && zSql != "" )
|
103
|
+
{
|
104
|
+
int nCol;
|
105
|
+
string[] azVals = null;
|
106
|
+
|
107
|
+
pStmt = null;
|
108
|
+
rc = sqlite3_prepare( db, zSql, -1, ref pStmt, ref zLeftover );
|
109
|
+
Debug.Assert( rc == SQLITE_OK || pStmt == null );
|
110
|
+
if ( rc != SQLITE_OK )
|
111
|
+
{
|
112
|
+
continue;
|
113
|
+
}
|
114
|
+
if ( pStmt == null )
|
115
|
+
{
|
116
|
+
/* this happens for a comment or white-space */
|
117
|
+
zSql = zLeftover;
|
118
|
+
continue;
|
119
|
+
}
|
120
|
+
|
121
|
+
callbackIsInit = 0;
|
122
|
+
nCol = sqlite3_column_count( pStmt );
|
123
|
+
|
124
|
+
while ( true )
|
125
|
+
{
|
126
|
+
int i;
|
127
|
+
rc = sqlite3_step( pStmt );
|
128
|
+
|
129
|
+
/* Invoke the callback function if required */
|
130
|
+
if ( xCallback != null && ( SQLITE_ROW == rc ||
|
131
|
+
( SQLITE_DONE == rc && callbackIsInit == 0
|
132
|
+
&& ( db.flags & SQLITE_NullCallback ) != 0 ) ) )
|
133
|
+
{
|
134
|
+
if ( 0 == callbackIsInit )
|
135
|
+
{
|
136
|
+
azCols = new string[nCol];//sqlite3DbMallocZero(db, 2*nCol*sizeof(const char*) + 1);
|
137
|
+
//if ( azCols == null )
|
138
|
+
//{
|
139
|
+
// goto exec_out;
|
140
|
+
//}
|
141
|
+
for ( i = 0; i < nCol; i++ )
|
142
|
+
{
|
143
|
+
azCols[i] = sqlite3_column_name( pStmt, i );
|
144
|
+
/* sqlite3VdbeSetColName() installs column names as UTF8
|
145
|
+
** strings so there is no way for sqlite3_column_name() to fail. */
|
146
|
+
Debug.Assert( azCols[i] != null );
|
147
|
+
}
|
148
|
+
callbackIsInit = 1;
|
149
|
+
}
|
150
|
+
if ( rc == SQLITE_ROW )
|
151
|
+
{
|
152
|
+
azVals = new string[nCol];// azCols[nCol];
|
153
|
+
for ( i = 0; i < nCol; i++ )
|
154
|
+
{
|
155
|
+
azVals[i] = sqlite3_column_text( pStmt, i );
|
156
|
+
if ( azVals[i] == null && sqlite3_column_type( pStmt, i ) != SQLITE_NULL )
|
157
|
+
{
|
158
|
+
//db.mallocFailed = 1;
|
159
|
+
//goto exec_out;
|
160
|
+
}
|
161
|
+
}
|
162
|
+
}
|
163
|
+
if ( xCallback( pArg, nCol, azVals, azCols ) != 0 )
|
164
|
+
{
|
165
|
+
rc = SQLITE_ABORT;
|
166
|
+
sqlite3VdbeFinalize( pStmt );
|
167
|
+
pStmt = null;
|
168
|
+
sqlite3Error( db, SQLITE_ABORT, 0 );
|
169
|
+
goto exec_out;
|
170
|
+
}
|
171
|
+
}
|
172
|
+
|
173
|
+
if ( rc != SQLITE_ROW )
|
174
|
+
{
|
175
|
+
rc = sqlite3VdbeFinalize( pStmt );
|
176
|
+
pStmt = null;
|
177
|
+
if ( rc != SQLITE_SCHEMA )
|
178
|
+
{
|
179
|
+
nRetry = 0;
|
180
|
+
if ( ( zSql = zLeftover ) != "" )
|
181
|
+
{
|
182
|
+
int zindex = 0;
|
183
|
+
while ( zindex < zSql.Length && sqlite3Isspace( zSql[zindex] ) ) zindex++;
|
184
|
+
if ( zindex != 0 ) zSql = zindex < zSql.Length ? zSql.Substring( zindex ) : "";
|
185
|
+
}
|
186
|
+
}
|
187
|
+
break;
|
188
|
+
}
|
189
|
+
}
|
190
|
+
|
191
|
+
sqlite3DbFree( db, ref azCols );
|
192
|
+
azCols = null;
|
193
|
+
}
|
194
|
+
|
195
|
+
exec_out:
|
196
|
+
if ( pStmt != null ) sqlite3VdbeFinalize( pStmt );
|
197
|
+
sqlite3DbFree( db, ref azCols );
|
198
|
+
|
199
|
+
rc = sqlite3ApiExit( db, rc );
|
200
|
+
if ( rc != SQLITE_OK && ALWAYS( rc == sqlite3_errcode( db ) ) && pzErrMsg != null )
|
201
|
+
{
|
202
|
+
//int nErrMsg = 1 + sqlite3Strlen30(sqlite3_errmsg(db));
|
203
|
+
//pzErrMsg = sqlite3Malloc(nErrMsg);
|
204
|
+
//if (pzErrMsg)
|
205
|
+
//{
|
206
|
+
// memcpy(pzErrMsg, sqlite3_errmsg(db), nErrMsg);
|
207
|
+
//}else{
|
208
|
+
//rc = SQLITE_NOMEM;
|
209
|
+
//sqlite3Error(db, SQLITE_NOMEM, 0);
|
210
|
+
//}
|
211
|
+
pzErrMsg = sqlite3_errmsg( db );
|
212
|
+
}
|
213
|
+
else if ( pzErrMsg != "" )
|
214
|
+
{
|
215
|
+
pzErrMsg = "";
|
216
|
+
}
|
217
|
+
|
218
|
+
Debug.Assert( ( rc & db.errMask ) == rc );
|
219
|
+
sqlite3_mutex_leave( db.mutex );
|
220
|
+
return rc;
|
221
|
+
}
|
222
|
+
}
|
223
|
+
}
|
@@ -0,0 +1,683 @@
|
|
1
|
+
using System;
|
2
|
+
using System.Diagnostics;
|
3
|
+
using HANDLE = System.IntPtr;
|
4
|
+
|
5
|
+
namespace Community.CsharpSqlite
|
6
|
+
{
|
7
|
+
public partial class Sqlite3
|
8
|
+
{
|
9
|
+
/*
|
10
|
+
** 2006 June 7
|
11
|
+
**
|
12
|
+
** The author disclaims copyright to this source code. In place of
|
13
|
+
** a legal notice, here is a blessing:
|
14
|
+
**
|
15
|
+
** May you do good and not evil.
|
16
|
+
** May you find forgiveness for yourself and forgive others.
|
17
|
+
** May you share freely, never taking more than you give.
|
18
|
+
**
|
19
|
+
*************************************************************************
|
20
|
+
** This file contains code used to dynamically load extensions into
|
21
|
+
** the SQLite library.
|
22
|
+
*************************************************************************
|
23
|
+
** Included in SQLite3 port to C#-SQLite; 2008 Noah B Hart
|
24
|
+
** C#-SQLite is an independent reimplementation of the SQLite software library
|
25
|
+
**
|
26
|
+
** SQLITE_SOURCE_ID: 2009-12-07 16:39:13 1ed88e9d01e9eda5cbc622e7614277f29bcc551c
|
27
|
+
**
|
28
|
+
** $Header$
|
29
|
+
*************************************************************************
|
30
|
+
*/
|
31
|
+
#if !SQLITE_CORE
|
32
|
+
//#define SQLITE_CORE 1 /* Disable the API redefinition in sqlite3ext.h */
|
33
|
+
const int SQLITE_CORE = 1;
|
34
|
+
#endif
|
35
|
+
//#include "sqlite3ext.h"
|
36
|
+
//#include "sqliteInt.h"
|
37
|
+
//#include <string.h>
|
38
|
+
|
39
|
+
#if !SQLITE_OMIT_LOAD_EXTENSION
|
40
|
+
|
41
|
+
/*
|
42
|
+
** Some API routines are omitted when various features are
|
43
|
+
** excluded from a build of SQLite. Substitute a NULL pointer
|
44
|
+
** for any missing APIs.
|
45
|
+
*/
|
46
|
+
#if !SQLITE_ENABLE_COLUMN_METADATA
|
47
|
+
//# define sqlite3_column_database_name 0
|
48
|
+
//# define sqlite3_column_database_name16 0
|
49
|
+
//# define sqlite3_column_table_name 0
|
50
|
+
//# define sqlite3_column_table_name16 0
|
51
|
+
//# define sqlite3_column_origin_name 0
|
52
|
+
//# define sqlite3_column_origin_name16 0
|
53
|
+
//# define sqlite3_table_column_metadata 0
|
54
|
+
#endif
|
55
|
+
|
56
|
+
#if SQLITE_OMIT_AUTHORIZATION
|
57
|
+
//# define sqlite3_set_authorizer 0
|
58
|
+
#endif
|
59
|
+
|
60
|
+
#if SQLITE_OMIT_UTF16
|
61
|
+
//# define sqlite3_bind_text16 0
|
62
|
+
//# define sqlite3_collation_needed16 0
|
63
|
+
//# define sqlite3_column_decltype16 0
|
64
|
+
//# define sqlite3_column_name16 0
|
65
|
+
//# define sqlite3_column_text16 0
|
66
|
+
//# define sqlite3_complete16 0
|
67
|
+
//# define sqlite3_create_collation16 0
|
68
|
+
//# define sqlite3_create_function16 0
|
69
|
+
//# define sqlite3_errmsg16 0
|
70
|
+
static string sqlite3_errmsg16( sqlite3 db ) { return ""; }
|
71
|
+
//# define sqlite3_open16 0
|
72
|
+
//# define sqlite3_prepare16 0
|
73
|
+
//# define sqlite3_prepare16_v2 0
|
74
|
+
//# define sqlite3_result_error16 0
|
75
|
+
//# define sqlite3_result_text16 0
|
76
|
+
static void sqlite3_result_text16( sqlite3_context pCtx, string z, int n, dxDel xDel ) { }
|
77
|
+
//# define sqlite3_result_text16be 0
|
78
|
+
//# define sqlite3_result_text16le 0
|
79
|
+
//# define sqlite3_value_text16 0
|
80
|
+
//# define sqlite3_value_text16be 0
|
81
|
+
//# define sqlite3_value_text16le 0
|
82
|
+
//# define sqlite3_column_database_name16 0
|
83
|
+
//# define sqlite3_column_table_name16 0
|
84
|
+
//# define sqlite3_column_origin_name16 0
|
85
|
+
#endif
|
86
|
+
|
87
|
+
#if SQLITE_OMIT_COMPLETE
|
88
|
+
//# define sqlite3_complete 0
|
89
|
+
//# define sqlite3_complete16 0
|
90
|
+
#endif
|
91
|
+
|
92
|
+
#if SQLITE_OMIT_PROGRESS_CALLBACK
|
93
|
+
//# define sqlite3_progress_handler 0
|
94
|
+
static void sqlite3_progress_handler (sqlite3 db, int nOps, dxProgress xProgress, object pArg){}
|
95
|
+
#endif
|
96
|
+
|
97
|
+
#if SQLITE_OMIT_VIRTUALTABLE
|
98
|
+
//# define sqlite3_create_module 0
|
99
|
+
//# define sqlite3_create_module_v2 0
|
100
|
+
//# define sqlite3_declare_vtab 0
|
101
|
+
#endif
|
102
|
+
|
103
|
+
#if SQLITE_OMIT_SHARED_CACHE
|
104
|
+
//# define sqlite3_enable_shared_cache 0
|
105
|
+
#endif
|
106
|
+
|
107
|
+
#if SQLITE_OMIT_TRACE
|
108
|
+
//# define sqlite3_profile 0
|
109
|
+
//# define sqlite3_trace 0
|
110
|
+
#endif
|
111
|
+
|
112
|
+
#if SQLITE_OMIT_GET_TABLE
|
113
|
+
//# define //sqlite3_free_table 0
|
114
|
+
//# define sqlite3_get_table 0
|
115
|
+
static public int sqlite3_get_table(
|
116
|
+
sqlite3 db, /* An open database */
|
117
|
+
string zSql, /* SQL to be evaluated */
|
118
|
+
ref string[] pazResult, /* Results of the query */
|
119
|
+
ref int pnRow, /* Number of result rows written here */
|
120
|
+
ref int pnColumn, /* Number of result columns written here */
|
121
|
+
ref string pzErrmsg /* Error msg written here */
|
122
|
+
) { return 0; }
|
123
|
+
#endif
|
124
|
+
|
125
|
+
#if SQLITE_OMIT_INCRBLOB
|
126
|
+
//#define sqlite3_bind_zeroblob 0
|
127
|
+
//#define sqlite3_blob_bytes 0
|
128
|
+
//#define sqlite3_blob_close 0
|
129
|
+
//#define sqlite3_blob_open 0
|
130
|
+
//#define sqlite3_blob_read 0
|
131
|
+
//#define sqlite3_blob_write 0
|
132
|
+
#endif
|
133
|
+
|
134
|
+
/*
|
135
|
+
** The following structure contains pointers to all SQLite API routines.
|
136
|
+
** A pointer to this structure is passed into extensions when they are
|
137
|
+
** loaded so that the extension can make calls back into the SQLite
|
138
|
+
** library.
|
139
|
+
**
|
140
|
+
** When adding new APIs, add them to the bottom of this structure
|
141
|
+
** in order to preserve backwards compatibility.
|
142
|
+
**
|
143
|
+
** Extensions that use newer APIs should first call the
|
144
|
+
** sqlite3_libversion_number() to make sure that the API they
|
145
|
+
** intend to use is supported by the library. Extensions should
|
146
|
+
** also check to make sure that the pointer to the function is
|
147
|
+
** not NULL before calling it.
|
148
|
+
*/
|
149
|
+
static sqlite3_api_routines sqlite3Apis = new sqlite3_api_routines();
|
150
|
+
//{
|
151
|
+
// sqlite3_aggregate_context,
|
152
|
+
#if !SQLITE_OMIT_DEPRECATED
|
153
|
+
/ sqlite3_aggregate_count,
|
154
|
+
#else
|
155
|
+
// 0,
|
156
|
+
#endif
|
157
|
+
// sqlite3_bind_blob,
|
158
|
+
// sqlite3_bind_double,
|
159
|
+
// sqlite3_bind_int,
|
160
|
+
// sqlite3_bind_int64,
|
161
|
+
// sqlite3_bind_null,
|
162
|
+
// sqlite3_bind_parameter_count,
|
163
|
+
// sqlite3_bind_parameter_index,
|
164
|
+
// sqlite3_bind_parameter_name,
|
165
|
+
// sqlite3_bind_text,
|
166
|
+
// sqlite3_bind_text16,
|
167
|
+
// sqlite3_bind_value,
|
168
|
+
// sqlite3_busy_handler,
|
169
|
+
// sqlite3_busy_timeout,
|
170
|
+
// sqlite3_changes,
|
171
|
+
// sqlite3_close,
|
172
|
+
// sqlite3_collation_needed,
|
173
|
+
// sqlite3_collation_needed16,
|
174
|
+
// sqlite3_column_blob,
|
175
|
+
// sqlite3_column_bytes,
|
176
|
+
// sqlite3_column_bytes16,
|
177
|
+
// sqlite3_column_count,
|
178
|
+
// sqlite3_column_database_name,
|
179
|
+
// sqlite3_column_database_name16,
|
180
|
+
// sqlite3_column_decltype,
|
181
|
+
// sqlite3_column_decltype16,
|
182
|
+
// sqlite3_column_double,
|
183
|
+
// sqlite3_column_int,
|
184
|
+
// sqlite3_column_int64,
|
185
|
+
// sqlite3_column_name,
|
186
|
+
// sqlite3_column_name16,
|
187
|
+
// sqlite3_column_origin_name,
|
188
|
+
// sqlite3_column_origin_name16,
|
189
|
+
// sqlite3_column_table_name,
|
190
|
+
// sqlite3_column_table_name16,
|
191
|
+
// sqlite3_column_text,
|
192
|
+
// sqlite3_column_text16,
|
193
|
+
// sqlite3_column_type,
|
194
|
+
// sqlite3_column_value,
|
195
|
+
// sqlite3_commit_hook,
|
196
|
+
// sqlite3_complete,
|
197
|
+
// sqlite3_complete16,
|
198
|
+
// sqlite3_create_collation,
|
199
|
+
// sqlite3_create_collation16,
|
200
|
+
// sqlite3_create_function,
|
201
|
+
// sqlite3_create_function16,
|
202
|
+
// sqlite3_create_module,
|
203
|
+
// sqlite3_data_count,
|
204
|
+
// sqlite3_db_handle,
|
205
|
+
// sqlite3_declare_vtab,
|
206
|
+
// sqlite3_enable_shared_cache,
|
207
|
+
// sqlite3_errcode,
|
208
|
+
// sqlite3_errmsg,
|
209
|
+
// sqlite3_errmsg16,
|
210
|
+
// sqlite3_exec,
|
211
|
+
#if !SQLITE_OMIT_DEPRECATED
|
212
|
+
//sqlite3_expired,
|
213
|
+
#else
|
214
|
+
//0,
|
215
|
+
#endif
|
216
|
+
// sqlite3_finalize,
|
217
|
+
// //sqlite3_free,
|
218
|
+
// //sqlite3_free_table,
|
219
|
+
// sqlite3_get_autocommit,
|
220
|
+
// sqlite3_get_auxdata,
|
221
|
+
// sqlite3_get_table,
|
222
|
+
// 0, /* Was sqlite3_global_recover(), but that function is deprecated */
|
223
|
+
// sqlite3_interrupt,
|
224
|
+
// sqlite3_last_insert_rowid,
|
225
|
+
// sqlite3_libversion,
|
226
|
+
// sqlite3_libversion_number,
|
227
|
+
// sqlite3_malloc,
|
228
|
+
// sqlite3_mprintf,
|
229
|
+
// sqlite3_open,
|
230
|
+
// sqlite3_open16,
|
231
|
+
// sqlite3_prepare,
|
232
|
+
// sqlite3_prepare16,
|
233
|
+
// sqlite3_profile,
|
234
|
+
// sqlite3_progress_handler,
|
235
|
+
// sqlite3_realloc,
|
236
|
+
// sqlite3_reset,
|
237
|
+
// sqlite3_result_blob,
|
238
|
+
// sqlite3_result_double,
|
239
|
+
// sqlite3_result_error,
|
240
|
+
// sqlite3_result_error16,
|
241
|
+
// sqlite3_result_int,
|
242
|
+
// sqlite3_result_int64,
|
243
|
+
// sqlite3_result_null,
|
244
|
+
// sqlite3_result_text,
|
245
|
+
// sqlite3_result_text16,
|
246
|
+
// sqlite3_result_text16be,
|
247
|
+
// sqlite3_result_text16le,
|
248
|
+
// sqlite3_result_value,
|
249
|
+
// sqlite3_rollback_hook,
|
250
|
+
// sqlite3_set_authorizer,
|
251
|
+
// sqlite3_set_auxdata,
|
252
|
+
// sqlite3_snprintf,
|
253
|
+
// sqlite3_step,
|
254
|
+
// sqlite3_table_column_metadata,
|
255
|
+
#if !SQLITE_OMIT_DEPRECATED
|
256
|
+
//sqlite3_thread_cleanup,
|
257
|
+
#else
|
258
|
+
// 0,
|
259
|
+
#endif
|
260
|
+
// sqlite3_total_changes,
|
261
|
+
// sqlite3_trace,
|
262
|
+
#if !SQLITE_OMIT_DEPRECATED
|
263
|
+
//sqlite3_transfer_bindings,
|
264
|
+
#else
|
265
|
+
// 0,
|
266
|
+
#endif
|
267
|
+
// sqlite3_update_hook,
|
268
|
+
// sqlite3_user_data,
|
269
|
+
// sqlite3_value_blob,
|
270
|
+
// sqlite3_value_bytes,
|
271
|
+
// sqlite3_value_bytes16,
|
272
|
+
// sqlite3_value_double,
|
273
|
+
// sqlite3_value_int,
|
274
|
+
// sqlite3_value_int64,
|
275
|
+
// sqlite3_value_numeric_type,
|
276
|
+
// sqlite3_value_text,
|
277
|
+
// sqlite3_value_text16,
|
278
|
+
// sqlite3_value_text16be,
|
279
|
+
// sqlite3_value_text16le,
|
280
|
+
// sqlite3_value_type,
|
281
|
+
// sqlite3_vmprintf,
|
282
|
+
// /*
|
283
|
+
// ** The original API set ends here. All extensions can call any
|
284
|
+
// ** of the APIs above provided that the pointer is not NULL. But
|
285
|
+
// ** before calling APIs that follow, extension should check the
|
286
|
+
// ** sqlite3_libversion_number() to make sure they are dealing with
|
287
|
+
// ** a library that is new enough to support that API.
|
288
|
+
// *************************************************************************
|
289
|
+
// */
|
290
|
+
// sqlite3_overload_function,
|
291
|
+
|
292
|
+
// /*
|
293
|
+
// ** Added after 3.3.13
|
294
|
+
// */
|
295
|
+
// sqlite3_prepare_v2,
|
296
|
+
// sqlite3_prepare16_v2,
|
297
|
+
// sqlite3_clear_bindings,
|
298
|
+
|
299
|
+
// /*
|
300
|
+
// ** Added for 3.4.1
|
301
|
+
// */
|
302
|
+
// sqlite3_create_module_v2,
|
303
|
+
|
304
|
+
// /*
|
305
|
+
// ** Added for 3.5.0
|
306
|
+
// */
|
307
|
+
// sqlite3_bind_zeroblob,
|
308
|
+
// sqlite3_blob_bytes,
|
309
|
+
// sqlite3_blob_close,
|
310
|
+
// sqlite3_blob_open,
|
311
|
+
// sqlite3_blob_read,
|
312
|
+
// sqlite3_blob_write,
|
313
|
+
// sqlite3_create_collation_v2,
|
314
|
+
// sqlite3_file_control,
|
315
|
+
// sqlite3_memory_highwater,
|
316
|
+
// sqlite3_memory_used,
|
317
|
+
#if SQLITE_MUTEX_OMIT
|
318
|
+
// 0,
|
319
|
+
// 0,
|
320
|
+
// 0,
|
321
|
+
// 0,
|
322
|
+
// 0,
|
323
|
+
#else
|
324
|
+
// sqlite3MutexAlloc,
|
325
|
+
// sqlite3_mutex_enter,
|
326
|
+
// sqlite3_mutex_free,
|
327
|
+
// sqlite3_mutex_leave,
|
328
|
+
// sqlite3_mutex_try,
|
329
|
+
#endif
|
330
|
+
// sqlite3_open_v2,
|
331
|
+
// sqlite3_release_memory,
|
332
|
+
// sqlite3_result_error_nomem,
|
333
|
+
// sqlite3_result_error_toobig,
|
334
|
+
// sqlite3_sleep,
|
335
|
+
// sqlite3_soft_heap_limit,
|
336
|
+
// sqlite3_vfs_find,
|
337
|
+
// sqlite3_vfs_register,
|
338
|
+
// sqlite3_vfs_unregister,
|
339
|
+
|
340
|
+
// /*
|
341
|
+
// ** Added for 3.5.8
|
342
|
+
// */
|
343
|
+
// sqlite3_threadsafe,
|
344
|
+
// sqlite3_result_zeroblob,
|
345
|
+
// sqlite3_result_error_code,
|
346
|
+
// sqlite3_test_control,
|
347
|
+
// sqlite3_randomness,
|
348
|
+
// sqlite3_context_db_handle,
|
349
|
+
|
350
|
+
// /*
|
351
|
+
// ** Added for 3.6.0
|
352
|
+
// */
|
353
|
+
// sqlite3_extended_result_codes,
|
354
|
+
// sqlite3_limit,
|
355
|
+
// sqlite3_next_stmt,
|
356
|
+
// sqlite3_sql,
|
357
|
+
// sqlite3_status,
|
358
|
+
//};
|
359
|
+
|
360
|
+
/*
|
361
|
+
** Attempt to load an SQLite extension library contained in the file
|
362
|
+
** zFile. The entry point is zProc. zProc may be 0 in which case a
|
363
|
+
** default entry point name (sqlite3_extension_init) is used. Use
|
364
|
+
** of the default name is recommended.
|
365
|
+
**
|
366
|
+
** Return SQLITE_OK on success and SQLITE_ERROR if something goes wrong.
|
367
|
+
**
|
368
|
+
** If an error occurs and pzErrMsg is not 0, then fill pzErrMsg with
|
369
|
+
** error message text. The calling function should free this memory
|
370
|
+
** by calling sqlite3DbFree(db, ).
|
371
|
+
*/
|
372
|
+
static int sqlite3LoadExtension(
|
373
|
+
sqlite3 db, /* Load the extension into this database connection */
|
374
|
+
string zFile, /* Name of the shared library containing extension */
|
375
|
+
string zProc, /* Entry point. Use "sqlite3_extension_init" if 0 */
|
376
|
+
ref string pzErrMsg /* Put error message here if not 0 */
|
377
|
+
)
|
378
|
+
{
|
379
|
+
sqlite3_vfs pVfs = db.pVfs;
|
380
|
+
HANDLE handle;
|
381
|
+
dxInit xInit; //int (*xInit)(sqlite3*,char**,const sqlite3_api_routines*);
|
382
|
+
string zErrmsg = "";
|
383
|
+
//object aHandle;
|
384
|
+
const int nMsg = 300;
|
385
|
+
if ( pzErrMsg != null ) pzErrMsg = null;
|
386
|
+
|
387
|
+
|
388
|
+
/* Ticket #1863. To avoid a creating security problems for older
|
389
|
+
** applications that relink against newer versions of SQLite, the
|
390
|
+
** ability to run load_extension is turned off by default. One
|
391
|
+
** must call sqlite3_enable_load_extension() to turn on extension
|
392
|
+
** loading. Otherwise you get the following error.
|
393
|
+
*/
|
394
|
+
if ( ( db.flags & SQLITE_LoadExtension ) == 0 )
|
395
|
+
{
|
396
|
+
//if( pzErrMsg != null){
|
397
|
+
pzErrMsg = sqlite3_mprintf( "not authorized" );
|
398
|
+
//}
|
399
|
+
return SQLITE_ERROR;
|
400
|
+
}
|
401
|
+
|
402
|
+
if ( zProc == null || zProc == "" )
|
403
|
+
{
|
404
|
+
zProc = "sqlite3_extension_init";
|
405
|
+
}
|
406
|
+
|
407
|
+
handle = sqlite3OsDlOpen( pVfs, zFile );
|
408
|
+
if ( handle == IntPtr.Zero )
|
409
|
+
{
|
410
|
+
// if( pzErrMsg ){
|
411
|
+
zErrmsg = "";//zErrmsg = sqlite3StackAllocZero(db, nMsg);
|
412
|
+
//if( zErrmsg !=null){
|
413
|
+
sqlite3_snprintf( nMsg, ref zErrmsg,
|
414
|
+
"unable to open shared library [%s]", zFile );
|
415
|
+
sqlite3OsDlError( pVfs, nMsg - 1, ref zErrmsg );
|
416
|
+
pzErrMsg = zErrmsg;// sqlite3DbStrDup( 0, zErrmsg );
|
417
|
+
//sqlite3StackFree( db, zErrmsg );
|
418
|
+
//}
|
419
|
+
return SQLITE_ERROR;
|
420
|
+
}
|
421
|
+
//xInit = (int(*)(sqlite3*,char**,const sqlite3_api_routines*))
|
422
|
+
// sqlite3OsDlSym(pVfs, handle, zProc);
|
423
|
+
xInit = (dxInit)sqlite3OsDlSym( pVfs, handle, ref zProc );
|
424
|
+
Debugger.Break(); // TODO --
|
425
|
+
//if( xInit==0 ){
|
426
|
+
// if( pzErrMsg ){
|
427
|
+
// zErrmsg = sqlite3StackAllocZero(db, nMsg);
|
428
|
+
// if( zErrmsg ){
|
429
|
+
// sqlite3_snprintf(nMsg, zErrmsg,
|
430
|
+
// "no entry point [%s] in shared library [%s]", zProc,zFile);
|
431
|
+
// sqlite3OsDlError(pVfs, nMsg-1, zErrmsg);
|
432
|
+
// *pzErrMsg = sqlite3DbStrDup(0, zErrmsg);
|
433
|
+
// //sqlite3StackFree(db, zErrmsg);
|
434
|
+
// }
|
435
|
+
// sqlite3OsDlClose(pVfs, handle);
|
436
|
+
// }
|
437
|
+
// return SQLITE_ERROR;
|
438
|
+
// }else if( xInit(db, ref zErrmsg, sqlite3Apis) ){
|
439
|
+
//// if( pzErrMsg !=null){
|
440
|
+
// pzErrMsg = sqlite3_mprintf("error during initialization: %s", zErrmsg);
|
441
|
+
// //}
|
442
|
+
// sqlite3DbFree(db,ref zErrmsg);
|
443
|
+
// sqlite3OsDlClose(pVfs, ref handle);
|
444
|
+
// return SQLITE_ERROR;
|
445
|
+
// }
|
446
|
+
|
447
|
+
// /* Append the new shared library handle to the db.aExtension array. */
|
448
|
+
// aHandle = sqlite3DbMallocZero(db, sizeof(handle)*db.nExtension+1);
|
449
|
+
// if( aHandle==null ){
|
450
|
+
// return SQLITE_NOMEM;
|
451
|
+
// }
|
452
|
+
// if( db.nExtension>0 ){
|
453
|
+
// memcpy(aHandle, db.aExtension, sizeof(handle)*(db.nExtension));
|
454
|
+
// }
|
455
|
+
// sqlite3DbFree(db,ref db.aExtension);
|
456
|
+
// db.aExtension = aHandle;
|
457
|
+
|
458
|
+
// db.aExtension[db.nExtension++] = handle;
|
459
|
+
return SQLITE_OK;
|
460
|
+
}
|
461
|
+
|
462
|
+
static public int sqlite3_load_extension(
|
463
|
+
sqlite3 db, /* Load the extension into this database connection */
|
464
|
+
string zFile, /* Name of the shared library containing extension */
|
465
|
+
string zProc, /* Entry point. Use "sqlite3_extension_init" if 0 */
|
466
|
+
ref string pzErrMsg /* Put error message here if not 0 */
|
467
|
+
)
|
468
|
+
{
|
469
|
+
int rc;
|
470
|
+
sqlite3_mutex_enter( db.mutex );
|
471
|
+
rc = sqlite3LoadExtension( db, zFile, zProc, ref pzErrMsg );
|
472
|
+
rc = sqlite3ApiExit( db, rc );
|
473
|
+
sqlite3_mutex_leave( db.mutex );
|
474
|
+
return rc;
|
475
|
+
}
|
476
|
+
|
477
|
+
/*
|
478
|
+
** Call this routine when the database connection is closing in order
|
479
|
+
** to clean up loaded extensions
|
480
|
+
*/
|
481
|
+
static void sqlite3CloseExtensions( sqlite3 db )
|
482
|
+
{
|
483
|
+
int i;
|
484
|
+
Debug.Assert( sqlite3_mutex_held( db.mutex ) );
|
485
|
+
for ( i = 0; i < db.nExtension; i++ )
|
486
|
+
{
|
487
|
+
sqlite3OsDlClose( db.pVfs, (HANDLE)db.aExtension[i] );
|
488
|
+
}
|
489
|
+
sqlite3DbFree( db, ref db.aExtension );
|
490
|
+
}
|
491
|
+
|
492
|
+
/*
|
493
|
+
** Enable or disable extension loading. Extension loading is disabled by
|
494
|
+
** default so as not to open security holes in older applications.
|
495
|
+
*/
|
496
|
+
static public int sqlite3_enable_load_extension( sqlite3 db, int onoff )
|
497
|
+
{
|
498
|
+
sqlite3_mutex_enter( db.mutex );
|
499
|
+
if ( onoff != 0 )
|
500
|
+
{
|
501
|
+
db.flags |= SQLITE_LoadExtension;
|
502
|
+
}
|
503
|
+
else
|
504
|
+
{
|
505
|
+
db.flags &= ~SQLITE_LoadExtension;
|
506
|
+
}
|
507
|
+
sqlite3_mutex_leave( db.mutex );
|
508
|
+
return SQLITE_OK;
|
509
|
+
}
|
510
|
+
|
511
|
+
#endif //* SQLITE_OMIT_LOAD_EXTENSION */
|
512
|
+
|
513
|
+
/*
|
514
|
+
** The auto-extension code added regardless of whether or not extension
|
515
|
+
** loading is supported. We need a dummy sqlite3Apis pointer for that
|
516
|
+
** code if regular extension loading is not available. This is that
|
517
|
+
** dummy pointer.
|
518
|
+
*/
|
519
|
+
#if SQLITE_OMIT_LOAD_EXTENSION
|
520
|
+
const sqlite3_api_routines sqlite3Apis = null;
|
521
|
+
#endif
|
522
|
+
|
523
|
+
|
524
|
+
/*
|
525
|
+
** The following object holds the list of automatically loaded
|
526
|
+
** extensions.
|
527
|
+
**
|
528
|
+
** This list is shared across threads. The SQLITE_MUTEX_STATIC_MASTER
|
529
|
+
** mutex must be held while accessing this list.
|
530
|
+
*/
|
531
|
+
//typedef struct sqlite3AutoExtList sqlite3AutoExtList;
|
532
|
+
public class sqlite3AutoExtList
|
533
|
+
{
|
534
|
+
public int nExt = 0; /* Number of entries in aExt[] */
|
535
|
+
public dxInit[] aExt = null; /* Pointers to the extension init functions */
|
536
|
+
public sqlite3AutoExtList( int nExt, dxInit[] aExt ) { this.nExt = nExt; this.aExt = aExt; }
|
537
|
+
}
|
538
|
+
static sqlite3AutoExtList sqlite3Autoext = new sqlite3AutoExtList( 0, null );
|
539
|
+
/* The "wsdAutoext" macro will resolve to the autoextension
|
540
|
+
** state vector. If writable static data is unsupported on the target,
|
541
|
+
** we have to locate the state vector at run-time. In the more common
|
542
|
+
** case where writable static data is supported, wsdStat can refer directly
|
543
|
+
** to the "sqlite3Autoext" state vector declared above.
|
544
|
+
*/
|
545
|
+
#if SQLITE_OMIT_WSD
|
546
|
+
//# define wsdAutoextInit \
|
547
|
+
sqlite3AutoExtList *x = &GLOBAL(sqlite3AutoExtList,sqlite3Autoext)
|
548
|
+
//# define wsdAutoext x[0]
|
549
|
+
#else
|
550
|
+
//# define wsdAutoextInit
|
551
|
+
static void wsdAutoextInit() { }
|
552
|
+
//# define wsdAutoext sqlite3Autoext
|
553
|
+
static sqlite3AutoExtList wsdAutoext = sqlite3Autoext;
|
554
|
+
#endif
|
555
|
+
|
556
|
+
/*
|
557
|
+
** Register a statically linked extension that is automatically
|
558
|
+
** loaded by every new database connection.
|
559
|
+
*/
|
560
|
+
static int sqlite3_auto_extension( dxInit xInit )
|
561
|
+
{
|
562
|
+
int rc = SQLITE_OK;
|
563
|
+
#if !SQLITE_OMIT_AUTOINIT
|
564
|
+
rc = sqlite3_initialize();
|
565
|
+
if ( rc != 0 )
|
566
|
+
{
|
567
|
+
return rc;
|
568
|
+
}
|
569
|
+
else
|
570
|
+
#endif
|
571
|
+
{
|
572
|
+
int i;
|
573
|
+
#if SQLITE_THREADSAFE
|
574
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER );
|
575
|
+
#else
|
576
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER ); // Need this since mutex_enter & leave are not MACROS under C#
|
577
|
+
#endif
|
578
|
+
wsdAutoextInit();
|
579
|
+
sqlite3_mutex_enter( mutex );
|
580
|
+
for ( i = 0; i < wsdAutoext.nExt; i++ )
|
581
|
+
{
|
582
|
+
if ( wsdAutoext.aExt[i] == xInit ) break;
|
583
|
+
}
|
584
|
+
//if( i==wsdAutoext.nExt ){
|
585
|
+
// int nByte = (wsdAutoext.nExt+1)*sizeof(wsdAutoext.aExt[0]);
|
586
|
+
// void **aNew;
|
587
|
+
// aNew = sqlite3_realloc(wsdAutoext.aExt, nByte);
|
588
|
+
// if( aNew==0 ){
|
589
|
+
// rc = SQLITE_NOMEM;
|
590
|
+
// }else{
|
591
|
+
Array.Resize( ref wsdAutoext.aExt, wsdAutoext.nExt + 1 );// wsdAutoext.aExt = aNew;
|
592
|
+
wsdAutoext.aExt[wsdAutoext.nExt] = xInit;
|
593
|
+
wsdAutoext.nExt++;
|
594
|
+
//}
|
595
|
+
sqlite3_mutex_leave( mutex );
|
596
|
+
Debug.Assert( ( rc & 0xff ) == rc );
|
597
|
+
return rc;
|
598
|
+
}
|
599
|
+
}
|
600
|
+
|
601
|
+
/*
|
602
|
+
** Reset the automatic extension loading mechanism.
|
603
|
+
*/
|
604
|
+
static void sqlite3_reset_auto_extension()
|
605
|
+
{
|
606
|
+
#if !SQLITE_OMIT_AUTOINIT
|
607
|
+
if ( sqlite3_initialize() == SQLITE_OK )
|
608
|
+
#endif
|
609
|
+
{
|
610
|
+
#if SQLITE_THREADSAFE
|
611
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER );
|
612
|
+
#else
|
613
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER ); // Need this since mutex_enter & leave are not MACROS under C#
|
614
|
+
#endif
|
615
|
+
wsdAutoextInit();
|
616
|
+
sqlite3_mutex_enter( mutex );
|
617
|
+
#if SQLITE_OMIT_WSD
|
618
|
+
//sqlite3_free( ref wsdAutoext.aExt );
|
619
|
+
wsdAutoext.aExt = null;
|
620
|
+
wsdAutoext.nExt = 0;
|
621
|
+
#else
|
622
|
+
//sqlite3_free( ref sqlite3Autoext.aExt );
|
623
|
+
sqlite3Autoext.aExt = null;
|
624
|
+
sqlite3Autoext.nExt = 0;
|
625
|
+
#endif
|
626
|
+
sqlite3_mutex_leave( mutex );
|
627
|
+
}
|
628
|
+
}
|
629
|
+
|
630
|
+
/*
|
631
|
+
** Load all automatic extensions.
|
632
|
+
**
|
633
|
+
** If anything goes wrong, set an error in the database connection.
|
634
|
+
*/
|
635
|
+
static void sqlite3AutoLoadExtensions( sqlite3 db )
|
636
|
+
{
|
637
|
+
int i;
|
638
|
+
bool go = true;
|
639
|
+
dxInit xInit;//)(sqlite3*,char**,const sqlite3_api_routines*);
|
640
|
+
|
641
|
+
wsdAutoextInit();
|
642
|
+
#if SQLITE_OMIT_WSD
|
643
|
+
if ( wsdAutoext.nExt == 0 )
|
644
|
+
#else
|
645
|
+
if ( sqlite3Autoext.nExt == 0 )
|
646
|
+
#endif
|
647
|
+
{
|
648
|
+
/* Common case: early out without every having to acquire a mutex */
|
649
|
+
return;
|
650
|
+
}
|
651
|
+
for ( i = 0; go; i++ )
|
652
|
+
{
|
653
|
+
string zErrmsg = "";
|
654
|
+
#if SQLITE_THREADSAFE
|
655
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER );
|
656
|
+
#else
|
657
|
+
sqlite3_mutex mutex = sqlite3MutexAlloc( SQLITE_MUTEX_STATIC_MASTER ); // Need this since mutex_enter & leave are not MACROS under C#
|
658
|
+
#endif
|
659
|
+
sqlite3_mutex_enter( mutex );
|
660
|
+
if ( i >= wsdAutoext.nExt )
|
661
|
+
{
|
662
|
+
xInit = null;
|
663
|
+
go = false;
|
664
|
+
}
|
665
|
+
else
|
666
|
+
{
|
667
|
+
xInit = (dxInit)
|
668
|
+
wsdAutoext.aExt[i];
|
669
|
+
}
|
670
|
+
sqlite3_mutex_leave( mutex );
|
671
|
+
zErrmsg = "";
|
672
|
+
if ( xInit != null && xInit( db, ref zErrmsg, (sqlite3_api_routines)sqlite3Apis ) != 0 )
|
673
|
+
{
|
674
|
+
sqlite3Error( db, SQLITE_ERROR,
|
675
|
+
"automatic extension loading failed: %s", zErrmsg );
|
676
|
+
go = false;
|
677
|
+
}
|
678
|
+
sqlite3DbFree( db, ref zErrmsg );
|
679
|
+
}
|
680
|
+
}
|
681
|
+
}
|
682
|
+
}
|
683
|
+
|