From 57d0b52ef430e78cc785796b19e3f6563278574f Mon Sep 17 00:00:00 2001 From: Vincent Peter Date: Mon, 12 Aug 2019 12:34:28 +0300 Subject: [PATCH] initial commit --- .gitignore | 13 + .idea/gradle.xml | 8 +- app/build.gradle | 8 +- app/src/main/java/promise/app/App.java | 2 - build.gradle | 1 + {promisepref => commonsapp}/.gitignore | 0 commonsapp/build.gradle | 45 + .../proguard-rules.pro | 0 .../commonsapp/ExampleInstrumentedTest.kt | 24 + commonsapp/src/main/AndroidManifest.xml | 24 + .../java/promise/commonsapp/MainActivity.kt | 31 + .../drawable-v24/ic_launcher_foreground.xml | 34 + .../res/drawable/ic_launcher_background.xml | 170 ++++ .../src/main/res/layout/activity_main.xml | 19 + .../res/mipmap-anydpi-v26/ic_launcher.xml | 5 + .../mipmap-anydpi-v26/ic_launcher_round.xml | 5 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 2963 bytes .../res/mipmap-hdpi/ic_launcher_round.png | Bin 0 -> 4905 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 2060 bytes .../res/mipmap-mdpi/ic_launcher_round.png | Bin 0 -> 2783 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 4490 bytes .../res/mipmap-xhdpi/ic_launcher_round.png | Bin 0 -> 6895 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 6387 bytes .../res/mipmap-xxhdpi/ic_launcher_round.png | Bin 0 -> 10413 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 9128 bytes .../res/mipmap-xxxhdpi/ic_launcher_round.png | Bin 0 -> 15132 bytes commonsapp/src/main/res/values/colors.xml | 6 + commonsapp/src/main/res/values/strings.xml | 3 + commonsapp/src/main/res/values/styles.xml | 11 + .../promise/commonsapp/ExampleUnitTest.kt | 17 + dbapp/.gitignore | 1 + dbapp/build.gradle | 50 ++ dbapp/proguard-rules.pro | 21 + .../promise/dbapp/ExampleInstrumentedTest.kt | 24 + dbapp/src/main/AndroidManifest.xml | 27 + dbapp/src/main/java/promise/dbapp/App.kt | 11 + .../main/java/promise/dbapp/MainActivity.kt | 67 ++ .../java/promise/dbapp/model/ComplexModel.kt | 160 ++++ .../promise/dbapp/model/ComplexModelTable.kt | 48 ++ .../main/java/promise/dbapp/model/Database.kt | 70 ++ .../drawable-v24/ic_launcher_foreground.xml | 34 + .../res/drawable/ic_launcher_background.xml | 170 ++++ dbapp/src/main/res/layout/activity_main.xml | 33 + dbapp/src/main/res/layout/complex_layout.xml | 6 + dbapp/src/main/res/layout/content_main.xml | 31 + dbapp/src/main/res/menu/menu_main.xml | 10 + .../res/mipmap-anydpi-v26/ic_launcher.xml | 5 + .../mipmap-anydpi-v26/ic_launcher_round.xml | 5 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 2963 bytes .../res/mipmap-hdpi/ic_launcher_round.png | Bin 0 -> 4905 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 2060 bytes .../res/mipmap-mdpi/ic_launcher_round.png | Bin 0 -> 2783 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 4490 bytes .../res/mipmap-xhdpi/ic_launcher_round.png | Bin 0 -> 6895 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 6387 bytes .../res/mipmap-xxhdpi/ic_launcher_round.png | Bin 0 -> 10413 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 9128 bytes .../res/mipmap-xxxhdpi/ic_launcher_round.png | Bin 0 -> 15132 bytes dbapp/src/main/res/values/colors.xml | 6 + dbapp/src/main/res/values/dimens.xml | 3 + dbapp/src/main/res/values/strings.xml | 4 + dbapp/src/main/res/values/styles.xml | 20 + .../java/promise/dbapp/ExampleUnitTest.kt | 17 + modelapp/.gitignore | 1 + modelapp/build.gradle | 39 + modelapp/proguard-rules.pro | 21 + .../modelapp/ExampleInstrumentedTest.kt | 24 + modelapp/src/main/AndroidManifest.xml | 24 + .../java/promise/modelapp/MainActivity.kt | 39 + .../drawable-v24/ic_launcher_foreground.xml | 34 + .../res/drawable/ic_launcher_background.xml | 170 ++++ .../src/main/res/layout/activity_main.xml | 33 + modelapp/src/main/res/layout/content_main.xml | 20 + modelapp/src/main/res/menu/menu_main.xml | 10 + .../res/mipmap-anydpi-v26/ic_launcher.xml | 5 + .../mipmap-anydpi-v26/ic_launcher_round.xml | 5 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 2963 bytes .../res/mipmap-hdpi/ic_launcher_round.png | Bin 0 -> 4905 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 2060 bytes .../res/mipmap-mdpi/ic_launcher_round.png | Bin 0 -> 2783 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 4490 bytes .../res/mipmap-xhdpi/ic_launcher_round.png | Bin 0 -> 6895 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 6387 bytes .../res/mipmap-xxhdpi/ic_launcher_round.png | Bin 0 -> 10413 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 9128 bytes .../res/mipmap-xxxhdpi/ic_launcher_round.png | Bin 0 -> 15132 bytes modelapp/src/main/res/values/colors.xml | 6 + modelapp/src/main/res/values/dimens.xml | 3 + modelapp/src/main/res/values/strings.xml | 4 + modelapp/src/main/res/values/styles.xml | 20 + .../java/promise/modelapp/ExampleUnitTest.kt | 17 + netapp/.gitignore | 1 + netapp/build.gradle | 39 + netapp/proguard-rules.pro | 21 + .../promise/netapp/ExampleInstrumentedTest.kt | 24 + netapp/src/main/AndroidManifest.xml | 24 + .../main/java/promise/netapp/MainActivity.kt | 39 + .../drawable-v24/ic_launcher_foreground.xml | 34 + .../res/drawable/ic_launcher_background.xml | 170 ++++ netapp/src/main/res/layout/activity_main.xml | 33 + netapp/src/main/res/layout/content_main.xml | 20 + netapp/src/main/res/menu/menu_main.xml | 10 + .../res/mipmap-anydpi-v26/ic_launcher.xml | 5 + .../mipmap-anydpi-v26/ic_launcher_round.xml | 5 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 2963 bytes .../res/mipmap-hdpi/ic_launcher_round.png | Bin 0 -> 4905 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 2060 bytes .../res/mipmap-mdpi/ic_launcher_round.png | Bin 0 -> 2783 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 4490 bytes .../res/mipmap-xhdpi/ic_launcher_round.png | Bin 0 -> 6895 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 6387 bytes .../res/mipmap-xxhdpi/ic_launcher_round.png | Bin 0 -> 10413 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 9128 bytes .../res/mipmap-xxxhdpi/ic_launcher_round.png | Bin 0 -> 15132 bytes netapp/src/main/res/values/colors.xml | 6 + netapp/src/main/res/values/dimens.xml | 3 + netapp/src/main/res/values/strings.xml | 4 + netapp/src/main/res/values/styles.xml | 20 + .../java/promise/netapp/ExampleUnitTest.kt | 17 + .../src/main/java/promise/data/db/Model.java | 1 - .../java/promise/data/db/ReactiveModel.java | 2 - .../promise/data/net/extras/CallAdapter.java | 8 - .../promise/data/net/extras/JsonAdapter.java | 3 - .../data/net/extras/JsonArrayAdapter.java | 1 - .../promise/data/pref/PreferenceStorage.java | 2 - .../java/promise/data/pref/PreferenceStore.kt | 1 - promisecommons/build.gradle | 4 +- .../src/main/java/promise/Promise.java | 2 +- .../src/main/java/promise/file/Config.java | 16 +- .../src/main/java/promise/file/Dir.java | 146 ++++ .../src/main/java/promise/file/Ext.java | 41 + .../src/main/java/promise/file/FManager.java | 192 +++++ .../src/main/java/promise/file/FUri.java | 98 +++ .../main/java/promise/file/NoFilesFound.java | 9 +- .../src/main/java/promise/model/S.java | 0 .../main/java/promise/pref/InvalidPref.java | 30 + .../java/promise/pref/InvalidPrefType.java | 37 + .../main/java/promise/pref/Preferences.java | 497 +++++++++++ .../src/main/java/promise/util/ArrayUtil.java | 45 - .../src/main/java/promise/util/ClassUtil.java | 6 - .../java/promise/util/DoubleConverter.java | 23 +- .../src/main/java/promise/util/Scheduler.java | 165 ---- promisedb/build.gradle | 4 +- .../src/main/java/promise/model/SModel.java | 0 .../main/java/promise/promisedb/Column.java | 5 +- .../main/java/promise/promisedb/Corrupt.java | 6 + .../src/main/java/promise/promisedb/Crud.java | 2 - .../main/java/promise/promisedb/DBError.java | 8 +- .../main/java/promise/promisedb/FastDB.java | 213 ++++- .../main/java/promise/promisedb/Model.java | 602 ++++++++----- .../java/promise/promisedb/ModelError.java | 5 +- .../java/promise/promisedb/ReactiveCrud.java | 27 +- .../java/promise/promisedb/ReactiveDB.java | 681 +++++++++++++++ .../promise/promisedb/ReactiveFastDB.java | 414 --------- .../java/promise/promisedb/ReactiveModel.java | 389 --------- .../java/promise/promisedb/ReactiveTable.java | 162 ++-- .../main/java/promise/promisedb/Table.java | 269 ++++-- .../promise/promisedb/query/QueryBuilder.java | 2 +- .../query/criteria/ExistsCriteria.java | 2 +- .../promisedb/query/from/SubQueryFrom.java | 2 +- .../query/projection/SubQueryProjection.java | 2 +- promisemodel/build.gradle | 9 +- .../java/promise/promisemodel/Extras.java | 18 + .../main/java/promise/promisemodel/Store.java | 75 ++ .../promisemodel/repo/AsyncIDataStore.kt | 173 +++- .../promisemodel/repo/OnSetupListener.kt | 9 + .../promise/promisemodel/repo/StoreHelper.kt | 16 + .../promisemodel/repo/StoreRepository.kt | 154 +++- .../promisemodel/repo/SyncIDataStore.kt | 141 +++- .../promisemodel/store/PreferenceStorage.java | 189 +++++ .../promisemodel/store/PreferenceStore.kt | 134 +++ .../promise/promisemodel/utils}/Base64.java | 8 +- .../promise/promisemodel/utils/CacheUtil.java | 98 +++ promisenet/build.gradle | 31 +- promisenet/src/main/AndroidManifest.xml | 7 +- .../main/java/promise/promisenet/Config.java | 106 +++ .../java/promise/promisenet/DataBridge.java | 22 + .../java/promise/promisenet/EndPoint.java | 119 +++ .../java/promise/promisenet/FastParser.java | 702 ++++++++++++++++ .../converters/GsonConverterFactory.java | 73 ++ .../converters/GsonRequestBodyConverter.java | 49 ++ .../converters/GsonResponseBodyConverter.java | 46 + .../converters/ParamsConverter.java | 35 + .../promisenet/extras/CallAdapter.java | 45 + .../promisenet/extras/DataRequest.java | 38 + .../promisenet/extras/HttpPayload.java | 98 +++ .../promisenet/extras/HttpResponse.java | 73 ++ .../extras/InputStreamHttpResponse.java | 38 + .../promisenet/extras/Interceptor.java | 36 + .../promisenet/extras/JsonAdapter.java | 55 ++ .../promisenet/extras/JsonArrayAdapter.java | 65 ++ .../extras/JsonArrayHttpResponse.java | 31 + .../promisenet/extras/JsonHttpResponse.java | 40 + .../extras/JsonObjectHttpResponse.java | 31 + .../promisenet/extras/MapHttpResponse.java | 33 + .../java/promise/promisenet/http/Body.java | 40 + .../java/promise/promisenet/http/DELETE.java | 39 + .../java/promise/promisenet/http/Field.java | 68 ++ .../promise/promisenet/http/FieldMap.java | 47 ++ .../promisenet/http/FormUrlEncoded.java | 36 + .../java/promise/promisenet/http/GET.java | 39 + .../java/promise/promisenet/http/HEAD.java | 39 + .../java/promise/promisenet/http/HTTP.java | 56 ++ .../java/promise/promisenet/http/Header.java | 44 + .../promise/promisenet/http/HeaderMap.java | 55 ++ .../java/promise/promisenet/http/Headers.java | 49 ++ .../promise/promisenet/http/Multipart.java | 32 + .../java/promise/promisenet/http/OPTIONS.java | 39 + .../java/promise/promisenet/http/PATCH.java | 39 + .../java/promise/promisenet/http/POST.java | 39 + .../java/promise/promisenet/http/PUT.java | 39 + .../java/promise/promisenet/http/Part.java | 64 ++ .../java/promise/promisenet/http/PartMap.java | 56 ++ .../java/promise/promisenet/http/Path.java | 63 ++ .../java/promise/promisenet/http/Query.java | 79 ++ .../promise/promisenet/http/QueryMap.java | 62 ++ .../promise/promisenet/http/QueryName.java | 64 ++ .../promise/promisenet/http/Streaming.java | 32 + .../java/promise/promisenet/http/Url.java | 41 + .../java/promise/promisenet/net/Call.java | 73 ++ .../promise/promisenet/net/CallAdapter.java | 89 ++ .../java/promise/promisenet/net/Callback.java | 44 + .../promisenet/net/CommonConverters.java | 96 +++ .../promise/promisenet/net/Converter.java | 101 +++ .../net/DefaultCallAdapterFactory.java | 45 + .../net/ExecutorCallAdapterFactory.java | 111 +++ .../promisenet/net/FastParserEngine.java | 614 ++++++++++++++ .../promise/promisenet/net/HttpException.java | 53 ++ .../promise/promisenet/net/OkHttpCall.java | 290 +++++++ .../promisenet/net/ParameterHandler.java | 364 ++++++++ .../java/promise/promisenet/net/Platform.java | 75 ++ .../promisenet/net/RequestBuilder.java | 228 +++++ .../java/promise/promisenet/net/Response.java | 152 ++++ .../promise/promisenet/net/ServiceMethod.java | 789 ++++++++++++++++++ .../java/promise/promisenet/net/Utils.java | 451 ++++++++++ .../promise/promisenet/utils}/Converter.java | 2 +- .../promisenet/utils}/NetworkUtil.java | 2 +- .../promisenet/view/NetworkErrorActivity.java | 119 +++ .../res/layout/activity_network_error.xml | 58 ++ promisenet/src/main/res/values/strings.xml | 22 +- .../promisepref/ExampleInstrumentedTest.java | 27 - promisepref/src/main/AndroidManifest.xml | 2 - promisepref/src/main/res/values/strings.xml | 3 - .../promise/promisepref/ExampleUnitTest.java | 17 - promiseui/build.gradle | 30 +- .../promise/promiseui/AdapterDivider.java | 144 ++++ .../promiseui/AutoCompleteAdapter.java | 19 + .../java/promise/promiseui/DataSource.java | 22 +- .../promise/promiseui/DiffPromiseAdapter.java | 477 +++++++++++ .../promise/promiseui/PromiseAdapter.java | 576 +++++++++++++ .../promise/promiseui/RxPromiseAdapter.java | 98 +++ .../promiseui/RxSearchableAdapter.java | 89 ++ .../promise/promiseui/SearchableAdapter.java | 87 ++ .../promiseui/SearchableListDialog.java | 216 +++++ .../promise/promiseui/SearchableSpinner.java | 159 ++++ .../promiseui/adapter/GroupAdapter.java | 21 + .../promiseui/adapter/GroupHolder.java | 21 + .../promise/promiseui/adapter/Holder.java | 79 ++ .../promiseui/adapter/SingleAdapter.java | 107 +++ .../promiseui/anim/ActivityAnimator.java | 36 + .../java/promise/promiseui/anim/Anim.java | 367 ++++++++ .../promise/promiseui/anim/AnimDuration.java | 86 ++ .../java/promise/promiseui/anim/Animator.java | 257 ++++++ .../promiseui/anim/ButtonAnimator.java | 36 + .../promiseui/anim/DrawerAnimator.java | 73 ++ .../promise/promiseui/anim/ListAnimator.java | 60 ++ .../promiseui/anim/ListDownToTopAnimator.java | 34 + .../promiseui/anim/RecordClickAnimator.java | 34 + .../promiseui/loading/LoadingListener.java | 46 + .../promiseui/loading/LoadingViewable.java | 60 ++ .../promiseui/loading/ProgressLayout.java | 462 ++++++++++ .../promise/promiseui/model/Searchable.java | 7 +- .../promise/promiseui/model/Viewable.java | 32 + .../promise/promiseui/notif/Duration.java | 35 + .../java/promise/promiseui/notif/NBar.java | 146 ++++ .../java/promise/promiseui/notif/NDialog.java | 180 ++++ .../java/promise/promiseui/notif/NToast.java | 51 ++ .../java/promise/promiseui/notif/NType.java | 44 + .../promise/promiseui/notif/Notification.java | 257 ++++++ .../promise/promiseui/utils}/ApiHelper.java | 4 +- .../promise/promiseui/utils}/BitmapUtil.java | 3 +- .../promise/promiseui/utils}/DimenUtil.java | 2 +- .../res/layout/searchable_list_dialog.xml | 22 + settings.gradle | 2 +- uiapp/.gitignore | 1 + {promisepref => uiapp}/build.gradle | 15 +- uiapp/proguard-rules.pro | 21 + .../promise/uiapp/ExampleInstrumentedTest.kt | 24 + uiapp/src/main/AndroidManifest.xml | 21 + .../main/java/promise/uiapp/MainActivity.kt | 12 + .../drawable-v24/ic_launcher_foreground.xml | 34 + .../res/drawable/ic_launcher_background.xml | 170 ++++ uiapp/src/main/res/layout/activity_main.xml | 18 + .../res/mipmap-anydpi-v26/ic_launcher.xml | 5 + .../mipmap-anydpi-v26/ic_launcher_round.xml | 5 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 2963 bytes .../res/mipmap-hdpi/ic_launcher_round.png | Bin 0 -> 4905 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 2060 bytes .../res/mipmap-mdpi/ic_launcher_round.png | Bin 0 -> 2783 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 4490 bytes .../res/mipmap-xhdpi/ic_launcher_round.png | Bin 0 -> 6895 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 6387 bytes .../res/mipmap-xxhdpi/ic_launcher_round.png | Bin 0 -> 10413 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 9128 bytes .../res/mipmap-xxxhdpi/ic_launcher_round.png | Bin 0 -> 15132 bytes uiapp/src/main/res/values/colors.xml | 6 + uiapp/src/main/res/values/strings.xml | 3 + uiapp/src/main/res/values/styles.xml | 11 + .../java/promise/uiapp/ExampleUnitTest.kt | 17 + 309 files changed, 17448 insertions(+), 1504 deletions(-) rename {promisepref => commonsapp}/.gitignore (100%) create mode 100644 commonsapp/build.gradle rename {promisepref => commonsapp}/proguard-rules.pro (100%) create mode 100644 commonsapp/src/androidTest/java/promise/commonsapp/ExampleInstrumentedTest.kt create mode 100644 commonsapp/src/main/AndroidManifest.xml create mode 100644 commonsapp/src/main/java/promise/commonsapp/MainActivity.kt create mode 100644 commonsapp/src/main/res/drawable-v24/ic_launcher_foreground.xml create mode 100644 commonsapp/src/main/res/drawable/ic_launcher_background.xml create mode 100644 commonsapp/src/main/res/layout/activity_main.xml create mode 100644 commonsapp/src/main/res/mipmap-anydpi-v26/ic_launcher.xml create mode 100644 commonsapp/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml create mode 100644 commonsapp/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 commonsapp/src/main/res/mipmap-hdpi/ic_launcher_round.png create mode 100644 commonsapp/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 commonsapp/src/main/res/mipmap-mdpi/ic_launcher_round.png create mode 100644 commonsapp/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 commonsapp/src/main/res/mipmap-xhdpi/ic_launcher_round.png create mode 100644 commonsapp/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 commonsapp/src/main/res/mipmap-xxhdpi/ic_launcher_round.png create mode 100644 commonsapp/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 commonsapp/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png create mode 100644 commonsapp/src/main/res/values/colors.xml create mode 100644 commonsapp/src/main/res/values/strings.xml create mode 100644 commonsapp/src/main/res/values/styles.xml create mode 100644 commonsapp/src/test/java/promise/commonsapp/ExampleUnitTest.kt create mode 100644 dbapp/.gitignore create mode 100644 dbapp/build.gradle create mode 100644 dbapp/proguard-rules.pro create mode 100644 dbapp/src/androidTest/java/promise/dbapp/ExampleInstrumentedTest.kt create mode 100644 dbapp/src/main/AndroidManifest.xml create mode 100644 dbapp/src/main/java/promise/dbapp/App.kt create mode 100644 dbapp/src/main/java/promise/dbapp/MainActivity.kt create mode 100644 dbapp/src/main/java/promise/dbapp/model/ComplexModel.kt create mode 100644 dbapp/src/main/java/promise/dbapp/model/ComplexModelTable.kt create mode 100644 dbapp/src/main/java/promise/dbapp/model/Database.kt create mode 100644 dbapp/src/main/res/drawable-v24/ic_launcher_foreground.xml create mode 100644 dbapp/src/main/res/drawable/ic_launcher_background.xml create mode 100644 dbapp/src/main/res/layout/activity_main.xml create mode 100644 dbapp/src/main/res/layout/complex_layout.xml create mode 100644 dbapp/src/main/res/layout/content_main.xml create mode 100644 dbapp/src/main/res/menu/menu_main.xml create mode 100644 dbapp/src/main/res/mipmap-anydpi-v26/ic_launcher.xml create mode 100644 dbapp/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml create mode 100644 dbapp/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 dbapp/src/main/res/mipmap-hdpi/ic_launcher_round.png create mode 100644 dbapp/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 dbapp/src/main/res/mipmap-mdpi/ic_launcher_round.png create mode 100644 dbapp/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 dbapp/src/main/res/mipmap-xhdpi/ic_launcher_round.png create mode 100644 dbapp/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 dbapp/src/main/res/mipmap-xxhdpi/ic_launcher_round.png create mode 100644 dbapp/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 dbapp/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png create mode 100644 dbapp/src/main/res/values/colors.xml create mode 100644 dbapp/src/main/res/values/dimens.xml create mode 100644 dbapp/src/main/res/values/strings.xml create mode 100644 dbapp/src/main/res/values/styles.xml create mode 100644 dbapp/src/test/java/promise/dbapp/ExampleUnitTest.kt create mode 100644 modelapp/.gitignore create mode 100644 modelapp/build.gradle create mode 100644 modelapp/proguard-rules.pro create mode 100644 modelapp/src/androidTest/java/promise/modelapp/ExampleInstrumentedTest.kt create mode 100644 modelapp/src/main/AndroidManifest.xml create mode 100644 modelapp/src/main/java/promise/modelapp/MainActivity.kt create mode 100644 modelapp/src/main/res/drawable-v24/ic_launcher_foreground.xml create mode 100644 modelapp/src/main/res/drawable/ic_launcher_background.xml create mode 100644 modelapp/src/main/res/layout/activity_main.xml create mode 100644 modelapp/src/main/res/layout/content_main.xml create mode 100644 modelapp/src/main/res/menu/menu_main.xml create mode 100644 modelapp/src/main/res/mipmap-anydpi-v26/ic_launcher.xml create mode 100644 modelapp/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml create mode 100644 modelapp/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 modelapp/src/main/res/mipmap-hdpi/ic_launcher_round.png create mode 100644 modelapp/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 modelapp/src/main/res/mipmap-mdpi/ic_launcher_round.png create mode 100644 modelapp/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 modelapp/src/main/res/mipmap-xhdpi/ic_launcher_round.png create mode 100644 modelapp/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 modelapp/src/main/res/mipmap-xxhdpi/ic_launcher_round.png create mode 100644 modelapp/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 modelapp/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png create mode 100644 modelapp/src/main/res/values/colors.xml create mode 100644 modelapp/src/main/res/values/dimens.xml create mode 100644 modelapp/src/main/res/values/strings.xml create mode 100644 modelapp/src/main/res/values/styles.xml create mode 100644 modelapp/src/test/java/promise/modelapp/ExampleUnitTest.kt create mode 100644 netapp/.gitignore create mode 100644 netapp/build.gradle create mode 100644 netapp/proguard-rules.pro create mode 100644 netapp/src/androidTest/java/promise/netapp/ExampleInstrumentedTest.kt create mode 100644 netapp/src/main/AndroidManifest.xml create mode 100644 netapp/src/main/java/promise/netapp/MainActivity.kt create mode 100644 netapp/src/main/res/drawable-v24/ic_launcher_foreground.xml create mode 100644 netapp/src/main/res/drawable/ic_launcher_background.xml create mode 100644 netapp/src/main/res/layout/activity_main.xml create mode 100644 netapp/src/main/res/layout/content_main.xml create mode 100644 netapp/src/main/res/menu/menu_main.xml create mode 100644 netapp/src/main/res/mipmap-anydpi-v26/ic_launcher.xml create mode 100644 netapp/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml create mode 100644 netapp/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 netapp/src/main/res/mipmap-hdpi/ic_launcher_round.png create mode 100644 netapp/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 netapp/src/main/res/mipmap-mdpi/ic_launcher_round.png create mode 100644 netapp/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 netapp/src/main/res/mipmap-xhdpi/ic_launcher_round.png create mode 100644 netapp/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 netapp/src/main/res/mipmap-xxhdpi/ic_launcher_round.png create mode 100644 netapp/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 netapp/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png create mode 100644 netapp/src/main/res/values/colors.xml create mode 100644 netapp/src/main/res/values/dimens.xml create mode 100644 netapp/src/main/res/values/strings.xml create mode 100644 netapp/src/main/res/values/styles.xml create mode 100644 netapp/src/test/java/promise/netapp/ExampleUnitTest.kt rename promise/src/main/java/promise/data/utils/Converter.java => promisecommons/src/main/java/promise/file/Config.java (71%) create mode 100644 promisecommons/src/main/java/promise/file/Dir.java create mode 100644 promisecommons/src/main/java/promise/file/Ext.java create mode 100644 promisecommons/src/main/java/promise/file/FManager.java create mode 100644 promisecommons/src/main/java/promise/file/FUri.java rename promisedb/src/main/java/promise/promisedb/ExpandedModel.java => promisecommons/src/main/java/promise/file/NoFilesFound.java (78%) rename {promisedb => promisecommons}/src/main/java/promise/model/S.java (100%) create mode 100644 promisecommons/src/main/java/promise/pref/InvalidPref.java create mode 100644 promisecommons/src/main/java/promise/pref/InvalidPrefType.java create mode 100644 promisecommons/src/main/java/promise/pref/Preferences.java delete mode 100644 promisecommons/src/main/java/promise/util/ArrayUtil.java delete mode 100644 promisecommons/src/main/java/promise/util/Scheduler.java rename {promisecommons => promisedb}/src/main/java/promise/model/SModel.java (100%) create mode 100644 promisedb/src/main/java/promise/promisedb/ReactiveDB.java delete mode 100644 promisedb/src/main/java/promise/promisedb/ReactiveFastDB.java delete mode 100644 promisedb/src/main/java/promise/promisedb/ReactiveModel.java create mode 100644 promisemodel/src/main/java/promise/promisemodel/Extras.java create mode 100644 promisemodel/src/main/java/promise/promisemodel/Store.java create mode 100644 promisemodel/src/main/java/promise/promisemodel/store/PreferenceStorage.java create mode 100644 promisemodel/src/main/java/promise/promisemodel/store/PreferenceStore.kt rename {promisecommons/src/main/java/promise/util => promisemodel/src/main/java/promise/promisemodel/utils}/Base64.java (99%) create mode 100644 promisemodel/src/main/java/promise/promisemodel/utils/CacheUtil.java create mode 100644 promisenet/src/main/java/promise/promisenet/Config.java create mode 100644 promisenet/src/main/java/promise/promisenet/DataBridge.java create mode 100644 promisenet/src/main/java/promise/promisenet/EndPoint.java create mode 100644 promisenet/src/main/java/promise/promisenet/FastParser.java create mode 100644 promisenet/src/main/java/promise/promisenet/converters/GsonConverterFactory.java create mode 100644 promisenet/src/main/java/promise/promisenet/converters/GsonRequestBodyConverter.java create mode 100644 promisenet/src/main/java/promise/promisenet/converters/GsonResponseBodyConverter.java create mode 100644 promisenet/src/main/java/promise/promisenet/converters/ParamsConverter.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/CallAdapter.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/DataRequest.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/HttpPayload.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/HttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/InputStreamHttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/Interceptor.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/JsonAdapter.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/JsonArrayAdapter.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/JsonArrayHttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/JsonHttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/JsonObjectHttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/extras/MapHttpResponse.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Body.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/DELETE.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Field.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/FieldMap.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/FormUrlEncoded.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/GET.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/HEAD.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/HTTP.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Header.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/HeaderMap.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Headers.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Multipart.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/OPTIONS.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/PATCH.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/POST.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/PUT.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Part.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/PartMap.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Path.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Query.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/QueryMap.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/QueryName.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Streaming.java create mode 100644 promisenet/src/main/java/promise/promisenet/http/Url.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Call.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/CallAdapter.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Callback.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/CommonConverters.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Converter.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/DefaultCallAdapterFactory.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/ExecutorCallAdapterFactory.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/FastParserEngine.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/HttpException.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/OkHttpCall.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/ParameterHandler.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Platform.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/RequestBuilder.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Response.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/ServiceMethod.java create mode 100644 promisenet/src/main/java/promise/promisenet/net/Utils.java rename {promisecommons/src/main/java/promise/util => promisenet/src/main/java/promise/promisenet/utils}/Converter.java (98%) rename {promisecommons/src/main/java/promise/util => promisenet/src/main/java/promise/promisenet/utils}/NetworkUtil.java (97%) create mode 100644 promisenet/src/main/java/promise/promisenet/view/NetworkErrorActivity.java create mode 100644 promisenet/src/main/res/layout/activity_network_error.xml delete mode 100644 promisepref/src/androidTest/java/promise/promisepref/ExampleInstrumentedTest.java delete mode 100644 promisepref/src/main/AndroidManifest.xml delete mode 100644 promisepref/src/main/res/values/strings.xml delete mode 100644 promisepref/src/test/java/promise/promisepref/ExampleUnitTest.java create mode 100644 promiseui/src/main/java/promise/promiseui/AdapterDivider.java create mode 100644 promiseui/src/main/java/promise/promiseui/AutoCompleteAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/DiffPromiseAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/PromiseAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/RxPromiseAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/RxSearchableAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/SearchableAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/SearchableListDialog.java create mode 100644 promiseui/src/main/java/promise/promiseui/SearchableSpinner.java create mode 100644 promiseui/src/main/java/promise/promiseui/adapter/GroupAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/adapter/GroupHolder.java create mode 100644 promiseui/src/main/java/promise/promiseui/adapter/Holder.java create mode 100644 promiseui/src/main/java/promise/promiseui/adapter/SingleAdapter.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/ActivityAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/Anim.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/AnimDuration.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/Animator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/ButtonAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/DrawerAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/ListAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/ListDownToTopAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/anim/RecordClickAnimator.java create mode 100644 promiseui/src/main/java/promise/promiseui/loading/LoadingListener.java create mode 100644 promiseui/src/main/java/promise/promiseui/loading/LoadingViewable.java create mode 100644 promiseui/src/main/java/promise/promiseui/loading/ProgressLayout.java rename promisedb/src/main/java/promise/promisedb/DBExtras.java => promiseui/src/main/java/promise/promiseui/model/Searchable.java (80%) create mode 100644 promiseui/src/main/java/promise/promiseui/model/Viewable.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/Duration.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/NBar.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/NDialog.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/NToast.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/NType.java create mode 100644 promiseui/src/main/java/promise/promiseui/notif/Notification.java rename {promisecommons/src/main/java/promise/util => promiseui/src/main/java/promise/promiseui/utils}/ApiHelper.java (99%) rename {promisecommons/src/main/java/promise/util => promiseui/src/main/java/promise/promiseui/utils}/BitmapUtil.java (99%) rename {promisecommons/src/main/java/promise/util => promiseui/src/main/java/promise/promiseui/utils}/DimenUtil.java (96%) create mode 100644 promiseui/src/main/res/layout/searchable_list_dialog.xml create mode 100644 uiapp/.gitignore rename {promisepref => uiapp}/build.gradle (61%) create mode 100644 uiapp/proguard-rules.pro create mode 100644 uiapp/src/androidTest/java/promise/uiapp/ExampleInstrumentedTest.kt create mode 100644 uiapp/src/main/AndroidManifest.xml create mode 100644 uiapp/src/main/java/promise/uiapp/MainActivity.kt create mode 100644 uiapp/src/main/res/drawable-v24/ic_launcher_foreground.xml create mode 100644 uiapp/src/main/res/drawable/ic_launcher_background.xml create mode 100644 uiapp/src/main/res/layout/activity_main.xml create mode 100644 uiapp/src/main/res/mipmap-anydpi-v26/ic_launcher.xml create mode 100644 uiapp/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml create mode 100644 uiapp/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 uiapp/src/main/res/mipmap-hdpi/ic_launcher_round.png create mode 100644 uiapp/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 uiapp/src/main/res/mipmap-mdpi/ic_launcher_round.png create mode 100644 uiapp/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 uiapp/src/main/res/mipmap-xhdpi/ic_launcher_round.png create mode 100644 uiapp/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 uiapp/src/main/res/mipmap-xxhdpi/ic_launcher_round.png create mode 100644 uiapp/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 uiapp/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png create mode 100644 uiapp/src/main/res/values/colors.xml create mode 100644 uiapp/src/main/res/values/strings.xml create mode 100644 uiapp/src/main/res/values/styles.xml create mode 100644 uiapp/src/test/java/promise/uiapp/ExampleUnitTest.kt diff --git a/.gitignore b/.gitignore index fd45b12..e133b7a 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,16 @@ /build /captures .externalNativeBuild +app +appbase +dbapp +modelapp +netapp +modelapp +promise +promisedb +promisemodel +promisenet +promiseui +uiapp + diff --git a/.idea/gradle.xml b/.idea/gradle.xml index 6a22d2f..3a92786 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -8,14 +8,8 @@