diff --git a/android.modules.data.adapters/build.gradle b/android.modules.data.adapters/build.gradle
index fb45c4e..31ab759 100644
--- a/android.modules.data.adapters/build.gradle
+++ b/android.modules.data.adapters/build.gradle
@@ -38,5 +38,5 @@ android {
dependencies {
implementation project(':android.modules.data')
- implementation "androidx.recyclerview:recyclerview:$project.ANDROID_SUPPORT_VERSION"
+ implementation "androidx.recyclerview:recyclerview:$project.ANDROIDX_VERSION"
}
diff --git a/android.modules.data.loaders/.gitignore b/android.modules.data.loaders/.gitignore
deleted file mode 100644
index 796b96d..0000000
--- a/android.modules.data.loaders/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-/build
diff --git a/android.modules.data.loaders/build.gradle b/android.modules.data.loaders/build.gradle
deleted file mode 100644
index b03ae02..0000000
--- a/android.modules.data.loaders/build.gradle
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-apply plugin: 'com.android.library'
-apply plugin: 'com.github.dcendents.android-maven'
-
-group='com.github.spryrocks.androidmodules'
-
-android {
- compileSdkVersion project.compileSdkVersion
-
- defaultConfig {
- minSdkVersion 14
- targetSdkVersion 28
- versionCode project.versionCode
- versionName project.versionName
- }
- buildTypes {
- release {
- minifyEnabled false
- proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
- }
- }
-}
-
-dependencies {
- implementation project(':android.modules.data')
- implementation "androidx.legacy:legacy-support-core-utils:$project.ANDROID_SUPPORT_VERSION"
-}
diff --git a/android.modules.data.loaders/proguard-rules.pro b/android.modules.data.loaders/proguard-rules.pro
deleted file mode 100644
index 3f9b53d..0000000
--- a/android.modules.data.loaders/proguard-rules.pro
+++ /dev/null
@@ -1,25 +0,0 @@
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in C:\android\sdk/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the proguardFiles
-# directive in build.gradle.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
-
-# Uncomment this to preserve the line number information for
-# debugging stack traces.
-#-keepattributes SourceFile,LineNumberTable
-
-# If you keep the line number information, uncomment this to
-# hide the original source file name.
-#-renamesourcefileattribute SourceFile
diff --git a/android.modules.data.loaders/src/main/AndroidManifest.xml b/android.modules.data.loaders/src/main/AndroidManifest.xml
deleted file mode 100644
index b0f6d39..0000000
--- a/android.modules.data.loaders/src/main/AndroidManifest.xml
+++ /dev/null
@@ -1,3 +0,0 @@
-
-
-
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/AsyncTaskLoaderBase.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/AsyncTaskLoaderBase.java
deleted file mode 100644
index ac2280b..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/AsyncTaskLoaderBase.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-import android.content.Context;
-
-import androidx.loader.content.AsyncTaskLoader;
-
-public abstract class AsyncTaskLoaderBase extends AsyncTaskLoader> {
- public AsyncTaskLoaderBase(Context context) {
- super(context);
- }
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/EmptyDataSource.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/EmptyDataSource.java
deleted file mode 100644
index a88eafc..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/EmptyDataSource.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-import android.content.Context;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class EmptyDataSource implements IDataSource {
- @Override
- public ILoaderAlgorithm createAlgorithm(Context context) {
- return new Algorithm<>();
- }
-
- private static class Algorithm implements ILoaderAlgorithm {
- @Override
- public List loadItems(int offset, int count) throws Exception {
- return new ArrayList<>();
- }
-
- @Override
- public boolean isPaginationSupported() {
- return false;
- }
- }
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IDataSource.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IDataSource.java
deleted file mode 100644
index ebe19eb..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IDataSource.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-import android.content.Context;
-
-import java.io.Serializable;
-
-public interface IDataSource extends Serializable {
- ILoaderAlgorithm createAlgorithm(Context context);
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/ILoaderAlgorithm.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/ILoaderAlgorithm.java
deleted file mode 100644
index 0f091ed..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/ILoaderAlgorithm.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-import java.util.List;
-
-public interface ILoaderAlgorithm {
- List loadItems(int offset, int count) throws Exception;
-
- boolean isPaginationSupported();
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IPaginationLoader.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IPaginationLoader.java
deleted file mode 100644
index 2eea990..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/IPaginationLoader.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-public interface IPaginationLoader {
- boolean isEnd();
-
- int getCount();
- void setCount(int count);
-
- void onContentChanged();
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/LoaderResult.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/LoaderResult.java
deleted file mode 100644
index b186d7e..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/LoaderResult.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-public class LoaderResult {
- public static LoaderResult create(T value) {
- return new LoaderResult(value, null);
- }
-
- public static LoaderResult create(Exception error) {
- return new LoaderResult(null, error);
- }
-
- public final T value;
- public final Exception error;
-
- private LoaderResult(T value, Exception error) {
- this.value = value;
- this.error = error;
- }
-}
diff --git a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/PaginationLoader.java b/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/PaginationLoader.java
deleted file mode 100644
index 87f5a09..0000000
--- a/android.modules.data.loaders/src/main/java/com/spryrocks/android/modules/data/loaders/PaginationLoader.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright 2017 Spry Rocks, Inc
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.spryrocks.android.modules.data.loaders;
-
-import android.content.Context;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class PaginationLoader extends AsyncTaskLoaderBase> implements IPaginationLoader {
- public static PaginationLoader create(Context context, IDataSource dataSource) {
- return new PaginationLoader(context, dataSource);
- }
-
- private final ILoaderAlgorithm algorithm;
-
- private int count = -1;
- private boolean isEnd;
-
- private final List items;
-
- public PaginationLoader(Context context, IDataSource dataSource) {
- super(context);
-
- if(dataSource == null)
- dataSource = new EmptyDataSource<>();
-
- this.algorithm = dataSource.createAlgorithm(context);
-
- this.items = new ArrayList();
- }
-
- @Override
- protected void onStartLoading() {
- super.onStartLoading();
- onContentChanged();
- }
-
- @Override
- public LoaderResult> loadInBackground() {
- try {
-
- boolean isPaginationEnabled = algorithm.isPaginationSupported() && count > -1;
-
- if(isPaginationEnabled) {
-
- while (items.size() < count && !isEnd) {
-
- int offset = items.size();
-
- List items = algorithm.loadItems(offset, count);
- if (items.size() < 1) {
- isEnd = true;
- break;
- }
- this.items.addAll(items);
- }
-
- }
- else {
- List postInfos = algorithm.loadItems(0, -1);
- items.clear();
- items.addAll(postInfos);
- isEnd = true;
- }
-
- } catch (Exception e) {
- isEnd = true;
- return LoaderResult.create(e);
- }
- return LoaderResult.create(items);
- }
-
- public void setCount(int count) {
- this.count = count;
- }
-
- public int getCount() {
- return count;
- }
-
- public boolean isEnd() {
- return isEnd;
- }
-}
diff --git a/android.modules.ui.mvp/build.gradle b/android.modules.ui.mvp/build.gradle
index 7b53ac0..9ff80a2 100644
--- a/android.modules.ui.mvp/build.gradle
+++ b/android.modules.ui.mvp/build.gradle
@@ -40,6 +40,6 @@ dependencies {
implementation project(':android.modules')
implementation project(':android.modules.ui')
implementation project(':android.modules.data')
- implementation "androidx.annotation:annotation:$project.ANDROID_SUPPORT_VERSION"
- implementation "androidx.fragment:fragment:$project.ANDROID_SUPPORT_VERSION"
+ implementation "androidx.annotation:annotation:$project.ANDROIDX_VERSION"
+ implementation "androidx.fragment:fragment:$project.ANDROIDX_VERSION"
}
diff --git a/android.modules.ui.mvvm/build.gradle b/android.modules.ui.mvvm/build.gradle
index 1e9bf39..b102556 100644
--- a/android.modules.ui.mvvm/build.gradle
+++ b/android.modules.ui.mvvm/build.gradle
@@ -49,6 +49,6 @@ android {
dependencies {
implementation project(":android.modules")
implementation project(":android.modules.ui")
- implementation "androidx.appcompat:appcompat:$project.ANDROID_SUPPORT_VERSION"
- implementation "androidx.lifecycle:lifecycle-extensions:$project.ANDROID_ARCH_VERSION"
+ implementation "androidx.appcompat:appcompat:$project.ANDROIDX_APPCOMPAT_VERSION"
+ implementation "androidx.lifecycle:lifecycle-extensions:$project.ANDROIDX_ARCH_VERSION"
}
diff --git a/android.modules.ui.routing/build.gradle b/android.modules.ui.routing/build.gradle
index 00b42fb..b506138 100644
--- a/android.modules.ui.routing/build.gradle
+++ b/android.modules.ui.routing/build.gradle
@@ -30,6 +30,6 @@ android {
dependencies {
implementation project(":android.modules")
implementation project(":android.modules.ui")
- implementation "androidx.annotation:annotation:$project.ANDROID_SUPPORT_VERSION"
- implementation "androidx.fragment:fragment:$project.ANDROID_SUPPORT_VERSION"
+ implementation "androidx.annotation:annotation:$project.ANDROIDX_VERSION"
+ implementation "androidx.fragment:fragment:$project.ANDROIDX_VERSION"
}
diff --git a/android.modules.ui/build.gradle b/android.modules.ui/build.gradle
index e5bcc32..f1c2b50 100644
--- a/android.modules.ui/build.gradle
+++ b/android.modules.ui/build.gradle
@@ -44,6 +44,6 @@ android {
dependencies {
implementation project(':android.modules')
- implementation "androidx.fragment:fragment:$project.ANDROID_SUPPORT_VERSION"
- implementation "androidx.appcompat:appcompat:$project.ANDROID_SUPPORT_VERSION"
+ implementation "androidx.fragment:fragment:$project.ANDROIDX_VERSION"
+ implementation "androidx.appcompat:appcompat:$project.ANDROIDX_APPCOMPAT_VERSION"
}
diff --git a/build.gradle b/build.gradle
index e764431..449da56 100644
--- a/build.gradle
+++ b/build.gradle
@@ -20,8 +20,8 @@ buildscript {
google()
}
dependencies {
- classpath 'com.android.tools.build:gradle:3.4.0-alpha02'
- classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0'
+ classpath 'com.android.tools.build:gradle:3.5.0'
+ classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
}
}
@@ -37,6 +37,7 @@ project.ext {
versionCode = 1
versionName = "1.0"
- ANDROID_SUPPORT_VERSION = "1.0.0"
- ANDROID_ARCH_VERSION = '2.0.0'
+ ANDROIDX_VERSION = "1.0.0"
+ ANDROIDX_APPCOMPAT_VERSION = "1.0.2"
+ ANDROIDX_ARCH_VERSION = '2.0.0'
}
\ No newline at end of file
diff --git a/gradle.properties b/gradle.properties
index e0348ed..404549b 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -2,5 +2,4 @@
# android.databinding
android.databinding.enableV2=true
-android.enableJetifier=true
android.useAndroidX=true
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 3cbfe67..9d63a0f 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,6 @@
-#Mon Feb 19 18:09:03 EET 2018
+#Wed Aug 28 13:58:03 MSK 2019
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.1-all.zip
\ No newline at end of file
+distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip
diff --git a/settings.gradle b/settings.gradle
index 749bcdd..f92caf3 100644
--- a/settings.gradle
+++ b/settings.gradle
@@ -1,7 +1,6 @@
include ':android.modules',
':android.modules.threading',
':android.modules.data',
- ':android.modules.data.loaders',
':android.modules.data.adapters',
':android.modules.ui',
':android.modules.ui.mvp',