mirror of
https://github.com/MinimalBible/MinimalBible
synced 2024-09-27 21:51:37 -04:00
Compare commits
No commits in common. "master" and "test_release_1" have entirely different histories.
master
...
test_relea
8
.gitignore
vendored
8
.gitignore
vendored
@ -1,6 +1,10 @@
|
|||||||
.gradle
|
.gradle
|
||||||
local.properties
|
/local.properties
|
||||||
|
/.idea
|
||||||
.DS_Store
|
.DS_Store
|
||||||
/build
|
/build
|
||||||
|
*.iml
|
||||||
|
/node_modules
|
||||||
|
app/src/main/assets/node_modules/
|
||||||
|
npm-debug.log
|
||||||
*.swp
|
*.swp
|
||||||
*.hprof
|
|
||||||
|
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -1,3 +1,6 @@
|
|||||||
[submodule "jsword-minimalbible"]
|
[submodule "jsword-minimalbible"]
|
||||||
path = jsword-minimalbible
|
path = jsword-minimalbible
|
||||||
url = http://github.com/MinimalBible/jsword-minimalbible
|
url = http://github.com/MinimalBible/jsword-minimalbible
|
||||||
|
[submodule "jsword"]
|
||||||
|
path = jsword
|
||||||
|
url = http://github.com/crosswire/jsword
|
||||||
|
1
.idea/.gitignore
vendored
1
.idea/.gitignore
vendored
@ -1 +0,0 @@
|
|||||||
workspace.xml
|
|
@ -1 +0,0 @@
|
|||||||
MinimalBible
|
|
@ -1,23 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="CompilerConfiguration">
|
|
||||||
<option name="DEFAULT_COMPILER" value="Javac" />
|
|
||||||
<resourceExtensions />
|
|
||||||
<wildcardResourcePatterns>
|
|
||||||
<entry name="!?*.java" />
|
|
||||||
<entry name="!?*.form" />
|
|
||||||
<entry name="!?*.class" />
|
|
||||||
<entry name="!?*.groovy" />
|
|
||||||
<entry name="!?*.scala" />
|
|
||||||
<entry name="!?*.flex" />
|
|
||||||
<entry name="!?*.kt" />
|
|
||||||
<entry name="!?*.clj" />
|
|
||||||
</wildcardResourcePatterns>
|
|
||||||
<annotationProcessing>
|
|
||||||
<profile default="true" name="Default" enabled="false">
|
|
||||||
<processorPath useClasspath="true" />
|
|
||||||
</profile>
|
|
||||||
</annotationProcessing>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
|||||||
<component name="CopyrightManager">
|
|
||||||
<settings default="" />
|
|
||||||
</component>
|
|
@ -1,5 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
|
|
||||||
</project>
|
|
||||||
|
|
@ -1,20 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="GradleSettings">
|
|
||||||
<option name="linkedExternalProjectsSettings">
|
|
||||||
<GradleProjectSettings>
|
|
||||||
<option name="distributionType" value="LOCAL" />
|
|
||||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
|
||||||
<option name="gradleHome" value="$APPLICATION_HOME_DIR$/gradle/gradle-2.2.1" />
|
|
||||||
<option name="gradleJvm" value="1.7" />
|
|
||||||
<option name="modules">
|
|
||||||
<set>
|
|
||||||
<option value="$PROJECT_DIR$" />
|
|
||||||
<option value="$PROJECT_DIR$/app" />
|
|
||||||
<option value="$PROJECT_DIR$/jsword-minimalbible" />
|
|
||||||
</set>
|
|
||||||
</option>
|
|
||||||
</GradleProjectSettings>
|
|
||||||
</option>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="InspectionProjectProfileManager">
|
|
||||||
<profile version="1.0" is_locked="false">
|
|
||||||
<option name="myName" value="Project Default" />
|
|
||||||
<option name="myLocal" value="false" />
|
|
||||||
<inspection_tool class="AndroidLintUselessParent" enabled="false" level="WARNING" enabled_by_default="false" />
|
|
||||||
<inspection_tool class="LoggerInitializedWithForeignClass" enabled="false" level="WARNING" enabled_by_default="false">
|
|
||||||
<option name="loggerClassName" value="org.apache.log4j.Logger,org.slf4j.LoggerFactory,org.apache.commons.logging.LogFactory,java.util.logging.Logger" />
|
|
||||||
<option name="loggerFactoryMethodName" value="getLogger,getLogger,getLog,getLogger" />
|
|
||||||
</inspection_tool>
|
|
||||||
</profile>
|
|
||||||
</component>
|
|
@ -1,7 +0,0 @@
|
|||||||
<component name="InspectionProjectProfileManager">
|
|
||||||
<settings>
|
|
||||||
<option name="PROJECT_PROFILE" value="Project Default" />
|
|
||||||
<option name="USE_PROJECT_PROFILE" value="true" />
|
|
||||||
<version value="1.0" />
|
|
||||||
</settings>
|
|
||||||
</component>
|
|
@ -1,9 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="acra-4.6.2">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/ch.acra/acra/4.6.2/b99297996579b72496c9f81b0c12d8404c74e618/acra-4.6.2.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,13 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="appcompat-v7-22.0.0">
|
|
||||||
<ANNOTATIONS>
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/22.0.0/annotations.zip!/" />
|
|
||||||
</ANNOTATIONS>
|
|
||||||
<CLASSES>
|
|
||||||
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/22.0.0/res" />
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/22.0.0/jars/classes.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="awaitility-1.6.3">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.jayway.awaitility/awaitility/1.6.3/2b698080294539741574d9f7532eb46bdc2bc345/awaitility-1.6.3.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.jayway.awaitility/awaitility/1.6.3/144ef9462490d5bb4fd27b17220840c498fed727/awaitility-1.6.3-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="butterknife-6.1.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.jakewharton/butterknife/6.1.0/63735f48b82bcd24cdd33821342428252eb1ca5a/butterknife-6.1.0.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.jakewharton/butterknife/6.1.0/282f5b78b68e7e5cbaa2f4266265f7f5cc783ee6/butterknife-6.1.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="byte-buddy-0.6.11">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.bytebuddy/byte-buddy/0.6.11/4ef3f3ad5127a5df8dd6483396186b735874fe44/byte-buddy-0.6.11.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.bytebuddy/byte-buddy/0.6.11/f777032b8641f339dc4e865d65505da860cabcd4/byte-buddy-0.6.11-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,12 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="cardview-v7-22.0.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/cardview-v7/22.0.0/jars/classes.jar!/" />
|
|
||||||
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/cardview-v7/22.0.0/res" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/../../android-sdk-linux/extras/android/m2repository/com/android/support/cardview-v7/22.0.0/cardview-v7-22.0.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="cglib-nodep-3.1">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/cglib/cglib-nodep/3.1/aa83efbd1aedc4f26bdf00e7ea78191483f2c9b3/cglib-nodep-3.1.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/cglib/cglib-nodep/3.1/e651cbd93cb1c2155afdea6675c50e567f7ce91e/cglib-nodep-3.1-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="commons-lang3-3.4">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.apache.commons/commons-lang3/3.4/5fe28b9518e58819180a43a850fbc0dd24b7c050/commons-lang3-3.4.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.apache.commons/commons-lang3/3.4/b49dafc9cfef24c356827f322e773e7c26725dd2/commons-lang3-3.4-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="dagger-2.1-SNAPSHOT">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.google.dagger/dagger/2.1-SNAPSHOT/eea9428d19e0d205df9f4d065feb3c06a25a24b2/dagger-2.1-SNAPSHOT.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.google.dagger/dagger/2.1-SNAPSHOT/cffff056ae36beb12c4b8f777e90bc851cf430b8/dagger-2.1-SNAPSHOT-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="esperandro-api-2.2.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/de.devland.esperandro/esperandro-api/2.2.0/df81f1bc766b4d600f2b5e724c05774509b26ab4/esperandro-api-2.2.0.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/de.devland.esperandro/esperandro-api/2.2.0/7faaea36da7a76500559d6abf7deaa23297a15af/esperandro-api-2.2.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="hamcrest-core-1.3">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.hamcrest/hamcrest-core/1.3/42a25dc3219429f0e5d060061f71acb49bf010a0/hamcrest-core-1.3.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.hamcrest/hamcrest-core/1.3/1dc37250fbc78e23a65a67fbbaf71d2e9cbc3c0b/hamcrest-core-1.3-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="hamcrest-library-1.3">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.hamcrest/hamcrest-library/1.3/4785a3c21320980282f9f33d0d1264a69040538f/hamcrest-library-1.3.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.hamcrest/hamcrest-library/1.3/47a7ee46628ab7133129cd7cef1e92657bc275e/hamcrest-library-1.3-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,9 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="javax.annotation-api-1.2">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/javax.annotation/javax.annotation-api/1.2/479c1e06db31c432330183f5cae684163f186146/javax.annotation-api-1.2.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="javax.inject-1">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/javax.inject/javax.inject/1/6975da39a7040257bd51d21a231b76c915872d38/javax.inject-1.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/javax.inject/javax.inject/1/a00123f261762a7c5e0ec916a2c7c8298d29c400/javax.inject-1-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,9 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="jsword-minimalbible.jsword">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/jsword-minimalbible/distribution/jsword.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="junit-4.12">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/junit/junit/4.12/2973d150c0dc1fefe998f834810d68f278ea58ec/junit-4.12.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/junit/junit/4.12/a6c32b40bf3d76eca54e3c601e5d1470c86fcdfa/junit-4.12-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="kotlin-runtime-0.12.213">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-runtime/0.12.213/114f2f0e0fe4c1dbf9aff4f9ef92309c6869a418/kotlin-runtime-0.12.213.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-runtime/0.12.213/e31408fe9fd033d85b76ce945bed62c672f544c/kotlin-runtime-0.12.213-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="kotlin-stdlib-0.12.213">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/0.12.213/ef6149c361cdc528ecef6c751617c7f68fee2d87/kotlin-stdlib-0.12.213.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/0.12.213/ee5b7d954d49ced45cf776c2ea8d626306170949/kotlin-stdlib-0.12.213-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,10 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="logger-1.10">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.orhanobut/logger/1.10/jars/classes.jar!/" />
|
|
||||||
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.orhanobut/logger/1.10/res" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,9 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="mockable-android-22">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/mockable-android-22.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES />
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="mockito-core-2.0.23-beta">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.mockito/mockito-core/2.0.23-beta/f8a8258fa24b3c418766169cccf937ddecf97600/mockito-core-2.0.23-beta.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.mockito/mockito-core/2.0.23-beta/1a867de9aa68a0e2599a4d12f39fd189bec32c43/mockito-core-2.0.23-beta-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="objenesis-2.1">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.objenesis/objenesis/2.1/87c0ea803b69252868d09308b4618f766f135a96/objenesis-2.1.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.objenesis/objenesis/2.1/611a57d836e2c320d59f9851d4ad587f3c8472e/objenesis-2.1-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,12 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="recyclerview-v7-22.0.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/recyclerview-v7/22.0.0/res" />
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/recyclerview-v7/22.0.0/jars/classes.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/../../android-sdk-linux/extras/android/m2repository/com/android/support/recyclerview-v7/22.0.0/recyclerview-v7-22.0.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="rxjava-android-0.20.7">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.netflix.rxjava/rxjava-android/0.20.7/e12fcefbbefd5a9c50585e839449117209128ddf/rxjava-android-0.20.7.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.netflix.rxjava/rxjava-android/0.20.7/49ad0246961d069024dba708b30af6307fc5ce6f/rxjava-android-0.20.7-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="rxjava-core-0.20.7">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.netflix.rxjava/rxjava-core/0.20.7/79abf98a7acac3ffb7fec527847accf23de02bdd/rxjava-core-0.20.7.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.netflix.rxjava/rxjava-core/0.20.7/e915d5e0e95f3bf9495be82e940fadb34763719d/rxjava-core-0.20.7-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="spek-0.1.165">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.spek/spek/0.1.165/ec932e6fe2b8a1b0801568a5cd7eda9fd8bede08/spek-0.1.165.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.spek/spek/0.1.165/f277655191a11d791978bfacbf8a714521ff58e7/spek-0.1.165-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="support-annotations-22.0.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/../../android-sdk-linux/extras/android/m2repository/com/android/support/support-annotations/22.0.0/support-annotations-22.0.0.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/../../android-sdk-linux/extras/android/m2repository/com/android/support/support-annotations/22.0.0/support-annotations-22.0.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,13 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="support-v4-22.0.0">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/support-v4/22.0.0/res" />
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/support-v4/22.0.0/jars/libs/internal_impl-22.0.0.jar!/" />
|
|
||||||
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/support-v4/22.0.0/jars/classes.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$PROJECT_DIR$/../../android-sdk-linux/extras/android/m2repository/com/android/support/support-v4/22.0.0/support-v4-22.0.0-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,11 +0,0 @@
|
|||||||
<component name="libraryTable">
|
|
||||||
<library name="systembartint-1.0.4">
|
|
||||||
<CLASSES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.readystatesoftware.systembartint/systembartint/1.0.4/6404f77b92ec723cc132e825afe85a07da85ee6/systembartint-1.0.4.jar!/" />
|
|
||||||
</CLASSES>
|
|
||||||
<JAVADOC />
|
|
||||||
<SOURCES>
|
|
||||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.readystatesoftware.systembartint/systembartint/1.0.4/51afd2a7626cb5ccffd2ed1a30f072adb284041a/systembartint-1.0.4-sources.jar!/" />
|
|
||||||
</SOURCES>
|
|
||||||
</library>
|
|
||||||
</component>
|
|
@ -1,83 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="CheckstyleConfigurable">
|
|
||||||
<option name="suppFilterFilename" value="" />
|
|
||||||
<option name="suppCommentFilter" value="false" />
|
|
||||||
<option name="offComment" value="CHECKSTYLE\:OFF" />
|
|
||||||
<option name="onComment" value="CHECKSTYLE\:ON" />
|
|
||||||
<option name="checkFormat" value=".*" />
|
|
||||||
<option name="messageFormat" value="" />
|
|
||||||
<option name="checkCPP" value="true" />
|
|
||||||
<option name="checkC" value="true" />
|
|
||||||
<option name="suppNearbyCommentFilter" value="false" />
|
|
||||||
<option name="snCommentFormat" value="SUPPRESS CHECKSTYLE (\w+)" />
|
|
||||||
<option name="snCheckFormat" value="$1" />
|
|
||||||
<option name="snMessageFormat" value="" />
|
|
||||||
<option name="snInfluenceFormat" value="0" />
|
|
||||||
<option name="snCheckCPP" value="true" />
|
|
||||||
<option name="snCheckC" value="true" />
|
|
||||||
<option name="pathToUserRulesConfiguration" value="" />
|
|
||||||
<option name="pathToJarWithRules" value="" />
|
|
||||||
</component>
|
|
||||||
<component name="EntryPointsManager">
|
|
||||||
<entry_points version="2.0" />
|
|
||||||
<list size="2">
|
|
||||||
<item index="0" class="java.lang.String" itemvalue="butterknife.OnClick" />
|
|
||||||
<item index="1" class="java.lang.String" itemvalue="dagger.Provides" />
|
|
||||||
</list>
|
|
||||||
</component>
|
|
||||||
<component name="FindBugsConfigurable">
|
|
||||||
<option name="make" value="true" />
|
|
||||||
<option name="effort" value="default" />
|
|
||||||
<option name="priority" value="Medium" />
|
|
||||||
<option name="excludeFilter" value="" />
|
|
||||||
</component>
|
|
||||||
<component name="IdProvider" IDEtalkID="15F212A1B560F3382F7D6643192A3A39" />
|
|
||||||
<component name="NullableNotNullManager">
|
|
||||||
<option name="myDefaultNullable" value="android.support.annotation.Nullable" />
|
|
||||||
<option name="myDefaultNotNull" value="android.support.annotation.NonNull" />
|
|
||||||
<option name="myNullables">
|
|
||||||
<value>
|
|
||||||
<list size="4">
|
|
||||||
<item index="0" class="java.lang.String" itemvalue="org.jetbrains.annotations.Nullable" />
|
|
||||||
<item index="1" class="java.lang.String" itemvalue="javax.annotation.Nullable" />
|
|
||||||
<item index="2" class="java.lang.String" itemvalue="edu.umd.cs.findbugs.annotations.Nullable" />
|
|
||||||
<item index="3" class="java.lang.String" itemvalue="android.support.annotation.Nullable" />
|
|
||||||
</list>
|
|
||||||
</value>
|
|
||||||
</option>
|
|
||||||
<option name="myNotNulls">
|
|
||||||
<value>
|
|
||||||
<list size="4">
|
|
||||||
<item index="0" class="java.lang.String" itemvalue="org.jetbrains.annotations.NotNull" />
|
|
||||||
<item index="1" class="java.lang.String" itemvalue="javax.annotation.Nonnull" />
|
|
||||||
<item index="2" class="java.lang.String" itemvalue="edu.umd.cs.findbugs.annotations.NonNull" />
|
|
||||||
<item index="3" class="java.lang.String" itemvalue="android.support.annotation.NonNull" />
|
|
||||||
</list>
|
|
||||||
</value>
|
|
||||||
</option>
|
|
||||||
</component>
|
|
||||||
<component name="PDMPlugin">
|
|
||||||
<option name="options">
|
|
||||||
<map>
|
|
||||||
<entry key="Encoding" value="" />
|
|
||||||
<entry key="Target JDK" value="1.6" />
|
|
||||||
</map>
|
|
||||||
</option>
|
|
||||||
<option name="options">
|
|
||||||
<map>
|
|
||||||
<entry key="Encoding" value="" />
|
|
||||||
<entry key="Target JDK" value="1.6" />
|
|
||||||
</map>
|
|
||||||
</option>
|
|
||||||
</component>
|
|
||||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" assert-keyword="true" jdk-15="true" project-jdk-name="1.7" project-jdk-type="JavaSDK">
|
|
||||||
<output url="file://$PROJECT_DIR$/classes" />
|
|
||||||
</component>
|
|
||||||
<component name="SuppressionsComponent">
|
|
||||||
<option name="suppComments" value="[]" />
|
|
||||||
</component>
|
|
||||||
<component name="UnicodeBrowser">
|
|
||||||
<option name="fontName" value="Source Code Pro" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
@ -1,10 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="ProjectModuleManager">
|
|
||||||
<modules>
|
|
||||||
<module fileurl="file://$PROJECT_DIR$/MinimalBible.iml" filepath="$PROJECT_DIR$/MinimalBible.iml" />
|
|
||||||
<module fileurl="file://$PROJECT_DIR$/app/app.iml" filepath="$PROJECT_DIR$/app/app.iml" />
|
|
||||||
<module fileurl="file://$PROJECT_DIR$/jsword-minimalbible/jsword-minimalbible.iml" filepath="$PROJECT_DIR$/jsword-minimalbible/jsword-minimalbible.iml" />
|
|
||||||
</modules>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
@ -1,886 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="AnalysisProjectProfileManager">
|
|
||||||
<option name="PROJECT_PROFILE" value="Project Default" />
|
|
||||||
<option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
|
|
||||||
<scopes />
|
|
||||||
<profiles>
|
|
||||||
<profile version="1.0" is_locked="false">
|
|
||||||
<option name="myName" value="Project Default" />
|
|
||||||
<option name="myLocal" value="false" />
|
|
||||||
<coding_rule class="AM_CREATES_EMPTY_JAR_FILE_ENTRY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="AM_CREATES_EMPTY_ZIP_FILE_ENTRY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="AT_OPERATION_SEQUENCE_ON_CONCURRENT_ABSTRACTION" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="AbstractClassNameCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="ignoreModifier" value="false" />
|
|
||||||
<param name="ignoreName" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="AndroidCallSuperFirst" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="AndroidCallSuperLast" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="AndroidDoNotHardCodeSDCard" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="AnnotationUseStyleCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="AnonInnerLengthCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ArrayTrailingCommaCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ArrayTypeStyleCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="AvoidInlineConditionalsCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="AvoidNestedBlocksCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="AvoidStarImportCheck" level="INFO" enabled="false">
|
|
||||||
<param name="allowClassImports" value="false" />
|
|
||||||
<param name="allowStaticMemberImports" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="AvoidStaticImportCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BAC_BAD_APPLET_CONSTRUCTOR" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BC_BAD_CAST_TO_ABSTRACT_COLLECTION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BC_BAD_CAST_TO_CONCRETE_COLLECTION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BC_EQUALS_METHOD_SHOULD_WORK_FOR_ALL_OBJECTS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BC_IMPOSSIBLE_CAST" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="BC_IMPOSSIBLE_DOWNCAST" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BC_IMPOSSIBLE_DOWNCAST_OF_TOARRAY" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BC_IMPOSSIBLE_INSTANCEOF" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BC_UNCONFIRMED_CAST" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BC_UNCONFIRMED_CAST_OF_RETURN_VALUE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="BC_VACUOUS_INSTANCEOF" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_ADD_OF_SIGNED_BYTE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_AND" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_AND_ZZ" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_IOR" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_IOR_OF_SIGNED_BYTE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_SIGNED_CHECK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BIT_SIGNED_CHECK_HIGH_BIT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BOA_BADLY_OVERRIDDEN_ADAPTER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BX_BOXING_IMMEDIATELY_UNBOXED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BX_BOXING_IMMEDIATELY_UNBOXED_TO_PERFORM_COERCION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BX_UNBOXED_AND_COERCED_FOR_TERNARY_OPERATOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BX_UNBOXING_IMMEDIATELY_REBOXED" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="BasicAvoidBranchingStatementAsLastInLoop" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicAvoidDecimalLiteralsInBigDecimalConstructor" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BasicAvoidMultipleUnaryOperators" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicAvoidThreadGroup" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="BasicAvoidUsingHardCodedIP" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicAvoidUsingOctalValues" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicBigIntegerInstantiation" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BasicBooleanInstantiation" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BasicBrokenNullCheck" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BasicCheckResultSet" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicCheckSkipResult" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicClassCastExceptionWithToArray" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BasicCollapsibleIfStatements" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="BasicDontCallThreadRun" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicDontUseFloatTypeForLoopIndices" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicDoubleCheckedLocking" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicExtendsObject" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicForLoopShouldBeWhileLoop" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSFDontNestJsfInJstlIteration" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPIframeMissingSrcAttribute" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoClassAttribute" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoHtmlComments" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoInlineStyleInformation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoJspForward" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoLongScripts" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJSPNoScriptlets" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicJumbledIncrementer" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicMisplacedNullCheck" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="BasicOverrideBothEqualsAndHashcode" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="BasicReturnFromFinallyBlock" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="BasicUnconditionalIfStatement" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="BooleanExpressionComplexityCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BracesForLoopsMustUseBraces" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BracesIfElseStmtsMustUseBraces" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BracesIfStmtsMustUseBraces" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="BracesWhileLoopsMustUseBraces" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CD_CIRCULAR_DEPENDENCY" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CI_CONFUSED_INHERITANCE" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="CN_IDIOM" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CN_IDIOM_NO_SUPER_CALL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CN_IMPLEMENTS_CLONE_BUT_NOT_CLONEABLE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CO_ABSTRACT_SELF" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CO_COMPARETO_RESULTS_MIN_VALUE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="CO_SELF_NO_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ClassDataAbstractionCouplingCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ClassFanOutComplexityCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ClassTypeParameterNameCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CloneImplementationCloneMethodMustImplementCloneable" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CloneImplementationCloneThrowsCloneNotSupportedException" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CloneImplementationProperCloneImplementation" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeCyclomaticComplexity" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeExcessiveClassLength" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeExcessiveMethodLength" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeExcessiveParameterList" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeExcessivePublicCount" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeNPathComplexity" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeNcssConstructorCount" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeNcssMethodCount" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CodeSizeNcssTypeCount" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CodeSizeTooManyFields" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CodeSizeTooManyMethods" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ConstantNameCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="ControversialAssignmentInOperand" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAtLeastOneConstructor" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidAccessibilityAlteration" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidFinalLocalVariable" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidLiteralsInIfCondition" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidPrefixingMethodParameters" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidUsingNativeCode" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidUsingShortType" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialAvoidUsingVolatile" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialBooleanInversion" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialCallSuperInConstructor" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialDataflowAnomalyAnalysis" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialDefaultPackage" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialDoNotCallGarbageCollectionExplicitly" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="ControversialDontImportSun" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="ControversialNullAssignment" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialOneDeclarationPerLine" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialOnlyOneReturn" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialSuspiciousOctalEscape" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialUnnecessaryConstructor" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialUnnecessaryParentheses" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialUseConcurrentHashMap" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ControversialUseObjectForClearerAPI" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CouplingCouplingBetweenObjects" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CouplingExcessiveImports" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CouplingLawOfDemeter" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CouplingLooseCoupling" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="CouplingLoosePackageCoupling" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CovariantEqualsCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="CyclomaticComplexityCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DB_DUPLICATE_BRANCHES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DB_DUPLICATE_SWITCH_CLAUSES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DC_DOUBLECHECK" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DE_MIGHT_DROP" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DE_MIGHT_IGNORE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DLS_DEAD_LOCAL_STORE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DLS_DEAD_LOCAL_STORE_IN_RETURN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DLS_DEAD_LOCAL_STORE_OF_NULL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DLS_DEAD_LOCAL_STORE_SHADOWS_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DLS_DEAD_STORE_OF_CLASS_LITERAL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DLS_OVERWRITTEN_INCREMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DL_SYNCHRONIZATION_ON_BOOLEAN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DL_SYNCHRONIZATION_ON_BOXED_PRIMITIVE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DL_SYNCHRONIZATION_ON_SHARED_CONSTANT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DL_SYNCHRONIZATION_ON_UNSHARED_BOXED_PRIMITIVE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_ANNOTATION_IS_NOT_VISIBLE_TO_REFLECTION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_ARGUMENTS_WRONG_ORDER" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DMI_BAD_MONTH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_BIGDECIMAL_CONSTRUCTED_FROM_DOUBLE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DMI_BLOCKING_METHODS_ON_URL" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="DMI_CALLING_NEXT_FROM_HASNEXT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_COLLECTIONS_SHOULD_NOT_CONTAIN_THEMSELVES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_COLLECTION_OF_URLS" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="DMI_CONSTANT_DB_PASSWORD" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="DMI_DOH" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DMI_EMPTY_DB_PASSWORD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_ENTRY_SETS_MAY_REUSE_ENTRY_OBJECTS" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DMI_FUTILE_ATTEMPT_TO_CHANGE_MAXPOOL_SIZE_OF_SCHEDULED_THREAD_POOL_EXECUTOR" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_HARDCODED_ABSOLUTE_FILENAME" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_INVOKING_HASHCODE_ON_ARRAY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_INVOKING_TOSTRING_ON_ANONYMOUS_ARRAY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_INVOKING_TOSTRING_ON_ARRAY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_LONG_BITS_TO_DOUBLE_INVOKED_ON_INT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_NONSERIALIZABLE_OBJECT_WRITTEN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_RANDOM_USED_ONLY_ONCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_SCHEDULED_THREAD_POOL_EXECUTOR_WITH_ZERO_CORE_THREADS" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_THREAD_PASSED_WHERE_RUNNABLE_EXPECTED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_UNSUPPORTED_METHOD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_USELESS_SUBSTRING" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_USING_REMOVEALL_TO_CLEAR_COLLECTION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DMI_VACUOUS_CALL_TO_EASYMOCK_METHOD" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DMI_VACUOUS_SELF_COLLECTION_CALL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DM_BOOLEAN_CTOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_BOXED_PRIMITIVE_TOSTRING" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_CONVERT_CASE" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="DM_DEFAULT_ENCODING" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DM_EXIT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_FP_NUMBER_CTOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_GC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_MONITOR_WAIT_ON_CONDITION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_NEW_FOR_GETCLASS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_NEXTINT_VIA_NEXTDOUBLE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_NUMBER_CTOR" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DM_RUN_FINALIZERS_ON_EXIT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_STRING_CTOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_STRING_TOSTRING" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="DM_STRING_VOID_CTOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DM_USELESS_THREAD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DP_DO_INSIDE_DO_PRIVILEGED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DeclarationOrderCheck" level="INFO" enabled="false">
|
|
||||||
<param name="ignoreConstructors" value="false" />
|
|
||||||
<param name="ignoreMethods" value="false" />
|
|
||||||
<param name="ignoreModifiers" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="DefaultComesLastCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DescendantTokenCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAbstractClassWithoutAbstractMethod" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAbstractClassWithoutAnyMethod" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAccessorClassGeneration" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAssignmentToNonFinalStatic" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAvoidConstantsInterface" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAvoidDeeplyNestedIfStmts" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAvoidInstanceofChecksInCatchClause" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignAvoidProtectedFieldInFinalClass" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAvoidReassigningParameters" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignAvoidSynchronizedAtMethodLevel" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignBadComparison" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignClassWithOnlyPrivateConstructorsShouldBeFinal" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignCloseResource" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignCompareObjectsWithEquals" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignConfusingTernary" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignConstructorCallsOverridableMethod" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignDefaultLabelNotLastInSwitchStmt" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignEmptyMethodInAbstractClassShouldBeAbstract" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignEqualsNull" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="DesignFieldDeclarationsShouldBeAtStartOfClass" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignFinalFieldCouldBeStatic" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignForExtensionCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="DesignGodClass" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignIdempotentOperations" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignImmutableField" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignInstantiationToGetClass" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignLogicInversion" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignMissingBreakInSwitch" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="DesignMissingStaticMethodInNonInstantiatableClass" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignNonCaseLabelInSwitchStatement" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignNonStaticInitializer" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignNonThreadSafeSingleton" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignOptimizableToArrayCall" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignPositionLiteralsFirstInComparisons" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignPreserveStackTrace" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignReturnEmptyArrayRatherThanNull" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignSimpleDateFormatNeedsLocale" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignSimplifyBooleanExpressions" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignSimplifyBooleanReturns" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignSimplifyConditional" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignSingularField" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignSwitchDensity" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignSwitchStmtsShouldHaveDefault" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignTooFewBranchesForASwitchStatement" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUncommentedEmptyConstructor" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUncommentedEmptyMethod" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUnnecessaryLocalBeforeReturn" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="DesignUnsynchronizedStaticDateFormatter" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUseCollectionIsEmpty" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUseLocaleWithCaseConversions" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUseNotifyAllInsteadOfNotify" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUseSingleton" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="DesignUseVarargs" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EC_ARRAY_AND_NONARRAY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_BAD_ARRAY_COMPARE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_INCOMPATIBLE_ARRAY_COMPARE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EC_NULL_ARG" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_UNRELATED_CLASS_AND_INTERFACE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_UNRELATED_INTERFACES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_UNRELATED_TYPES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EC_UNRELATED_TYPES_USING_POINTER_EQUALITY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EI_EXPOSE_REP" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EI_EXPOSE_REP2" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EI_EXPOSE_STATIC_REP2" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_ABSTRACT_SELF" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_ALWAYS_FALSE" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="EQ_ALWAYS_TRUE" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_COMPARETO_USE_OBJECT_EQUALS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EQ_COMPARING_CLASS_NAMES" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_DOESNT_OVERRIDE_EQUALS" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EQ_DONT_DEFINE_EQUALS_FOR_ENUM" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_GETCLASS_AND_CLASS_CONSTANT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EQ_OTHER_NO_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_OTHER_USE_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_OVERRIDING_EQUALS_NOT_SYMMETRIC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_SELF_NO_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_SELF_USE_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EQ_UNUSUAL" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="ES_COMPARING_PARAMETER_STRING_WITH_EQ" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ES_COMPARING_STRINGS_WITH_EQ" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ESync_EMPTY_SYNC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EmptyBlockCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyCatchBlock" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyFinallyBlock" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyIfStmt" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyInitializer" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyStatementBlock" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyStatementNotInLoop" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyStaticInitializer" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptySwitchStatements" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptySynchronizedBlock" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyTryBlock" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="EmptyCodeEmptyWhileStmt" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="EmptyForInitializerPadCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="EmptyForIteratorPadCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="EmptyStatementCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="EqualsAvoidNullCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="ignoreEqualsIgnoreCase" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="EqualsHashCodeCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ExecutableStatementCountCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ExplicitInitializationCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="FB_MISSING_EXPECTED_WARNING" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="FB_UNEXPECTED_WARNING" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="FE_FLOATING_POINT_EQUALITY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="FE_TEST_IF_EQUAL_TO_NOT_A_NUMBER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="FI_EMPTY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_EXPLICIT_INVOCATION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_FINALIZER_NULLS_FIELDS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_FINALIZER_ONLY_NULLS_FIELDS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_MISSING_SUPER_CALL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_NULLIFY_SUPER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="FI_PUBLIC_SHOULD_BE_PROTECTED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FI_USELESS" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="FL_MATH_USING_FLOAT_PRECISION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="FallThroughCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="FileLengthCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="FileTabCharacterCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="FinalClassCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FinalLocalVariableCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="FinalParametersCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="FinalizerAvoidCallingFinalize" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FinalizerEmptyFinalizer" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FinalizerFinalizeDoesNotCallSuperFinalize" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FinalizerFinalizeOnlyCallsSuperFinalize" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="FinalizerFinalizeOverloaded" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="FinalizerFinalizeShouldBeProtected" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="GC_UNCHECKED_TYPE_IN_GENERIC_CALL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="GC_UNRELATED_TYPES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="GenericWhitespaceCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="HE_EQUALS_NO_HASHCODE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="HE_EQUALS_USE_HASHCODE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HE_HASHCODE_NO_EQUALS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HE_HASHCODE_USE_OBJECT_EQUALS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HE_INHERITS_EQUALS_USE_HASHCODE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HE_SIGNATURE_DECLARES_HASHING_OF_UNHASHABLE_CLASS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HE_USE_OF_UNHASHABLE_CLASS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HRS_REQUEST_PARAMETER_TO_COOKIE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="HRS_REQUEST_PARAMETER_TO_HTTP_HEADER" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="HSC_HUGE_SHARED_STRING_CONSTANT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="HeaderCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="HiddenFieldCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="HideUtilityClassConstructorCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="IA_AMBIGUOUS_INVOCATION_OF_INHERITED_OR_OUTER_METHOD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_BAD_SHIFT_AMOUNT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_IDIV_CAST_TO_DOUBLE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_INTEGER_MULTIPLY_CAST_TO_LONG" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_INT_2_LONG_AS_INSTANT" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="ICAST_INT_CAST_TO_DOUBLE_PASSED_TO_CEIL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_INT_CAST_TO_FLOAT_PASSED_TO_ROUND" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ICAST_QUESTIONABLE_UNSIGNED_RIGHT_SHIFT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IC_INIT_CIRCULARITY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IC_SUPERCLASS_USES_SUBCLASS_DURING_INITIALIZATION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="IJU_ASSERT_METHOD_INVOKED_FROM_RUN_METHOD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IJU_BAD_SUITE_METHOD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IJU_NO_TESTS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IJU_SETUP_NO_SUPER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IJU_SUITE_NOT_STATIC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IJU_TEARDOWN_NO_SUPER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IL_CONTAINER_ADDED_TO_ITSELF" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IL_INFINITE_LOOP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IL_INFINITE_RECURSIVE_LOOP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IMA_INEFFICIENT_MEMBER_ACCESS" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IMSE_DONT_CATCH_IMSE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="IM_AVERAGE_COMPUTATION_COULD_OVERFLOW" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IM_BAD_CHECK_FOR_ODD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IM_MULTIPLYING_RESULT_OF_IREM" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="INT_BAD_COMPARISON_WITH_INT_VALUE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="INT_BAD_COMPARISON_WITH_NONNEGATIVE_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="INT_BAD_COMPARISON_WITH_SIGNED_BYTE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="INT_BAD_REM_BY_1" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="INT_VACUOUS_BIT_OPERATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="INT_VACUOUS_COMPARISON" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IO_APPENDING_TO_OBJECT_OUTPUT_STREAM" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IP_PARAMETER_IS_DEAD_BUT_OVERWRITTEN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IS2_INCONSISTENT_SYNC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ISC_INSTANTIATE_STATIC_CLASS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="IS_FIELD_NOT_GUARDED" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ITA_INEFFICIENT_TO_ARRAY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="IT_NO_SUCH_ELEMENT" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="IllegalCatchCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IllegalImportCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IllegalInstantiationCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IllegalThrowsCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="IllegalTokenCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IllegalTokenTextCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="IllegalTypeCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ImportControlCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ImportOrderCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="ImportStatementsDontImportJavaLang" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="ImportStatementsDuplicateImports" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ImportStatementsImportFromSamePackage" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="ImportStatementsTooManyStaticImports" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ImportStatementsUnusedImports" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="IndentationCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="InnerAssignmentCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="InnerTypeLastCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="InterfaceIsTypeCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EEDoNotCallSystemExit" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EEDoNotUseThreads" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EELocalHomeNamingConvention" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EELocalInterfaceSessionNamingConvention" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EEMDBAndSessionBeanNamingConvention" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EERemoteInterfaceNamingConvention" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EERemoteSessionInterfaceNamingConvention" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EEStaticEJBFieldShouldBeFinal" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="J2EEUseProperClassLoader" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="J2EE_STORE_OF_NON_SERIALIZABLE_OBJECT_INTO_SESSION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="JCIP_FIELD_ISNT_FINAL_IN_IMMUTABLE_CLASS" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="JLM_JSR166_LOCK_MONITORENTER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="JLM_JSR166_UTILCONCURRENT_MONITORENTER" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="JML_JSR166_CALLING_WAIT_RATHER_THAN_AWAIT" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="JUnitJUnitAssertionsShouldIncludeMessage" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitJUnitSpelling" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitJUnitStaticSuite" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitJUnitTestContainsTooManyAsserts" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitJUnitTestsShouldIncludeAssert" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitSimplifyBooleanAssertion" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitTestCaseCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitTestClassWithoutTestCases" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitUnnecessaryBooleanAssertion" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitUseAssertEqualsInsteadOfAssertTrue" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitUseAssertNullInsteadOfAssertTrue" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitUseAssertSameInsteadOfAssertTrue" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JUnitUseAssertTrueInsteadOfAssertEquals" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JakartaCommonsLoggingGuardDebugLogging" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JakartaCommonsLoggingProperLogger" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JakartaCommonsLoggingUseCorrectExceptionLogging" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="JavaBeansBeanMembersShouldSerialize" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavaBeansMissingSerialVersionUID" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavaLoggingAvoidPrintStackTrace" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="JavaLoggingLoggerIsNotStaticFinal" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavaLoggingMoreThanOneLogger" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavaLoggingSystemPrintln" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="JavaNCSSCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavadocMethodCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavadocPackageCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavadocStyleCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavadocTypeCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="JavadocVariableCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="LG_LOST_LOGGER_DUE_TO_WEAK_REFERENCE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="LI_LAZY_INIT_STATIC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="LI_LAZY_INIT_UPDATE_STATIC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="LeftCurlyCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="LineLengthCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="LocalFinalVariableNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="LocalVariableNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MF_CLASS_MASKS_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MF_METHOD_MASKS_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ML_SYNC_ON_FIELD_TO_GUARD_CHANGING_THAT_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ML_SYNC_ON_UPDATED_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MSF_MUTABLE_SERVLET_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_CANNOT_BE_FINAL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_EXPOSE_REP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="MS_FINAL_PKGPROTECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_MUTABLE_ARRAY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_MUTABLE_HASHTABLE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_OOI_PKGPROTECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_PKGPROTECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_SHOULD_BE_FINAL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MS_SHOULD_BE_REFACTORED_TO_BE_FINAL" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="MTIA_SUSPECT_SERVLET_INSTANCE_FIELD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="MTIA_SUSPECT_STRUTS_INSTANCE_FIELD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="MWN_MISMATCHED_NOTIFY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="MWN_MISMATCHED_WAIT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="MagicNumberCheck" level="INFO" enabled="true">
|
|
||||||
<param name="ignoreHashCodeMethod" value="false" />
|
|
||||||
<param name="ignoreAnnotation" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="MemberNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MethodCountCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="maxTotal" value="100" />
|
|
||||||
<param name="maxPrivate" value="100" />
|
|
||||||
<param name="maxPackage" value="100" />
|
|
||||||
<param name="maxProtected" value="100" />
|
|
||||||
<param name="maxPublic" value="100" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="MethodLengthCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MethodNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MethodParamPadCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MethodTypeParameterNameCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationAvoidAssertAsIdentifier" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationAvoidEnumAsIdentifier" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationByteInstantiation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationIntegerInstantiation" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationJUnit4SuitesShouldUseSuiteAnnotation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationJUnit4TestShouldUseAfterAnnotation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationJUnit4TestShouldUseBeforeAnnotation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationJUnit4TestShouldUseTestAnnotation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationJUnitUseExpected" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationLongInstantiation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MigrationReplaceEnumerationWithIterator" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationReplaceHashtableWithMap" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationReplaceVectorWithList" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="MigrationShortInstantiation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MissingCtorCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MissingDeprecatedCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MissingOverrideCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MissingSwitchDefaultCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ModifiedControlVariableCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ModifierOrderCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="MultipleStringLiteralsCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MultipleVariableDeclarationsCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="MutableExceptionCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_BAD_EQUAL" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_CLASS_NAMING_CONVENTION" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_CLASS_NOT_EXCEPTION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_CONFUSING" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_FIELD_NAMING_CONVENTION" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_FUTURE_KEYWORD_USED_AS_IDENTIFIER" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_FUTURE_KEYWORD_USED_AS_MEMBER_IDENTIFIER" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_LCASE_HASHCODE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_LCASE_TOSTRING" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_METHOD_CONSTRUCTOR_CONFUSION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_METHOD_NAMING_CONVENTION" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NM_SAME_SIMPLE_NAME_AS_INTERFACE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_SAME_SIMPLE_NAME_AS_SUPERCLASS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_VERY_CONFUSING" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_VERY_CONFUSING_INTENTIONAL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_WRONG_PACKAGE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NM_WRONG_PACKAGE_INTENTIONAL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NN_NAKED_NOTIFY" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NOISE_FIELD_REFERENCE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NOISE_METHOD_CALL" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NOISE_NULL_DEREFERENCE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NOISE_OPERATION" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NO_NOTIFY_NOT_NOTIFYALL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_ALWAYS_NULL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_ALWAYS_NULL_EXCEPTION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_ARGUMENT_MIGHT_BE_NULL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NP_BOOLEAN_RETURN_NULL" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NP_CLONE_COULD_RETURN_NULL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_CLOSING_NULL" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NP_DEREFERENCE_OF_READLINE_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_EQUALS_SHOULD_HANDLE_NULL_ARGUMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_GUARANTEED_DEREF" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="NP_GUARANTEED_DEREF_ON_EXCEPTION_PATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_IMMEDIATE_DEREFERENCE_OF_READLINE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_LOAD_OF_KNOWN_NULL_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NONNULL_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="NP_NONNULL_PARAM_VIOLATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NONNULL_RETURN_VIOLATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_INSTANCEOF" level="BLOCKER" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_ON_SOME_PATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_ON_SOME_PATH_EXCEPTION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_ON_SOME_PATH_MIGHT_BE_INFEASIBLE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_PARAM_DEREF" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_PARAM_DEREF_ALL_TARGETS_DANGEROUS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_NULL_PARAM_DEREF_NONVIRTUAL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_PARAMETER_MUST_BE_NONNULL_BUT_MARKED_AS_NULLABLE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_STORE_INTO_NONNULL_FIELD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_SYNC_AND_NULL_CHECK_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NP_TOSTRING_COULD_RETURN_NULL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NP_UNWRITTEN_FIELD" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NP_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="NPathComplexityCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NS_DANGEROUS_NON_SHORT_CIRCUIT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NS_NON_SHORT_CIRCUIT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingAbstractNaming" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingAvoidDollarSigns" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingAvoidFieldNameMatchingMethodName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingAvoidFieldNameMatchingTypeName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingBooleanGetMethodName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingClassNamingConventions" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingGenericsNaming" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingLongVariable" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingMethodNamingConventions" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingMethodWithSameNameAsEnclosingClass" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingMisleadingVariableName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingNoPackage" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingPackageCase" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingShortClassName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingShortMethodName" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingShortVariable" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NamingSuspiciousConstantFieldName" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingSuspiciousEqualsMethodName" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="NamingSuspiciousHashcodeMethodName" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="NamingVariableNamingConventions" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NeedBracesCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="NestedForDepthCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="max" value="1" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="NestedIfDepthCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NestedTryDepthCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NewlineAtEndOfFileCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="NoCloneCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NoFinalizerCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="NoWhitespaceAfterCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="NoWhitespaceBeforeCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="OBL_UNSATISFIED_OBLIGATION" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="ODR_OPEN_DATABASE_RESOURCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ODR_OPEN_DATABASE_RESOURCE_EXCEPTION_PATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="OS_OPEN_STREAM" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="OS_OPEN_STREAM_EXCEPTION_PATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="OneStatementPerLineCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="OperatorWrapCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationAddEmptyString" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationAvoidArrayLoops" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="OptimizationAvoidInstantiatingObjectsInLoops" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationLocalVariableCouldBeFinal" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationMethodArgumentCouldBeFinal" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationPrematureDeclaration" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationRedundantFieldInitializer" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationSimplifyStartsWith" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationUnnecessaryWrapperObjectCreation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="OptimizationUseArrayListInsteadOfVector" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="OptimizationUseArraysAsList" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="OptimizationUseStringBufferForStringAppends" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="OuterTypeFilenameCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="OuterTypeNumberCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="PS_PUBLIC_SEMAPHORES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="PT_ABSOLUTE_PATH_TRAVERSAL" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="PT_RELATIVE_PATH_TRAVERSAL" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="PZLA_PREFER_ZERO_LENGTH_ARRAYS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="PZ_DONT_REUSE_ENTRY_OBJECTS_IN_ITERATORS" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="PackageAnnotationCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="PackageDeclarationCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="ignoreDirectoryName" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="PackageNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ParameterAssignmentCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ParameterNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="ParameterNumberCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ParenPadCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="QBA_QUESTIONABLE_BOOLEAN_ASSIGNMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="QF_QUESTIONABLE_FOR_LOOP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RCN_REDUNDANT_COMPARISON_OF_NULL_AND_NONNULL_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RCN_REDUNDANT_COMPARISON_TWO_NULL_VALUES" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RCN_REDUNDANT_NULLCHECK_OF_NULL_VALUE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RC_REF_COMPARISON" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RC_REF_COMPARISON_BAD_PRACTICE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="RC_REF_COMPARISON_BAD_PRACTICE_BOOLEAN" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="REC_CATCH_EXCEPTION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RE_BAD_SYNTAX_FOR_REGULAR_EXPRESSION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RE_CANT_USE_FILE_SEPARATOR_AS_REGULAR_EXPRESSION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RE_POSSIBLE_UNINTENDED_PATTERN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RI_REDUNDANT_INTERFACES" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RR_NOT_CHECKED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RS_READOBJECT_SYNC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RU_INVOKE_RUN" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_01_TO_INT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_ABSOLUTE_VALUE_OF_HASHCODE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RV_ABSOLUTE_VALUE_OF_RANDOM_INT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RV_CHECK_COMPARETO_FOR_SPECIFIC_RETURN_VALUE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="RV_CHECK_FOR_POSITIVE_INDEXOF" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_DONT_JUST_NULL_CHECK_READLINE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_EXCEPTION_NOT_THROWN" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RV_NEGATING_RESULT_OF_COMPARETO" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="RV_REM_OF_HASHCODE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RV_REM_OF_RANDOM_INT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="RV_RETURN_VALUE_IGNORED" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_RETURN_VALUE_IGNORED_BAD_PRACTICE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="RV_RETURN_VALUE_IGNORED_INFERRED" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="RV_RETURN_VALUE_OF_PUTIFABSENT_IGNORED" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="RedundantImportCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="RedundantModifierCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="RedundantThrowsCheck" level="INFO" enabled="true" />
|
|
||||||
<coding_rule class="RegexpCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="RegexpHeaderCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="RegexpMultilineCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="message" value="TODO item found" />
|
|
||||||
<param name="minimum" value="0" />
|
|
||||||
<param name="maximum" value="0" />
|
|
||||||
<param name="format" value="TODO" />
|
|
||||||
<param name="ignoreCase" value="true" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="RegexpSinglelineCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="message" value="TODO item found" />
|
|
||||||
<param name="minimum" value="0" />
|
|
||||||
<param name="maximum" value="0" />
|
|
||||||
<param name="format" value="TODO" />
|
|
||||||
<param name="ignoreCase" value="true" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="RegexpSinglelineJavaCheck" level="MAJOR" enabled="false">
|
|
||||||
<param name="message" value="TODO item found" />
|
|
||||||
<param name="minimum" value="0" />
|
|
||||||
<param name="maximum" value="0" />
|
|
||||||
<param name="ignoreComments" value="false" />
|
|
||||||
<param name="format" value="TODO" />
|
|
||||||
<param name="ignoreCase" value="true" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="RequireThisCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="ReturnCountCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="RightCurlyCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="RpC_REPEATED_CONDITIONAL_TEST" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SA_FIELD_DOUBLE_ASSIGNMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_FIELD_SELF_ASSIGNMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_FIELD_SELF_COMPARISON" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_FIELD_SELF_COMPUTATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_LOCAL_DOUBLE_ASSIGNMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_LOCAL_SELF_ASSIGNMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_LOCAL_SELF_ASSIGNMENT_INSTEAD_OF_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="SA_LOCAL_SELF_COMPARISON" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SA_LOCAL_SELF_COMPUTATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SBSC_USE_STRINGBUFFER_CONCATENATION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SC_START_IN_CTOR" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SE_BAD_FIELD" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="SE_BAD_FIELD_INNER_CLASS" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_BAD_FIELD_STORE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SE_COMPARATOR_SHOULD_BE_SERIALIZABLE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_INNER_CLASS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_METHOD_MUST_BE_PRIVATE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_NONFINAL_SERIALVERSIONID" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SE_NONLONG_SERIALVERSIONID" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_NONSTATIC_SERIALVERSIONID" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_NO_SERIALVERSIONID" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_NO_SUITABLE_CONSTRUCTOR" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_NO_SUITABLE_CONSTRUCTOR_FOR_EXTERNALIZATION" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_PRIVATE_READ_RESOLVE_NOT_INHERITED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_READ_RESOLVE_IS_STATIC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_READ_RESOLVE_MUST_RETURN_OBJECT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_TRANSIENT_FIELD_NOT_RESTORED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SE_TRANSIENT_FIELD_OF_NONSERIALIZABLE_CLASS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SF_DEAD_STORE_DUE_TO_SWITCH_FALLTHROUGH" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SF_DEAD_STORE_DUE_TO_SWITCH_FALLTHROUGH_TO_THROW" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SF_SWITCH_FALLTHROUGH" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SF_SWITCH_NO_DEFAULT" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SIC_INNER_SHOULD_BE_STATIC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SIC_INNER_SHOULD_BE_STATIC_ANON" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SIC_INNER_SHOULD_BE_STATIC_NEEDS_THIS" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SIC_THREADLOCAL_DEADLY_EMBRACE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SIO_SUPERFLUOUS_INSTANCEOF" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SI_INSTANCE_BEFORE_FINALS_ASSIGNED" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SP_SPIN_ON_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SQL_BAD_PREPARED_STATEMENT_ACCESS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SQL_BAD_RESULTSET_ACCESS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SQL_NONCONSTANT_STRING_PASSED_TO_EXECUTE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SQL_PREPARED_STATEMENT_GENERATED_FROM_NONCONSTANT_STRING" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SR_NOT_CHECKED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SS_SHOULD_BE_STATIC" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="STCAL_INVOKE_ON_STATIC_CALENDAR_INSTANCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="STCAL_INVOKE_ON_STATIC_DATE_FORMAT_INSTANCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="STCAL_STATIC_CALENDAR_INSTANCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="STCAL_STATIC_SIMPLE_DATE_FORMAT_INSTANCE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="STI_INTERRUPTED_ON_CURRENTTHREAD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="STI_INTERRUPTED_ON_UNKNOWNTHREAD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SWL_SLEEP_WITH_LOCK_HELD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SW_SWING_METHODS_INVOKED_IN_SWING_THREAD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SecurityCodeGuidelinesArrayIsStoredDirectly" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="SecurityCodeGuidelinesMethodReturnsInternalArray" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="SimplifyBooleanExpressionCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="SimplifyBooleanReturnCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StaticVariableNameCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictDuplicateCodeCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidCatchingGenericException" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidCatchingNPE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidCatchingThrowable" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidLosingExceptionInformation" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidRethrowingException" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidThrowingNewInstanceOfSameException" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidThrowingNullPointerException" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsAvoidThrowingRawExceptionTypes" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsDoNotExtendJavaLangError" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsDoNotThrowExceptionInFinally" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StrictExceptionsExceptionAsFlowControl" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StrictExceptionsSignatureDeclareThrowsException" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringLiteralEqualityCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferAppendCharacterWithChar" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferAvoidDuplicateLiterals" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferAvoidStringBufferField" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferConsecutiveLiteralAppends" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferInefficientEmptyStringCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferInefficientStringBuffering" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferInsufficientStringBufferDeclaration" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferStringBufferInstantiationWithChar" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferStringInstantiation" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferStringToString" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferUnnecessaryCaseChange" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferUseEqualsToCompareStrings" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="StringandStringBufferUseIndexOfChar" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferUseStringBufferLength" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="StringandStringBufferUselessStringValueOf" level="MINOR" enabled="true" />
|
|
||||||
<coding_rule class="SuperCloneCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SuperFinalizeCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="SuppressWarningsCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="TLW_TWO_LOCK_WAIT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="TQ_ALWAYS_VALUE_USED_WHERE_NEVER_REQUIRED" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_COMPARING_VALUES_WITH_INCOMPATIBLE_TYPE_QUALIFIERS" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="TQ_EXPLICIT_UNKNOWN_SOURCE_VALUE_REACHES_ALWAYS_SINK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_EXPLICIT_UNKNOWN_SOURCE_VALUE_REACHES_NEVER_SINK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_MAYBE_SOURCE_VALUE_REACHES_ALWAYS_SINK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_MAYBE_SOURCE_VALUE_REACHES_NEVER_SINK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_NEVER_VALUE_USED_WHERE_ALWAYS_REQUIRED" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="TQ_UNKNOWN_VALUE_USED_WHERE_ALWAYS_STRICTLY_REQUIRED" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="ThrowsCountCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="TodoCommentCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="TrailingCommentCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="TranslationCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="TypeNameCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="TypeResolutionCloneMethodMustImplementCloneable" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="TypeResolutionLooseCoupling" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="TypeResolutionSignatureDeclareThrowsException" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="TypeResolutionUnusedImports" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="TypecastParenPadCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UCF_USELESS_CONTROL_FLOW" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UCF_USELESS_CONTROL_FLOW_NEXT_LINE" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UG_SYNC_SET_UNSYNC_GET" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UI_INHERITANCE_UNSAFE_GETRESOURCE" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UL_UNRELEASED_LOCK" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UL_UNRELEASED_LOCK_EXCEPTION_PATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UMAC_UNCALLABLE_METHOD_OF_ANONYMOUS_CLASS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UM_UNNECESSARY_MATH" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UPM_UNCALLED_PRIVATE_METHOD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="URF_UNREAD_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="UR_UNINIT_READ" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UR_UNINIT_READ_CALLED_FROM_SUPER_CONSTRUCTOR" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="USM_USELESS_ABSTRACT_METHOD" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="USM_USELESS_SUBCLASS_METHOD" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UUF_UNUSED_FIELD" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UUF_UNUSED_PUBLIC_OR_PROTECTED_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UWF_NULL_FIELD" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UWF_UNWRITTEN_FIELD" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UWF_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="UW_UNCOND_WAIT" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UncommentedMainCheck" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UnnecessaryParenthesesCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="UnnecessaryUnnecessaryConversionTemporary" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UnnecessaryUnnecessaryFinalModifier" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="UnnecessaryUnnecessaryReturn" level="MINOR" enabled="false" />
|
|
||||||
<coding_rule class="UnnecessaryUnusedNullCheckInEquals" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnnecessaryUselessOperationOnImmutable" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="UnnecessaryUselessOverridingMethod" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnnecessaryUselessParentheses" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="UnusedCodeUnusedFormalParameter" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnusedCodeUnusedLocalVariable" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnusedCodeUnusedModifier" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnusedCodeUnusedPrivateField" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnusedCodeUnusedPrivateMethod" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="UnusedImportsCheck" level="INFO" enabled="true">
|
|
||||||
<param name="processJavadoc" value="false" />
|
|
||||||
</coding_rule>
|
|
||||||
<coding_rule class="UpperEllCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_BAD_ARGUMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_BAD_CONVERSION" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_BAD_CONVERSION_FROM_ARRAY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_BAD_CONVERSION_TO_BOOLEAN" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_EXPECTED_MESSAGE_FORMAT_SUPPLIED" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_EXTRA_ARGUMENTS_PASSED" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_ILLEGAL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_MISSING_ARGUMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_NO_PREVIOUS_ARGUMENT" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VA_FORMAT_STRING_USES_NEWLINE" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="VA_PRIMITIVE_ARRAY_PASSED_TO_OBJECT_VARARG" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="VO_VOLATILE_INCREMENT" level="CRITICAL" enabled="false" />
|
|
||||||
<coding_rule class="VO_VOLATILE_REFERENCE_TO_ARRAY" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="VR_UNRESOLVABLE_REFERENCE" level="MAJOR" enabled="false" />
|
|
||||||
<coding_rule class="VisibilityModifierCheck" level="MAJOR" enabled="true" />
|
|
||||||
<coding_rule class="WA_AWAIT_NOT_IN_LOOP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="WA_NOT_IN_LOOP" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="WL_USING_GETCLASS_RATHER_THAN_CLASS_LITERAL" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="WMI_WRONG_MAP_ITERATOR" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="WS_WRITEOBJECT_SYNC" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="WhitespaceAfterCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="WhitespaceAroundCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="WriteTagCheck" level="INFO" enabled="false" />
|
|
||||||
<coding_rule class="XFB_XML_FACTORY_BYPASS" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="XSS_REQUEST_PARAMETER_TO_JSP_WRITER" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="XSS_REQUEST_PARAMETER_TO_SEND_ERROR" level="CRITICAL" enabled="true" />
|
|
||||||
<coding_rule class="XSS_REQUEST_PARAMETER_TO_SERVLET_WRITER" level="CRITICAL" enabled="true" />
|
|
||||||
</profile>
|
|
||||||
</profiles>
|
|
||||||
<list size="0" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
|
|
@ -1,12 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="RunConfigurationProducerService">
|
|
||||||
<option name="ignoredProducers">
|
|
||||||
<set>
|
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
|
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
|
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
|
|
||||||
</set>
|
|
||||||
</option>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
@ -1,5 +0,0 @@
|
|||||||
<component name="DependencyValidationManager">
|
|
||||||
<state>
|
|
||||||
<option name="SKIP_IMPORT_STATEMENTS" value="false" />
|
|
||||||
</state>
|
|
||||||
</component>
|
|
@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="VcsDirectoryMappings">
|
|
||||||
<mapping directory="" vcs="Git" />
|
|
||||||
<mapping directory="$PROJECT_DIR$/jsword-minimalbible" vcs="Git" />
|
|
||||||
<mapping directory="$PROJECT_DIR$/jsword-minimalbible/jsword" vcs="Git" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
28
.travis.yml
28
.travis.yml
@ -1,29 +1,19 @@
|
|||||||
language: android
|
language: java
|
||||||
env:
|
env:
|
||||||
|
matrix:
|
||||||
|
- ANDROID_HOME="./android-sdk-linux"
|
||||||
global:
|
global:
|
||||||
- secure: FFXEK5dnQaJ2nSyaggVO66uNfpM6WYdS962qjY4ry9OumoK9OHg25MeQPrWmQurUaDDRfzdjMTs0UicWvJAnka846dDpYVbt0bpWbnNsq8vb05h1XhCsjjnEwcgPzbbyoAecmx7m1noAhkjFVnqmUhnjoYIsNd/pIRplO+r+0PY=
|
- secure: FFXEK5dnQaJ2nSyaggVO66uNfpM6WYdS962qjY4ry9OumoK9OHg25MeQPrWmQurUaDDRfzdjMTs0UicWvJAnka846dDpYVbt0bpWbnNsq8vb05h1XhCsjjnEwcgPzbbyoAecmx7m1noAhkjFVnqmUhnjoYIsNd/pIRplO+r+0PY=
|
||||||
- secure: jrti7lGbCxscGDzOVgcVuIMSFnTUfJSbL5VtvhZXKllRoKeuM4tJ8HMubUKG0UXR0VGZl3XPcj3Ga7W6gxxSOavA9zmkT1kC9v/ya9QPQI1hCn1kq0GESxj3uFeYyiSa3T/0GcEO0bB660ttRSfpSwQ+MZknJUzIIdTt7K3LjXA=
|
- secure: BezK2LQRlHA4bgfShHH9l8/N0roGcMCxzAXV3CoGw4OWp6npUbIGvj1H4scA2OAMpct7u6fS9T0//FQehe6tbsHniVfsRxrmwsj8SqXQ6E3tQ4lZeFu9q6dy2qgIaktY9q2SIkf+/1DG5b7gd/KJX4luU8LX1RErorco6+MGuoQ=
|
||||||
|
|
||||||
android:
|
|
||||||
components:
|
|
||||||
- platform-tools
|
|
||||||
- tools
|
|
||||||
- android-22
|
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
# -in is a switch to openssl
|
|
||||||
- openssl aes-256-cbc -K $encrypted_b017c1e684ac_key -iv $encrypted_b017c1e684ac_iv
|
- openssl aes-256-cbc -K $encrypted_b017c1e684ac_key -iv $encrypted_b017c1e684ac_iv
|
||||||
-in app/src/main/play/play_api.p12.enc -out app/src/main/play/play_api.p12 -d
|
-in play_api.p12.enc -out play_api.p12 -d
|
||||||
|
- bash android_install.sh
|
||||||
# We have to make sure the actual JSword is updated
|
|
||||||
- git submodule update --init --recursive
|
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- ./gradlew test
|
- ./gradlew test
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- ./gradlew jacocoTestReport coveralls
|
- ./gradlew jacocoTestReport coveralls
|
||||||
- if [ $TRAVIS_TAG ];
|
- if [ $TRAVIS_TAG ]; then
|
||||||
then echo "Publishing to Play store...";
|
echo "Publishing to Play store..."
|
||||||
./gradlew publishRelease;
|
./gradlew publishRelease
|
||||||
fi
|
fi
|
||||||
|
@ -1,19 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<module external.linked.project.id="MinimalBible" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" external.system.module.group="" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
|
|
||||||
<component name="FacetManager">
|
|
||||||
<facet type="java-gradle" name="Java-Gradle">
|
|
||||||
<configuration>
|
|
||||||
<option name="BUILD_FOLDER_PATH" value="$MODULE_DIR$/build" />
|
|
||||||
<option name="BUILDABLE" value="false" />
|
|
||||||
</configuration>
|
|
||||||
</facet>
|
|
||||||
</component>
|
|
||||||
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7" inherit-compiler-output="true">
|
|
||||||
<exclude-output />
|
|
||||||
<content url="file://$MODULE_DIR$">
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/.gradle" />
|
|
||||||
</content>
|
|
||||||
<orderEntry type="inheritedJdk" />
|
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
|
||||||
</component>
|
|
||||||
</module>
|
|
@ -4,21 +4,19 @@ COMPONENTS="
|
|||||||
tools
|
tools
|
||||||
platform-tools
|
platform-tools
|
||||||
build-tools-21.1.2
|
build-tools-21.1.2
|
||||||
android-22
|
android-21
|
||||||
extra-android-m2repository
|
extra-android-m2repository
|
||||||
extra-android-support
|
extra-android-support
|
||||||
extra-google-m2repository"
|
extra-google-m2repository"
|
||||||
|
|
||||||
SDK_VERSION="24.1.2"
|
|
||||||
|
|
||||||
echo "Updating packages..."
|
echo "Updating packages..."
|
||||||
sudo apt-get update -qq
|
sudo apt-get update -qq
|
||||||
|
|
||||||
echo "Installing Android dependencies..."
|
echo "Installing Android dependencies..."
|
||||||
sudo apt-get install -qq --force-yes libgd2-xpm ia32-libs ia32-libs-multiarch
|
sudo apt-get install -qq --force-yes libgd2-xpm ia32-libs ia32-libs-multiarch
|
||||||
|
|
||||||
wget http://dl.google.com/android/android-sdk_r${SDK_VERSION}-linux.tgz
|
wget http://dl.google.com/android/android-sdk_r23.0.2-linux.tgz
|
||||||
tar -zxf android-sdk_r${SDK_VERSION}-linux.tgz
|
tar -zxf android-sdk_r23.0.2-linux.tgz
|
||||||
|
|
||||||
for COMP in ${COMPONENTS}
|
for COMP in ${COMPONENTS}
|
||||||
do
|
do
|
||||||
|
1
app-test/.gitignore
vendored
Normal file
1
app-test/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
/build
|
96
app-test/build.gradle
Normal file
96
app-test/build.gradle
Normal file
@ -0,0 +1,96 @@
|
|||||||
|
apply plugin: 'java'
|
||||||
|
apply plugin: 'kotlin'
|
||||||
|
apply plugin: 'jacoco'
|
||||||
|
apply plugin: 'com.github.kt3k.coveralls'
|
||||||
|
|
||||||
|
evaluationDependsOn(":app")
|
||||||
|
|
||||||
|
buildscript {
|
||||||
|
repositories {
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
// Version lock for https://github.com/kt3k/coveralls-gradle-plugin/issues/27
|
||||||
|
classpath 'org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.0.1x'
|
||||||
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
maven {
|
||||||
|
url 'http://repository.jetbrains.com/repo'
|
||||||
|
}
|
||||||
|
mavenCentral()
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: Make sure we test against the Debug variant
|
||||||
|
def androidModule = project(':app')
|
||||||
|
def firstVariant = androidModule.android.applicationVariants.toList().first()
|
||||||
|
|
||||||
|
def testIncludes = [
|
||||||
|
'**/*Test.class',
|
||||||
|
'**/*Spek.class'
|
||||||
|
]
|
||||||
|
def jacocoExcludes = [
|
||||||
|
'android/**',
|
||||||
|
'com/todddavies/**',
|
||||||
|
'com/cmwmobile/**',
|
||||||
|
'org/bspeice/minimalbible/R*',
|
||||||
|
'**/BookAdapter$ChapterInfo*',
|
||||||
|
'**/*$$*' // Dagger/Butterknife
|
||||||
|
]
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
compile androidModule
|
||||||
|
|
||||||
|
testCompile 'junit:junit:4.+'
|
||||||
|
testCompile 'org.robolectric:robolectric:2.+'
|
||||||
|
testCompile 'org.mockito:mockito-core:+'
|
||||||
|
testCompile 'com.jayway.awaitility:awaitility:+'
|
||||||
|
testCompile 'org.jetbrains.spek:spek:0.1-SNAPSHOT'
|
||||||
|
|
||||||
|
testCompile firstVariant.javaCompile.classpath
|
||||||
|
testCompile firstVariant.javaCompile.outputs.files
|
||||||
|
testCompile files(androidModule.plugins.findPlugin("com.android.application").getBootClasspath())
|
||||||
|
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
||||||
|
}
|
||||||
|
|
||||||
|
def buildExcludeTree(path, excludes) {
|
||||||
|
//noinspection GroovyAssignabilityCheck
|
||||||
|
def tree = fileTree(path).exclude(excludes)
|
||||||
|
tree
|
||||||
|
}
|
||||||
|
|
||||||
|
jacocoTestReport {
|
||||||
|
doFirst {
|
||||||
|
// First we build a list of our base directories
|
||||||
|
def fileList = new ArrayList<String>()
|
||||||
|
def outputsList = firstVariant.javaCompile.outputs.files
|
||||||
|
outputsList.each { fileList.add(it.absolutePath.toString()) }
|
||||||
|
|
||||||
|
// And build a fileTree from those
|
||||||
|
def outputTree = fileList.inject { tree1, tree2 ->
|
||||||
|
buildExcludeTree(tree1, jacocoExcludes) +
|
||||||
|
buildExcludeTree(tree2, jacocoExcludes)
|
||||||
|
}
|
||||||
|
|
||||||
|
// And finally tell Jacoco to only include said files in the report
|
||||||
|
// For whatever reason, firstVariant.javaCompile.exclude(jacocoExcludes) doesn't work...
|
||||||
|
classDirectories = outputTree
|
||||||
|
sourceDirectories = files(androidModule.android.sourceSets.main.java.srcDirs)
|
||||||
|
}
|
||||||
|
|
||||||
|
reports {
|
||||||
|
xml.enabled true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
coveralls {
|
||||||
|
sourceDirs = files(androidModule.android.sourceSets.main.java.srcDirs).files.absolutePath
|
||||||
|
}
|
||||||
|
|
||||||
|
tasks.withType(Test) {
|
||||||
|
scanForTestClasses = true
|
||||||
|
includes = testIncludes
|
||||||
|
}
|
@ -0,0 +1,31 @@
|
|||||||
|
package org.bspeice.minimalbible.activity.search;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
import org.robolectric.Robolectric;
|
||||||
|
import org.robolectric.RobolectricTestRunner;
|
||||||
|
import org.robolectric.annotation.Config;
|
||||||
|
|
||||||
|
import static org.junit.Assert.assertNotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Right now this is the only Robolectric test. Some clarifications on this should be made:
|
||||||
|
* There's an ongoing issue with the ActionBarDrawerToggle, meaning that the BasicSearch
|
||||||
|
* activity is the only one eligible for testing
|
||||||
|
* (https://github.com/robolectric/robolectric/issues/1424)
|
||||||
|
* <p/>
|
||||||
|
* Additionally, Robolectric only supports up to Jellybean, which is why the emulateSdk.
|
||||||
|
* Finally, in Gradle, tests run relative to app-test, whereas the IDE may try and run
|
||||||
|
* things in the project root. Be careful when changing the manifest location.
|
||||||
|
*/
|
||||||
|
@RunWith(RobolectricTestRunner.class)
|
||||||
|
@Config(emulateSdk = 18, manifest = "../app/src/main/AndroidManifest.xml")
|
||||||
|
public class BasicSearchTest {
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testBuildActivity() {
|
||||||
|
BasicSearch activity = Robolectric.buildActivity(BasicSearch.class)
|
||||||
|
.create().get();
|
||||||
|
assertNotNull(activity);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,295 @@
|
|||||||
|
package org.bspeice.minimalbible.test.activity.downloader.manager;
|
||||||
|
|
||||||
|
import android.net.ConnectivityManager;
|
||||||
|
import android.net.NetworkInfo;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.BookManager;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.DLProgressEvent;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
||||||
|
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
||||||
|
import org.crosswire.common.progress.JobManager;
|
||||||
|
import org.crosswire.common.progress.Progress;
|
||||||
|
import org.crosswire.common.progress.WorkEvent;
|
||||||
|
import org.crosswire.common.progress.WorkListener;
|
||||||
|
import org.crosswire.jsword.book.Book;
|
||||||
|
import org.crosswire.jsword.book.BookDriver;
|
||||||
|
import org.crosswire.jsword.book.BookException;
|
||||||
|
import org.crosswire.jsword.book.Books;
|
||||||
|
import org.crosswire.jsword.book.BooksEvent;
|
||||||
|
import org.crosswire.jsword.book.install.InstallManager;
|
||||||
|
import org.crosswire.jsword.book.install.Installer;
|
||||||
|
import org.crosswire.jsword.index.IndexManager;
|
||||||
|
import org.crosswire.jsword.index.IndexManagerFactory;
|
||||||
|
import org.junit.Before;
|
||||||
|
import org.junit.Ignore;
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.mockito.Mockito;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collection;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.concurrent.TimeUnit;
|
||||||
|
import java.util.concurrent.atomic.AtomicBoolean;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
import dagger.Provides;
|
||||||
|
import rx.Observable;
|
||||||
|
import rx.functions.Action1;
|
||||||
|
import rx.functions.Func1;
|
||||||
|
import rx.subjects.PublishSubject;
|
||||||
|
|
||||||
|
import static com.jayway.awaitility.Awaitility.await;
|
||||||
|
import static org.junit.Assert.assertFalse;
|
||||||
|
import static org.junit.Assert.assertTrue;
|
||||||
|
import static org.mockito.Mockito.mock;
|
||||||
|
import static org.mockito.Mockito.verify;
|
||||||
|
import static org.mockito.Mockito.when;
|
||||||
|
import static org.mockito.internal.verification.VerificationModeFactory.times;
|
||||||
|
|
||||||
|
// TODO: Fix @Ignore'd tests
|
||||||
|
public class BookManagerTest implements Injector {
|
||||||
|
|
||||||
|
ObjectGraph mObjectGraph;
|
||||||
|
@Inject
|
||||||
|
BookManager bookManager;
|
||||||
|
@Inject
|
||||||
|
RefreshManager refreshManager;
|
||||||
|
@Inject
|
||||||
|
Books installedBooks;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void inject(Object o) {
|
||||||
|
mObjectGraph.inject(o);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Before
|
||||||
|
public void setUp() {
|
||||||
|
BookDownloadManagerTestModules modules = new BookDownloadManagerTestModules(this);
|
||||||
|
mObjectGraph = ObjectGraph.create(modules);
|
||||||
|
mObjectGraph.inject(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
Observable<Book> installableBooks() {
|
||||||
|
return refreshManager.getFlatModules()
|
||||||
|
.filter(new Func1<Book, Boolean>() {
|
||||||
|
@Override
|
||||||
|
public Boolean call(Book book) {
|
||||||
|
return !installedBooks.getBooks().contains(book);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: Why doesn't this work?
|
||||||
|
@Ignore("Should be working, but isn't...")
|
||||||
|
@Test
|
||||||
|
public void testInstallBook() throws Exception {
|
||||||
|
final Book toInstall = installableBooks().toBlocking().first();
|
||||||
|
|
||||||
|
final AtomicBoolean signal = new AtomicBoolean(false);
|
||||||
|
bookManager.getDownloadEvents()
|
||||||
|
.subscribe(new Action1<DLProgressEvent>() {
|
||||||
|
@Override
|
||||||
|
public void call(DLProgressEvent dlProgressEvent) {
|
||||||
|
System.out.println(dlProgressEvent.getProgress());
|
||||||
|
if (dlProgressEvent.getB().getInitials().equals(toInstall.getInitials())
|
||||||
|
&& dlProgressEvent.getProgress() == DLProgressEvent.PROGRESS_COMPLETE) {
|
||||||
|
signal.set(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
bookManager.downloadBook(toInstall);
|
||||||
|
|
||||||
|
await().atMost(30, TimeUnit.SECONDS)
|
||||||
|
.untilTrue(signal);
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: Why doesn't this work?
|
||||||
|
@Ignore("Should be working, but isn't...")
|
||||||
|
@Test
|
||||||
|
public void testJobIdMatch() {
|
||||||
|
final Book toInstall = installableBooks().toBlocking().first();
|
||||||
|
final String jobName = bookManager.getJobName(toInstall);
|
||||||
|
final AtomicBoolean jobNameMatch = new AtomicBoolean(false);
|
||||||
|
|
||||||
|
JobManager.addWorkListener(new WorkListener() {
|
||||||
|
@Override
|
||||||
|
public void workProgressed(WorkEvent ev) {
|
||||||
|
if (ev.getJob().getJobID().equals(jobName)) {
|
||||||
|
jobNameMatch.set(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void workStateChanged(WorkEvent ev) {
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
bookManager.downloadBook(toInstall);
|
||||||
|
await().atMost(10, TimeUnit.SECONDS)
|
||||||
|
.untilTrue(jobNameMatch);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testLocalListUpdatedAfterAdd() {
|
||||||
|
Book mockBook = mock(Book.class);
|
||||||
|
BooksEvent event = mock(BooksEvent.class);
|
||||||
|
when(event.getBook()).thenReturn(mockBook);
|
||||||
|
|
||||||
|
bookManager.bookAdded(event);
|
||||||
|
assertTrue(bookManager.getInstalledBooksList().contains(mockBook));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This test requires deep knowledge of how to remove a book in order to test,
|
||||||
|
* but the Kotlin interface is nice!
|
||||||
|
*/
|
||||||
|
@Test
|
||||||
|
public void testLocalListUpdatedAfterRemove() throws BookException {
|
||||||
|
BookDriver driver = mock(BookDriver.class);
|
||||||
|
|
||||||
|
Book mockBook = mock(Book.class);
|
||||||
|
Book secondMockBook = mock(Book.class);
|
||||||
|
when(mockBook.getDriver()).thenReturn(driver);
|
||||||
|
|
||||||
|
BooksEvent event = mock(BooksEvent.class);
|
||||||
|
when(event.getBook()).thenReturn(mockBook);
|
||||||
|
|
||||||
|
bookManager.getInstalledBooksList().add(mockBook);
|
||||||
|
assertTrue(bookManager.getInstalledBooksList().contains(mockBook));
|
||||||
|
try {
|
||||||
|
bookManager.removeBook(mockBook, secondMockBook);
|
||||||
|
} catch (NullPointerException e) {
|
||||||
|
// Nasty NPE shows up when testing because the index
|
||||||
|
// isn't installed. Suppressing here.
|
||||||
|
}
|
||||||
|
assertFalse(bookManager.getInstalledBooksList().contains(mockBook));
|
||||||
|
verify(driver, times(1)).delete(secondMockBook);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Make sure that when workProgressed is fired, the correct progress event gets triggered
|
||||||
|
* Previously, integer roundoff errors led to some strange results
|
||||||
|
*/
|
||||||
|
@Test
|
||||||
|
public void testWorkProgressedCorrectProgress() {
|
||||||
|
Book mockBook = mock(Book.class);
|
||||||
|
when(mockBook.getInitials()).thenReturn("mockBook");
|
||||||
|
String bookJobName = bookManager.getJobName(mockBook);
|
||||||
|
bookManager.getInProgressJobNames().put(bookJobName, mockBook);
|
||||||
|
|
||||||
|
// Percent to degrees
|
||||||
|
final int workDone = 50; // 50%
|
||||||
|
final int circularProgress = 180;
|
||||||
|
WorkEvent ev = mock(WorkEvent.class);
|
||||||
|
Progress p = mock(Progress.class);
|
||||||
|
|
||||||
|
when(p.getJobID()).thenReturn(bookJobName);
|
||||||
|
when(p.getWork()).thenReturn(workDone);
|
||||||
|
when(ev.getJob()).thenReturn(p);
|
||||||
|
|
||||||
|
final AtomicBoolean progressCorrect = new AtomicBoolean(false);
|
||||||
|
bookManager.getDownloadEvents()
|
||||||
|
.subscribe(new Action1<DLProgressEvent>() {
|
||||||
|
@Override
|
||||||
|
public void call(DLProgressEvent dlProgressEvent) {
|
||||||
|
progressCorrect.set(circularProgress == dlProgressEvent.toCircular());
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
bookManager.workProgressed(ev);
|
||||||
|
|
||||||
|
await().atMost(10, TimeUnit.SECONDS)
|
||||||
|
.untilTrue(progressCorrect);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Modules needed for this test case
|
||||||
|
*/
|
||||||
|
@Module(injects = {BookManager.class,
|
||||||
|
RefreshManager.class,
|
||||||
|
BookManagerTest.class})
|
||||||
|
@SuppressWarnings("unused")
|
||||||
|
public static class BookDownloadManagerTestModules {
|
||||||
|
Injector i;
|
||||||
|
ConnectivityManager manager;
|
||||||
|
DownloadPrefs prefs;
|
||||||
|
|
||||||
|
BookDownloadManagerTestModules(Injector i) {
|
||||||
|
this.i = i;
|
||||||
|
|
||||||
|
// Set reasonable defaults for the manager and preferences, can over-ride if need-be
|
||||||
|
manager = mock(ConnectivityManager.class);
|
||||||
|
NetworkInfo mockNetworkInfo = Mockito.mock(NetworkInfo.class);
|
||||||
|
|
||||||
|
when(manager.getActiveNetworkInfo()).thenReturn(mockNetworkInfo);
|
||||||
|
when(mockNetworkInfo.getType()).thenReturn(ConnectivityManager.TYPE_WIFI);
|
||||||
|
|
||||||
|
prefs = mock(DownloadPrefs.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Books provideBooks() {
|
||||||
|
return Books.installed();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Collection<Installer> provideInstallers() {
|
||||||
|
return new InstallManager().getInstallers().values();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
List<String> excludeList() {
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
|
|
||||||
|
void setConnectivityManager(ConnectivityManager manager) {
|
||||||
|
this.manager = manager;
|
||||||
|
}
|
||||||
|
|
||||||
|
void setPrefs(DownloadPrefs prefs) {
|
||||||
|
this.prefs = prefs;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
RefreshManager refreshManager(Collection<Installer> installers, List<String> excludes) {
|
||||||
|
return new RefreshManager(installers, excludes,
|
||||||
|
prefs, manager);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
PublishSubject<DLProgressEvent> dlProgressEventPublisher() {
|
||||||
|
return PublishSubject.create();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
IndexManager indexManager() {
|
||||||
|
return IndexManagerFactory.getIndexManager();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
MBIndexManager mbIndexManager(IndexManager indexManager) {
|
||||||
|
return new MBIndexManager(indexManager);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
BookManager bookDownloadManager(Books installed, RefreshManager rm,
|
||||||
|
PublishSubject<DLProgressEvent> eventPublisher,
|
||||||
|
MBIndexManager manager) {
|
||||||
|
return new BookManager(installed, rm, eventPublisher, manager);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,165 @@
|
|||||||
|
package org.bspeice.minimalbible.test.activity.downloader.manager;
|
||||||
|
|
||||||
|
import android.net.ConnectivityManager;
|
||||||
|
import android.net.NetworkInfo;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
||||||
|
import org.crosswire.jsword.book.Book;
|
||||||
|
import org.crosswire.jsword.book.install.Installer;
|
||||||
|
import org.junit.Before;
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.mockito.Mockito;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Calendar;
|
||||||
|
import java.util.Collection;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
import dagger.Provides;
|
||||||
|
import rx.functions.Action1;
|
||||||
|
|
||||||
|
import static org.junit.Assert.assertEquals;
|
||||||
|
import static org.junit.Assert.assertFalse;
|
||||||
|
import static org.junit.Assert.assertSame;
|
||||||
|
import static org.junit.Assert.assertTrue;
|
||||||
|
import static org.mockito.Mockito.mock;
|
||||||
|
import static org.mockito.Mockito.verify;
|
||||||
|
import static org.mockito.Mockito.when;
|
||||||
|
|
||||||
|
public class RefreshManagerTest implements Injector {
|
||||||
|
|
||||||
|
final String mockBookName = "MockBook";
|
||||||
|
/**
|
||||||
|
* The object graph that should be given to classes under test. Each test is responsible
|
||||||
|
* for setting their own ObjectGraph.
|
||||||
|
*/
|
||||||
|
ObjectGraph mObjectGraph;
|
||||||
|
@Inject
|
||||||
|
RefreshManager rM;
|
||||||
|
Installer mockInstaller;
|
||||||
|
Book mockBook;
|
||||||
|
|
||||||
|
@Before
|
||||||
|
public void setUp() {
|
||||||
|
// Environment setup
|
||||||
|
mockBook = mock(Book.class);
|
||||||
|
when(mockBook.getName()).thenReturn(mockBookName);
|
||||||
|
|
||||||
|
mockInstaller = mock(Installer.class);
|
||||||
|
List<Book> bookList = new ArrayList<Book>();
|
||||||
|
bookList.add(mockBook);
|
||||||
|
when(mockInstaller.getBooks()).thenReturn(bookList);
|
||||||
|
|
||||||
|
Collection<Installer> mockInstallers = new ArrayList<Installer>();
|
||||||
|
mockInstallers.add(mockInstaller);
|
||||||
|
|
||||||
|
RMTModules modules = new RMTModules(mockInstallers);
|
||||||
|
mObjectGraph = ObjectGraph.create(modules);
|
||||||
|
|
||||||
|
// Now the actual test
|
||||||
|
mObjectGraph.inject(this); // Get the RefreshManager
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void inject(Object o) {
|
||||||
|
mObjectGraph.inject(o);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testGetAvailableModulesFlattened() throws Exception {
|
||||||
|
rM.getFlatModules()
|
||||||
|
.toBlocking()
|
||||||
|
.forEach(new Action1<Book>() {
|
||||||
|
@Override
|
||||||
|
public void call(Book book) {
|
||||||
|
assertEquals(mockBookName, book.getName());
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
verify(mockInstaller).getBooks();
|
||||||
|
verify(mockBook).getName();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testInstallerFromBook() throws Exception {
|
||||||
|
Installer i = rM.installerFromBook(mockBook).toBlocking().first();
|
||||||
|
|
||||||
|
assertSame(mockInstaller, i);
|
||||||
|
verify(mockInstaller).getBooks();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Test the conditions are right for downloading
|
||||||
|
* I'd like to point out that I can test all of this without requiring mocking of
|
||||||
|
* either the preferences or network state. Value Boundaries for the win.
|
||||||
|
*/
|
||||||
|
@Test
|
||||||
|
public void testDoUpdate() {
|
||||||
|
long fourteenDaysAgo = Calendar.getInstance().getTime().getTime() - 1209600;
|
||||||
|
long sixteenDaysAgo = Calendar.getInstance().getTime().getTime() - 1382400;
|
||||||
|
|
||||||
|
assertFalse(rM.doReload(true, fourteenDaysAgo, ConnectivityManager.TYPE_DUMMY));
|
||||||
|
assertFalse(rM.doReload(true, fourteenDaysAgo, ConnectivityManager.TYPE_WIFI));
|
||||||
|
assertFalse(rM.doReload(true, sixteenDaysAgo, ConnectivityManager.TYPE_DUMMY));
|
||||||
|
assertTrue(rM.doReload(true, sixteenDaysAgo, ConnectivityManager.TYPE_WIFI));
|
||||||
|
|
||||||
|
assertFalse(rM.doReload(false, fourteenDaysAgo, ConnectivityManager.TYPE_WIFI));
|
||||||
|
assertFalse(rM.doReload(false, fourteenDaysAgo, ConnectivityManager.TYPE_DUMMY));
|
||||||
|
assertFalse(rM.doReload(false, sixteenDaysAgo, ConnectivityManager.TYPE_WIFI));
|
||||||
|
assertFalse(rM.doReload(false, sixteenDaysAgo, ConnectivityManager.TYPE_DUMMY));
|
||||||
|
}
|
||||||
|
|
||||||
|
@Module(injects = {RefreshManagerTest.class, RefreshManager.class})
|
||||||
|
@SuppressWarnings("unused")
|
||||||
|
class RMTModules {
|
||||||
|
Collection<Installer> installers;
|
||||||
|
ConnectivityManager manager;
|
||||||
|
DownloadPrefs prefs;
|
||||||
|
|
||||||
|
RMTModules(Collection<Installer> installers) {
|
||||||
|
this.installers = installers;
|
||||||
|
|
||||||
|
// Set reasonable defaults for the manager and preferences, can over-ride if need-be
|
||||||
|
manager = mock(ConnectivityManager.class);
|
||||||
|
NetworkInfo mockNetworkInfo = Mockito.mock(NetworkInfo.class);
|
||||||
|
|
||||||
|
when(manager.getActiveNetworkInfo()).thenReturn(mockNetworkInfo);
|
||||||
|
when(mockNetworkInfo.getType()).thenReturn(ConnectivityManager.TYPE_WIFI);
|
||||||
|
|
||||||
|
prefs = mock(DownloadPrefs.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Collection<Installer> provideInstallers() {
|
||||||
|
return this.installers;
|
||||||
|
}
|
||||||
|
|
||||||
|
void setConnectivityManager(ConnectivityManager manager) {
|
||||||
|
this.manager = manager;
|
||||||
|
}
|
||||||
|
|
||||||
|
void setPrefs(DownloadPrefs prefs) {
|
||||||
|
this.prefs = prefs;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
List<String> excludeList() {
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
RefreshManager refreshManager(Collection<Installer> installers, List<String> excludes) {
|
||||||
|
return new RefreshManager(installers, excludes,
|
||||||
|
prefs, manager);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -12,12 +12,12 @@ class SafeValDelegateKotlinTest {
|
|||||||
delegate = SafeValDelegate()
|
delegate = SafeValDelegate()
|
||||||
}
|
}
|
||||||
|
|
||||||
Test(expected = IllegalStateException::class)
|
Test(expected = javaClass<IllegalStateException>())
|
||||||
fun testDelegateNullSafety() {
|
fun testDelegateNullSafety() {
|
||||||
delegate.get(null, PropertyMetadataImpl(""))
|
delegate.get(null, PropertyMetadataImpl(""))
|
||||||
}
|
}
|
||||||
|
|
||||||
Test(expected = IllegalStateException::class)
|
Test(expected = javaClass<IllegalStateException>())
|
||||||
fun testDelegateAssignOnce() {
|
fun testDelegateAssignOnce() {
|
||||||
delegate.set(null, PropertyMetadataImpl(""), "")
|
delegate.set(null, PropertyMetadataImpl(""), "")
|
||||||
delegate.set(null, PropertyMetadataImpl(""), "")
|
delegate.set(null, PropertyMetadataImpl(""), "")
|
@ -1,11 +1,17 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.manager
|
package org.bspeice.minimalbible.activity.downloader.manager
|
||||||
|
|
||||||
|
import com.jayway.awaitility.Awaitility
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs
|
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs
|
||||||
|
import org.crosswire.jsword.book.Book
|
||||||
import org.crosswire.jsword.book.install.Installer
|
import org.crosswire.jsword.book.install.Installer
|
||||||
import org.jetbrains.spek.api.Spek
|
import org.jetbrains.spek.api.Spek
|
||||||
import org.mockito.Matchers.anyLong
|
import org.mockito.Matchers.anyLong
|
||||||
import org.mockito.Mockito.*
|
import org.mockito.Mockito.*
|
||||||
|
import rx.Subscriber
|
||||||
|
import rx.schedulers.Schedulers
|
||||||
import java.util.Calendar
|
import java.util.Calendar
|
||||||
|
import java.util.concurrent.TimeUnit
|
||||||
|
import java.util.concurrent.atomic.AtomicBoolean
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by bspeice on 1/3/15.
|
* Created by bspeice on 1/3/15.
|
||||||
@ -44,8 +50,6 @@ class RefreshManagerSpek() : Spek() {init {
|
|||||||
val rM = buildRefreshmanager(listOf(installer, installer), mockPrefs)
|
val rM = buildRefreshmanager(listOf(installer, installer), mockPrefs)
|
||||||
reset(mockPrefs)
|
reset(mockPrefs)
|
||||||
|
|
||||||
/*
|
|
||||||
TODO: Fix this test not working
|
|
||||||
it("should not update the prefs after the first installer") {
|
it("should not update the prefs after the first installer") {
|
||||||
// The process to do actually validate this is tricky. We have to block
|
// The process to do actually validate this is tricky. We have to block
|
||||||
// the Observable from producing before we can validate the preferences -
|
// the Observable from producing before we can validate the preferences -
|
||||||
@ -78,7 +82,6 @@ class RefreshManagerSpek() : Spek() {init {
|
|||||||
Awaitility.waitAtMost(2, TimeUnit.SECONDS)
|
Awaitility.waitAtMost(2, TimeUnit.SECONDS)
|
||||||
.untilTrue(success)
|
.untilTrue(success)
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
on("creating a new RefreshManager and mock preferences") {
|
on("creating a new RefreshManager and mock preferences") {
|
||||||
@ -86,8 +89,6 @@ class RefreshManagerSpek() : Spek() {init {
|
|||||||
val rM = buildRefreshmanager(listOf(installer, installer), mockPrefs)
|
val rM = buildRefreshmanager(listOf(installer, installer), mockPrefs)
|
||||||
reset(mockPrefs)
|
reset(mockPrefs)
|
||||||
|
|
||||||
/*
|
|
||||||
TODO: Fix this not working
|
|
||||||
it("should update the prefs after completed") {
|
it("should update the prefs after completed") {
|
||||||
val complete = AtomicBoolean(false)
|
val complete = AtomicBoolean(false)
|
||||||
rM.availableModules.observeOn(Schedulers.immediate())
|
rM.availableModules.observeOn(Schedulers.immediate())
|
||||||
@ -101,7 +102,6 @@ class RefreshManagerSpek() : Spek() {init {
|
|||||||
verify(mockPrefs, times(1))
|
verify(mockPrefs, times(1))
|
||||||
.downloadRefreshedOn(anyLong())
|
.downloadRefreshedOn(anyLong())
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
132
app/app.iml
132
app/app.iml
@ -1,132 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<module external.linked.project.id=":app" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" external.system.module.group="MinimalBible" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
|
|
||||||
<component name="FacetManager">
|
|
||||||
<facet type="android-gradle" name="Android-Gradle">
|
|
||||||
<configuration>
|
|
||||||
<option name="GRADLE_PROJECT_PATH" value=":app" />
|
|
||||||
</configuration>
|
|
||||||
</facet>
|
|
||||||
<facet type="android" name="Android">
|
|
||||||
<configuration>
|
|
||||||
<option name="SELECTED_BUILD_VARIANT" value="debug" />
|
|
||||||
<option name="SELECTED_TEST_ARTIFACT" value="_unit_test_" />
|
|
||||||
<option name="ASSEMBLE_TASK_NAME" value="assembleDebug" />
|
|
||||||
<option name="COMPILE_JAVA_TASK_NAME" value="compileDebugSources" />
|
|
||||||
<option name="ASSEMBLE_TEST_TASK_NAME" value="assembleDebugUnitTest" />
|
|
||||||
<option name="COMPILE_JAVA_TEST_TASK_NAME" value="compileDebugUnitTestSources" />
|
|
||||||
<afterSyncTasks>
|
|
||||||
<task>generateDebugSources</task>
|
|
||||||
<task>mockableAndroidJar</task>
|
|
||||||
<task>prepareDebugUnitTestDependencies</task>
|
|
||||||
</afterSyncTasks>
|
|
||||||
<option name="ALLOW_USER_CONFIGURATION" value="false" />
|
|
||||||
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/src/main/AndroidManifest.xml" />
|
|
||||||
<option name="RES_FOLDER_RELATIVE_PATH" value="/src/main/res" />
|
|
||||||
<option name="RES_FOLDERS_RELATIVE_PATH" value="file://$MODULE_DIR$/src/main/res;file://$MODULE_DIR$/src/debug/res" />
|
|
||||||
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/src/main/assets" />
|
|
||||||
</configuration>
|
|
||||||
</facet>
|
|
||||||
</component>
|
|
||||||
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7" inherit-compiler-output="false">
|
|
||||||
<output url="file://$MODULE_DIR$/build/intermediates/classes/debug" />
|
|
||||||
<output-test url="file://$MODULE_DIR$/build/intermediates/classes/test/debug" />
|
|
||||||
<exclude-output />
|
|
||||||
<content url="file://$MODULE_DIR$">
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/apt/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/kapt/debug" isTestSource="false" generated="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/debug" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/aidl" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/java" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/jni" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/rs" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/res" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/resources" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/assets" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/aidl" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/java" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/jni" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/testDebug/rs" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/res" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/assets" type="java-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/aidl" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/kotlin" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/res" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/resources" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/assets" type="java-test-resource" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/aidl" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/kotlin" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/jni" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/test/rs" isTestSource="true" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/assets" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/bundles" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/classes" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/coverage-instrumented-classes" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dependency-cache" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex-cache" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/appcompat-v7/22.0.0/jars" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/cardview-v7/22.0.0/jars" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/recyclerview-v7/22.0.0/jars" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/support-v4/22.0.0/jars" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.orhanobut/logger/1.10/jars" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/jacoco" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/javaResources" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/libs" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/lint" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/manifests" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/ndk" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/pre-dexed" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/proguard" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/res" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/rs" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/symbols" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/outputs" />
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/build/tmp" />
|
|
||||||
</content>
|
|
||||||
<orderEntry type="jdk" jdkName="Android API 22 Platform" jdkType="Android SDK" />
|
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="spek-0.1.165" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="javax.annotation-api-1.2" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="objenesis-2.1" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="cglib-nodep-3.1" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="hamcrest-library-1.3" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="support-annotations-22.0.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="recyclerview-v7-22.0.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="acra-4.6.2" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="rxjava-core-0.20.7" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="mockable-android-22" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="logger-1.10" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="kotlin-stdlib-0.12.213" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="support-v4-22.0.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="systembartint-1.0.4" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="appcompat-v7-22.0.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="hamcrest-core-1.3" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="junit-4.12" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="butterknife-6.1.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="dagger-2.1-SNAPSHOT" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="esperandro-api-2.2.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="cardview-v7-22.0.0" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="rxjava-android-0.20.7" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="commons-lang3-3.4" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="javax.inject-1" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="byte-buddy-0.6.11" level="project" />
|
|
||||||
<orderEntry type="library" exported="" name="kotlin-runtime-0.12.213" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="awaitility-1.6.3" level="project" />
|
|
||||||
<orderEntry type="library" exported="" scope="TEST" name="mockito-core-2.0.23-beta" level="project" />
|
|
||||||
<orderEntry type="module" module-name="jsword-minimalbible" exported="" />
|
|
||||||
</component>
|
|
||||||
</module>
|
|
@ -1,38 +1,32 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath "org.jetbrains.kotlin:kotlin-android-extensions:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-android-extensions:$kotlin_version"
|
||||||
classpath 'com.neenbedankt.gradle.plugins:android-apt:1.4'
|
|
||||||
classpath 'com.github.triplet.gradle:play-publisher:1.0.2'
|
classpath 'com.github.triplet.gradle:play-publisher:1.0.2'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
|
||||||
maven {
|
|
||||||
url "http://repository.jetbrains.com/all"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
apply plugin: 'com.neenbedankt.android-apt'
|
|
||||||
apply plugin: 'kotlin-android'
|
apply plugin: 'kotlin-android'
|
||||||
apply plugin: 'play'
|
apply plugin: 'play'
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 22
|
compileSdkVersion 21
|
||||||
buildToolsVersion '21.1.2'
|
buildToolsVersion '21.1.2'
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId 'org.bspeice.minimalbible'
|
applicationId 'org.bspeice.minimalbible'
|
||||||
minSdkVersion 8
|
minSdkVersion 8
|
||||||
targetSdkVersion 22
|
targetSdkVersion 21
|
||||||
versionName '0.7'
|
|
||||||
versionCode System.getenv("TRAVIS_BUILD_NUMBER")?.toInteger() ?: 0
|
|
||||||
}
|
|
||||||
|
|
||||||
|
def travis_code = System.getenv("TRAVIS_BUILD_NUMBER")
|
||||||
|
if (travis_code)
|
||||||
|
versionCode travis_code.toInteger()
|
||||||
|
else
|
||||||
|
versionCode 0
|
||||||
|
versionName '0.7'
|
||||||
|
}
|
||||||
packagingOptions {
|
packagingOptions {
|
||||||
exclude 'META-INF/LICENSE.txt'
|
exclude 'META-INF/LICENSE.txt'
|
||||||
exclude 'META-INF/NOTICE.txt'
|
exclude 'META-INF/NOTICE.txt'
|
||||||
@ -45,7 +39,6 @@ android {
|
|||||||
exclude 'NOTICE'
|
exclude 'NOTICE'
|
||||||
exclude 'asm-license.txt'
|
exclude 'asm-license.txt'
|
||||||
}
|
}
|
||||||
|
|
||||||
signingConfigs {
|
signingConfigs {
|
||||||
release {
|
release {
|
||||||
storeFile file('src/main/play/MinimalBible.jks')
|
storeFile file('src/main/play/MinimalBible.jks')
|
||||||
@ -54,20 +47,13 @@ android {
|
|||||||
keyPassword System.getenv("KEYSTORE_PASSWORD")
|
keyPassword System.getenv("KEYSTORE_PASSWORD")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
lintOptions {
|
|
||||||
abortOnError false
|
|
||||||
}
|
|
||||||
|
|
||||||
buildTypes {
|
buildTypes {
|
||||||
release {
|
release {
|
||||||
signingConfig signingConfigs.release
|
signingConfig signingConfigs.release
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main.java.srcDirs += 'src/main/kotlin'
|
main.java.srcDirs += 'src/main/kotlin'
|
||||||
test.java.srcDirs += 'src/test/kotlin'
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -79,33 +65,24 @@ play {
|
|||||||
dependencies {
|
dependencies {
|
||||||
compile project(path: ':jsword-minimalbible', configuration: 'buildJSword')
|
compile project(path: ':jsword-minimalbible', configuration: 'buildJSword')
|
||||||
|
|
||||||
compile 'com.google.dagger:dagger:+'
|
compile 'com.squareup.dagger:dagger:+'
|
||||||
apt 'com.google.dagger:dagger-compiler:+'
|
provided 'com.squareup.dagger:dagger-compiler:+'
|
||||||
provided 'javax.annotation:javax.annotation-api:1.2'
|
|
||||||
|
|
||||||
compile 'de.devland.esperandro:esperandro-api:+'
|
// TODO: Figure out why I need to force 2.1.0 and can't just use +
|
||||||
apt 'de.devland.esperandro:esperandro:+'
|
compile 'de.devland.esperandro:esperandro-api:2.1.0'
|
||||||
|
provided 'de.devland.esperandro:esperandro:2.1.0'
|
||||||
|
|
||||||
compile 'com.jakewharton:butterknife:6.1.0'
|
compile 'com.jakewharton:butterknife:+'
|
||||||
compile 'com.readystatesoftware.systembartint:systembartint:+'
|
compile 'com.readystatesoftware.systembartint:systembartint:+'
|
||||||
compile 'com.netflix.rxjava:rxjava-android:+'
|
compile 'com.netflix.rxjava:rxjava-android:+'
|
||||||
compile 'com.android.support:appcompat-v7:+'
|
compile 'com.android.support:appcompat-v7:21.+'
|
||||||
compile 'com.android.support:recyclerview-v7:+'
|
compile 'com.android.support:recyclerview-v7:21.+'
|
||||||
compile 'com.android.support:cardview-v7:+'
|
|
||||||
compile 'org.apache.commons:commons-lang3:+'
|
compile 'org.apache.commons:commons-lang3:+'
|
||||||
compile 'com.orhanobut:logger:+'
|
|
||||||
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
||||||
|
|
||||||
// Instrumentation Test dependencies
|
|
||||||
androidTestCompile 'com.jayway.awaitility:awaitility:+'
|
androidTestCompile 'com.jayway.awaitility:awaitility:+'
|
||||||
androidTestCompile 'org.mockito:mockito-core:+'
|
androidTestCompile 'org.mockito:mockito-core:+'
|
||||||
|
|
||||||
// Unit Test dependencies
|
|
||||||
testCompile 'junit:junit:4.12'
|
|
||||||
testCompile 'com.jayway.awaitility:awaitility:+'
|
|
||||||
testCompile 'org.mockito:mockito-core:+'
|
|
||||||
testCompile 'org.jetbrains.spek:spek:+'
|
|
||||||
|
|
||||||
// Email debug reports if I crash...
|
// Email debug reports if I crash...
|
||||||
debugCompile('ch.acra:acra:+') {
|
debugCompile('ch.acra:acra:+') {
|
||||||
exclude module: 'json'
|
exclude module: 'json'
|
||||||
|
@ -1,8 +1,5 @@
|
|||||||
package org.bspeice.minimalbible;
|
package org.bspeice.minimalbible;
|
||||||
|
|
||||||
import com.orhanobut.logger.LogLevel;
|
|
||||||
import com.orhanobut.logger.Logger;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a MinimalBible application that we can extend from the main release
|
* Create a MinimalBible application that we can extend from the main release
|
||||||
* Currently it's not doing much, but would allow for shenanigans during testing in the future
|
* Currently it's not doing much, but would allow for shenanigans during testing in the future
|
||||||
@ -13,14 +10,11 @@ import com.orhanobut.logger.Logger;
|
|||||||
mode = ReportingInteractionMode.SILENT
|
mode = ReportingInteractionMode.SILENT
|
||||||
)
|
)
|
||||||
*/
|
*/
|
||||||
public class MinimalBibleDebug extends MinimalBible {
|
public class MinimalBibleDebug extends MinimalBible implements Injector {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate() {
|
public void onCreate() {
|
||||||
super.onCreate();
|
super.onCreate();
|
||||||
Logger.init("MinimalBible")
|
|
||||||
.setLogLevel(LogLevel.FULL);
|
|
||||||
Logger.d("Beginning application run...");
|
|
||||||
// ACRA.init(this);
|
// ACRA.init(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -2,37 +2,44 @@ package org.bspeice.minimalbible;
|
|||||||
|
|
||||||
import android.app.Application;
|
import android.app.Application;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
|
import android.util.Log;
|
||||||
import com.orhanobut.logger.LogLevel;
|
|
||||||
import com.orhanobut.logger.Logger;
|
|
||||||
|
|
||||||
import org.crosswire.jsword.book.sword.SwordBookPath;
|
import org.crosswire.jsword.book.sword.SwordBookPath;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set up the application!
|
* Set up the application!
|
||||||
*/
|
*/
|
||||||
public class MinimalBible extends Application {
|
public class MinimalBible extends Application implements Injector {
|
||||||
private static Context mContext;
|
private String TAG = "MinimalBible";
|
||||||
|
private ObjectGraph mObjectGraph;
|
||||||
|
|
||||||
public static MinimalBible get(Context ctx) {
|
public static MinimalBible get(Context ctx) {
|
||||||
return (MinimalBible) ctx.getApplicationContext();
|
return (MinimalBible) ctx.getApplicationContext();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Context getAppContext() {
|
|
||||||
Logger.v("Statically accessing context, please refactor that.");
|
|
||||||
return mContext;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate() {
|
public void onCreate() {
|
||||||
super.onCreate();
|
super.onCreate();
|
||||||
mContext = this;
|
buildObjGraph();
|
||||||
Logger.init().setLogLevel(LogLevel.NONE);
|
|
||||||
setJswordHome();
|
setJswordHome();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void buildObjGraph() {
|
||||||
|
mObjectGraph = ObjectGraph.create(Modules.list(this));
|
||||||
|
}
|
||||||
|
|
||||||
|
public void inject(Object o) {
|
||||||
|
mObjectGraph.inject(o);
|
||||||
|
}
|
||||||
|
|
||||||
|
public ObjectGraph plus(Object... modules) {
|
||||||
|
return mObjectGraph.plus(modules);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Notify jSword that it needs to store files in the Android internal directory
|
* Notify jSword that it needs to store files in the Android internal directory
|
||||||
* NOTE: Android will uninstall these files if you uninstall MinimalBible.
|
* NOTE: Android will uninstall these files if you uninstall MinimalBible.
|
||||||
@ -42,10 +49,10 @@ public class MinimalBible extends Application {
|
|||||||
// We need to set the download directory for jSword to stick with
|
// We need to set the download directory for jSword to stick with
|
||||||
// Android.
|
// Android.
|
||||||
String home = this.getFilesDir().toString();
|
String home = this.getFilesDir().toString();
|
||||||
Logger.d("Setting jsword.home to: " + home);
|
Log.d(TAG, "Setting jsword.home to: " + home);
|
||||||
System.setProperty("jsword.home", home);
|
System.setProperty("jsword.home", home);
|
||||||
System.setProperty("sword.home", home);
|
System.setProperty("sword.home", home);
|
||||||
SwordBookPath.setDownloadDir(new File(home));
|
SwordBookPath.setDownloadDir(new File(home));
|
||||||
Logger.d("Sword download path: " + SwordBookPath.getSwordDownloadDir());
|
Log.d(TAG, "Sword download path: " + SwordBookPath.getSwordDownloadDir());
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -16,6 +16,9 @@ import java.util.List;
|
|||||||
import java.util.NoSuchElementException;
|
import java.util.NoSuchElementException;
|
||||||
import java.util.concurrent.atomic.AtomicReference;
|
import java.util.concurrent.atomic.AtomicReference;
|
||||||
|
|
||||||
|
import javax.inject.Named;
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
import dagger.Module;
|
import dagger.Module;
|
||||||
import dagger.Provides;
|
import dagger.Provides;
|
||||||
import de.devland.esperandro.Esperandro;
|
import de.devland.esperandro.Esperandro;
|
||||||
@ -26,7 +29,8 @@ import rx.functions.Func1;
|
|||||||
/**
|
/**
|
||||||
* Entry point for the default modules used by MinimalBible
|
* Entry point for the default modules used by MinimalBible
|
||||||
*/
|
*/
|
||||||
@Module
|
@SuppressWarnings("unused")
|
||||||
|
@Module(library = true)
|
||||||
public class MinimalBibleModules {
|
public class MinimalBibleModules {
|
||||||
MinimalBible app;
|
MinimalBible app;
|
||||||
|
|
||||||
@ -35,6 +39,7 @@ public class MinimalBibleModules {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
Application provideApplication() {
|
Application provideApplication() {
|
||||||
return app;
|
return app;
|
||||||
}
|
}
|
||||||
@ -46,6 +51,7 @@ public class MinimalBibleModules {
|
|||||||
* @return the list of books (by name) to ignore
|
* @return the list of books (by name) to ignore
|
||||||
*/
|
*/
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
List<String> invalidBooks() {
|
List<String> invalidBooks() {
|
||||||
List<String> list = new ArrayList<>();
|
List<String> list = new ArrayList<>();
|
||||||
list.add("ABU"); // Missing content
|
list.add("ABU"); // Missing content
|
||||||
@ -55,15 +61,30 @@ public class MinimalBibleModules {
|
|||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//TODO: Move this to a true async
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Provide a raw reference to the books installed. Please don't use this, chances are
|
||||||
|
* you should go through List<Book> since it excludes the invalid books.
|
||||||
|
*
|
||||||
|
* @return The raw reference to JSword Books class
|
||||||
|
*/
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Books provideInstalledBooks() {
|
||||||
|
return Books.installed();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use this to get the list of books installed, as filtered by what should be excluded
|
* Use this to get the list of books installed, as filtered by what should be excluded
|
||||||
*
|
*
|
||||||
|
* @param b The raw Books instance to get the installed list from
|
||||||
* @param invalidBooks The books to exclude from usage
|
* @param invalidBooks The books to exclude from usage
|
||||||
* @return The books available for using
|
* @return The books available for using
|
||||||
*/
|
*/
|
||||||
@Provides
|
@Provides
|
||||||
List<Book> provideInstalledBooks(final List<String> invalidBooks) {
|
List<Book> provideInstalledBooks(Books b, final List<String> invalidBooks) {
|
||||||
List<Book> rawBooks = Books.installed().getBooks();
|
List<Book> rawBooks = b.getBooks();
|
||||||
return Observable.from(rawBooks)
|
return Observable.from(rawBooks)
|
||||||
.filter(new Func1<Book, Boolean>() {
|
.filter(new Func1<Book, Boolean>() {
|
||||||
@Override
|
@Override
|
||||||
@ -75,18 +96,14 @@ public class MinimalBibleModules {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
BibleViewerPreferences providePrefs() {
|
BibleViewerPreferences providePrefs() {
|
||||||
return Esperandro.getPreferences(BibleViewerPreferences.class, app);
|
return Esperandro.getPreferences(BibleViewerPreferences.class, app);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* TODO: Assume a book exists, throw an error if nothing available
|
|
||||||
*
|
|
||||||
* @param bookManager
|
|
||||||
* @param prefs
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
@Named("MainBook")
|
||||||
Book provideMainBook(BookManager bookManager, final BibleViewerPreferences prefs) {
|
Book provideMainBook(BookManager bookManager, final BibleViewerPreferences prefs) {
|
||||||
final AtomicReference<Book> mBook = new AtomicReference<>(null);
|
final AtomicReference<Book> mBook = new AtomicReference<>(null);
|
||||||
bookManager.getInstalledBooks()
|
bookManager.getInstalledBooks()
|
||||||
@ -134,11 +151,13 @@ public class MinimalBibleModules {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
BookManager bookManager(List<String> exclude) {
|
BookManager bookManager(List<String> exclude) {
|
||||||
return new BookManager(exclude);
|
return new BookManager(exclude);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
IndexManager indexManager() {
|
IndexManager indexManager() {
|
||||||
return IndexManagerFactory.getIndexManager();
|
return IndexManagerFactory.getIndexManager();
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,8 @@ import android.support.v4.app.Fragment;
|
|||||||
import android.support.v4.app.FragmentActivity;
|
import android.support.v4.app.FragmentActivity;
|
||||||
import android.support.v4.app.FragmentManager;
|
import android.support.v4.app.FragmentManager;
|
||||||
|
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holding location for activity object graphs.
|
* Holding location for activity object graphs.
|
||||||
* This technique could be extended to other things, but honestly,
|
* This technique could be extended to other things, but honestly,
|
||||||
@ -12,10 +14,10 @@ import android.support.v4.app.FragmentManager;
|
|||||||
* an ObjectGraph anyway.
|
* an ObjectGraph anyway.
|
||||||
* This works because getSupportFragmentManager() is scoped to each activity.
|
* This works because getSupportFragmentManager() is scoped to each activity.
|
||||||
*/
|
*/
|
||||||
public class OGHolder<T> extends Fragment {
|
public class OGHolder extends Fragment {
|
||||||
private final static String TAG = "OGHolder";
|
private final static String TAG = "OGHolder";
|
||||||
|
|
||||||
private T mComponent;
|
private ObjectGraph mObjectGraph;
|
||||||
|
|
||||||
public static OGHolder get(FragmentActivity activity) {
|
public static OGHolder get(FragmentActivity activity) {
|
||||||
FragmentManager manager = activity.getSupportFragmentManager();
|
FragmentManager manager = activity.getSupportFragmentManager();
|
||||||
@ -33,11 +35,11 @@ public class OGHolder<T> extends Fragment {
|
|||||||
setRetainInstance(true);
|
setRetainInstance(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
public T getmComponent() {
|
public void persistGraph(ObjectGraph graph) {
|
||||||
return mComponent;
|
mObjectGraph = graph;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setmComponent(T mComponent) {
|
public ObjectGraph fetchGraph() {
|
||||||
this.mComponent = mComponent;
|
return mObjectGraph;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -64,11 +64,6 @@ public class BookItemHolder {
|
|||||||
public void bindHolder() {
|
public void bindHolder() {
|
||||||
acronym.setText(b.getInitials());
|
acronym.setText(b.getInitials());
|
||||||
itemName.setText(b.getName());
|
itemName.setText(b.getName());
|
||||||
// TODO: I shouldn't have to check for this condition.
|
|
||||||
if (bookManager == null) {
|
|
||||||
displayInstalled();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
DLProgressEvent dlProgressEvent = bookManager.getDownloadProgress(b);
|
DLProgressEvent dlProgressEvent = bookManager.getDownloadProgress(b);
|
||||||
if (dlProgressEvent != null) {
|
if (dlProgressEvent != null) {
|
||||||
displayProgress(dlProgressEvent);
|
displayProgress(dlProgressEvent);
|
||||||
|
@ -13,11 +13,9 @@ import android.widget.ListView;
|
|||||||
import android.widget.Spinner;
|
import android.widget.Spinner;
|
||||||
import android.widget.Toast;
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
import org.bspeice.minimalbible.R;
|
import org.bspeice.minimalbible.R;
|
||||||
import org.bspeice.minimalbible.activity.BaseFragment;
|
import org.bspeice.minimalbible.activity.BaseFragment;
|
||||||
import org.bspeice.minimalbible.activity.downloader.injection.ActivityContextModule;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.injection.BookListFragmentComponent;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.injection.DaggerBookListFragmentComponent;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.LocaleManager;
|
import org.bspeice.minimalbible.activity.downloader.manager.LocaleManager;
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
||||||
import org.crosswire.common.util.Language;
|
import org.crosswire.common.util.Language;
|
||||||
@ -71,12 +69,8 @@ public class BookListFragment extends BaseFragment {
|
|||||||
* Returns a new instance of this fragment for the given section number.
|
* Returns a new instance of this fragment for the given section number.
|
||||||
* TODO: Switch to AutoFactory/@Provides rather than inline creation.
|
* TODO: Switch to AutoFactory/@Provides rather than inline creation.
|
||||||
*/
|
*/
|
||||||
public static BookListFragment newInstance(BookCategory c, DownloadActivity activity) {
|
public static BookListFragment newInstance(BookCategory c) {
|
||||||
BookListFragment fragment = new BookListFragment();
|
BookListFragment fragment = new BookListFragment();
|
||||||
DaggerBookListFragmentComponent.builder()
|
|
||||||
.activityContextModule(new ActivityContextModule(activity))
|
|
||||||
.build()
|
|
||||||
.injectBookListFragment(fragment);
|
|
||||||
Bundle args = new Bundle();
|
Bundle args = new Bundle();
|
||||||
args.putString(ARG_BOOK_CATEGORY, c.toString());
|
args.putString(ARG_BOOK_CATEGORY, c.toString());
|
||||||
fragment.setArguments(args);
|
fragment.setArguments(args);
|
||||||
@ -86,10 +80,7 @@ public class BookListFragment extends BaseFragment {
|
|||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle state) {
|
public void onCreate(Bundle state) {
|
||||||
super.onCreate(state);
|
super.onCreate(state);
|
||||||
BookListFragmentComponent component = DaggerBookListFragmentComponent.builder()
|
((Injector)getActivity()).inject(this);
|
||||||
.activityContextModule(new ActivityContextModule((DownloadActivity) getActivity()))
|
|
||||||
.build();
|
|
||||||
component.injectBookListFragment(this);
|
|
||||||
|
|
||||||
bookCategory = BookCategory.fromString(getArguments().getString(ARG_BOOK_CATEGORY));
|
bookCategory = BookCategory.fromString(getArguments().getString(ARG_BOOK_CATEGORY));
|
||||||
availableLanguages = localeManager.sortedLanguagesForCategory(bookCategory);
|
availableLanguages = localeManager.sortedLanguagesForCategory(bookCategory);
|
||||||
|
@ -15,10 +15,10 @@ import android.widget.LinearLayout;
|
|||||||
import android.widget.ListView;
|
import android.widget.ListView;
|
||||||
|
|
||||||
import org.bspeice.minimalbible.Injector;
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.MinimalBible;
|
||||||
|
import org.bspeice.minimalbible.OGHolder;
|
||||||
import org.bspeice.minimalbible.R;
|
import org.bspeice.minimalbible.R;
|
||||||
import org.bspeice.minimalbible.activity.BaseActivity;
|
import org.bspeice.minimalbible.activity.BaseActivity;
|
||||||
import org.bspeice.minimalbible.activity.downloader.injection.DaggerDownloadActivityComponent;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.injection.DownloadActivityComponent;
|
|
||||||
import org.bspeice.minimalbible.activity.settings.MinimalBibleSettings;
|
import org.bspeice.minimalbible.activity.settings.MinimalBibleSettings;
|
||||||
import org.crosswire.jsword.book.BookCategory;
|
import org.crosswire.jsword.book.BookCategory;
|
||||||
import org.jetbrains.annotations.NotNull;
|
import org.jetbrains.annotations.NotNull;
|
||||||
@ -26,15 +26,18 @@ import org.jetbrains.annotations.NotNull;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
|
import javax.inject.Named;
|
||||||
|
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
import butterknife.InjectView;
|
import butterknife.InjectView;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
|
||||||
public class DownloadActivity extends BaseActivity implements
|
public class DownloadActivity extends BaseActivity implements
|
||||||
Injector,
|
Injector,
|
||||||
AdapterView.OnItemClickListener {
|
AdapterView.OnItemClickListener {
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
|
@Named("ValidCategories")
|
||||||
List<BookCategory> validCategories;
|
List<BookCategory> validCategories;
|
||||||
|
|
||||||
@InjectView(R.id.navigation_drawer)
|
@InjectView(R.id.navigation_drawer)
|
||||||
@ -49,10 +52,30 @@ public class DownloadActivity extends BaseActivity implements
|
|||||||
@InjectView(R.id.drawer_layout)
|
@InjectView(R.id.drawer_layout)
|
||||||
DrawerLayout drawerLayout;
|
DrawerLayout drawerLayout;
|
||||||
|
|
||||||
|
private ObjectGraph daObjectGraph;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build a scoped object graph for anything used by the DownloadActivity
|
||||||
|
*/
|
||||||
|
private void buildObjGraph() {
|
||||||
|
if (daObjectGraph == null) {
|
||||||
|
OGHolder holder = OGHolder.get(this);
|
||||||
|
ObjectGraph holderGraph = holder.fetchGraph();
|
||||||
|
if (holderGraph == null) {
|
||||||
|
daObjectGraph = MinimalBible.get(this)
|
||||||
|
.plus(new DownloadActivityModules(this));
|
||||||
|
holder.persistGraph(daObjectGraph);
|
||||||
|
} else {
|
||||||
|
daObjectGraph = holderGraph;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
daObjectGraph.inject(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
public void inject(Object o) {
|
public void inject(Object o) {
|
||||||
// TODO: Cache the component
|
buildObjGraph();
|
||||||
DownloadActivityComponent component = DaggerDownloadActivityComponent.create();
|
daObjectGraph.inject(o);
|
||||||
component.injectDownloadActivity(this);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -115,7 +138,7 @@ public class DownloadActivity extends BaseActivity implements
|
|||||||
fragmentManager
|
fragmentManager
|
||||||
.beginTransaction()
|
.beginTransaction()
|
||||||
.replace(R.id.content,
|
.replace(R.id.content,
|
||||||
BookListFragment.newInstance(validCategories.get(position), this))
|
BookListFragment.newInstance(validCategories.get(position)))
|
||||||
.commit();
|
.commit();
|
||||||
|
|
||||||
drawerLayout.closeDrawers();
|
drawerLayout.closeDrawers();
|
||||||
|
@ -0,0 +1,130 @@
|
|||||||
|
package org.bspeice.minimalbible.activity.downloader;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.net.ConnectivityManager;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.MinimalBibleModules;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.BookManager;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.DLProgressEvent;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.LocaleManager;
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
||||||
|
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
||||||
|
import org.crosswire.jsword.book.BookCategory;
|
||||||
|
import org.crosswire.jsword.book.Books;
|
||||||
|
import org.crosswire.jsword.book.install.InstallManager;
|
||||||
|
import org.crosswire.jsword.book.install.Installer;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collection;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Named;
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.Provides;
|
||||||
|
import de.devland.esperandro.Esperandro;
|
||||||
|
import rx.subjects.PublishSubject;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Module mappings for the classes under the Download Activity
|
||||||
|
*/
|
||||||
|
@Module(
|
||||||
|
injects = {
|
||||||
|
BookListFragment.class,
|
||||||
|
BookItemHolder.class,
|
||||||
|
BookManager.class,
|
||||||
|
RefreshManager.class,
|
||||||
|
DownloadActivity.class
|
||||||
|
},
|
||||||
|
addsTo = MinimalBibleModules.class,
|
||||||
|
library = true
|
||||||
|
)
|
||||||
|
@SuppressWarnings("unused")
|
||||||
|
public class DownloadActivityModules {
|
||||||
|
DownloadActivity activity;
|
||||||
|
|
||||||
|
DownloadActivityModules(DownloadActivity activity) {
|
||||||
|
this.activity = activity;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
DownloadPrefs provideDownloadPrefs() {
|
||||||
|
return Esperandro.getPreferences(DownloadPrefs.class, activity);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
DownloadActivity provideDownloadActivity() {
|
||||||
|
return activity;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Injector provideActivityInjector() {
|
||||||
|
return activity;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Provide the context for the DownloadActivity. We name it so that we don't have to
|
||||||
|
* \@Provides a specific class, but can keep track of what exactly we mean by "Context"
|
||||||
|
*
|
||||||
|
* @return The DownloadActivity Context
|
||||||
|
*/
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
@Named("DownloadActivityContext")
|
||||||
|
Context provideActivityContext() {
|
||||||
|
return activity;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
PublishSubject<DLProgressEvent> dlProgressEventPublisher() {
|
||||||
|
return PublishSubject.create();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
BookManager provideBookDownloadManager(Books installedBooks, RefreshManager rm,
|
||||||
|
PublishSubject<DLProgressEvent> progressEvents,
|
||||||
|
MBIndexManager mbIndexManager) {
|
||||||
|
return new BookManager(installedBooks, rm, progressEvents, mbIndexManager);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
@Named("ValidCategories")
|
||||||
|
List<BookCategory> provideValidCategories() {
|
||||||
|
return new ArrayList<BookCategory>() {{
|
||||||
|
add(BookCategory.BIBLE);
|
||||||
|
add(BookCategory.COMMENTARY);
|
||||||
|
add(BookCategory.DICTIONARY);
|
||||||
|
add(BookCategory.MAPS);
|
||||||
|
}};
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
Collection<Installer> provideInstallers() {
|
||||||
|
return new InstallManager().getInstallers().values();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
RefreshManager provideRefreshManager(Collection<Installer> installers, List<String> exclude,
|
||||||
|
DownloadPrefs prefs,
|
||||||
|
@Named("DownloadActivityContext") Context context) {
|
||||||
|
return new RefreshManager(installers, exclude, prefs,
|
||||||
|
(ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE));
|
||||||
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
LocaleManager provideLocaleManager(RefreshManager refreshManager) {
|
||||||
|
return new LocaleManager(refreshManager);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -1,21 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.injection;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadActivity;
|
|
||||||
|
|
||||||
import dagger.Module;
|
|
||||||
import dagger.Provides;
|
|
||||||
|
|
||||||
@Module
|
|
||||||
public class ActivityContextModule {
|
|
||||||
|
|
||||||
DownloadActivity activity;
|
|
||||||
|
|
||||||
public ActivityContextModule(DownloadActivity activity) {
|
|
||||||
this.activity = activity;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
DownloadActivity downloadActivity() {
|
|
||||||
return activity;
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,13 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.injection;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.BookListFragment;
|
|
||||||
import org.bspeice.minimalbible.common.injection.InvalidBookModule;
|
|
||||||
|
|
||||||
import dagger.Component;
|
|
||||||
|
|
||||||
@Component(modules = {ActivityContextModule.class, DownloadManagerModule.class,
|
|
||||||
InvalidBookModule.class})
|
|
||||||
public interface BookListFragmentComponent {
|
|
||||||
|
|
||||||
BookListFragment injectBookListFragment(BookListFragment fragment);
|
|
||||||
}
|
|
@ -1,11 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.injection;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadActivity;
|
|
||||||
|
|
||||||
import dagger.Component;
|
|
||||||
|
|
||||||
@Component(modules = ValidCategoryModule.class)
|
|
||||||
public interface DownloadActivityComponent {
|
|
||||||
|
|
||||||
public DownloadActivity injectDownloadActivity(DownloadActivity activity);
|
|
||||||
}
|
|
@ -1,62 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.injection;
|
|
||||||
|
|
||||||
import android.content.Context;
|
|
||||||
import android.net.ConnectivityManager;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadActivity;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.BookManager;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.DLProgressEvent;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.LocaleManager;
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.manager.RefreshManager;
|
|
||||||
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
|
||||||
import org.crosswire.jsword.book.Books;
|
|
||||||
import org.crosswire.jsword.book.install.InstallManager;
|
|
||||||
import org.crosswire.jsword.book.install.Installer;
|
|
||||||
|
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import dagger.Module;
|
|
||||||
import dagger.Provides;
|
|
||||||
import de.devland.esperandro.Esperandro;
|
|
||||||
import rx.subjects.PublishSubject;
|
|
||||||
|
|
||||||
@Module
|
|
||||||
public class DownloadManagerModule {
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
DownloadPrefs provideDownloadPrefs(DownloadActivity activity) {
|
|
||||||
return Esperandro.getPreferences(DownloadPrefs.class, activity);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
PublishSubject<DLProgressEvent> dlProgressEventPublisher() {
|
|
||||||
return PublishSubject.create();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
BookManager provideBookDownloadManager(Books installedBooks, RefreshManager rm,
|
|
||||||
PublishSubject<DLProgressEvent> progressEvents,
|
|
||||||
MBIndexManager mbIndexManager) {
|
|
||||||
return new BookManager(installedBooks, rm, progressEvents, mbIndexManager);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
Collection<Installer> provideInstallers() {
|
|
||||||
return new InstallManager().getInstallers().values();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
RefreshManager provideRefreshManager(Collection<Installer> installers, List<String> exclude,
|
|
||||||
DownloadPrefs prefs,
|
|
||||||
DownloadActivity activity) {
|
|
||||||
return new RefreshManager(installers, exclude, prefs,
|
|
||||||
(ConnectivityManager) activity.getSystemService(Context.CONNECTIVITY_SERVICE));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
LocaleManager provideLocaleManager(RefreshManager refreshManager) {
|
|
||||||
return new LocaleManager(refreshManager);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,23 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.injection;
|
|
||||||
|
|
||||||
import org.crosswire.jsword.book.BookCategory;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import dagger.Module;
|
|
||||||
import dagger.Provides;
|
|
||||||
|
|
||||||
@Module
|
|
||||||
public class ValidCategoryModule {
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
List<BookCategory> provideValidCategories() {
|
|
||||||
return new ArrayList<BookCategory>() {{
|
|
||||||
add(BookCategory.BIBLE);
|
|
||||||
add(BookCategory.COMMENTARY);
|
|
||||||
add(BookCategory.DICTIONARY);
|
|
||||||
add(BookCategory.MAPS);
|
|
||||||
}};
|
|
||||||
}
|
|
||||||
}
|
|
@ -5,9 +5,11 @@ import android.content.Intent;
|
|||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.v7.widget.Toolbar;
|
import android.support.v7.widget.Toolbar;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.MinimalBible;
|
||||||
|
import org.bspeice.minimalbible.OGHolder;
|
||||||
import org.bspeice.minimalbible.R;
|
import org.bspeice.minimalbible.R;
|
||||||
import org.bspeice.minimalbible.activity.BaseActivity;
|
import org.bspeice.minimalbible.activity.BaseActivity;
|
||||||
import org.bspeice.minimalbible.common.injection.MainBookModule;
|
|
||||||
import org.crosswire.jsword.passage.Verse;
|
import org.crosswire.jsword.passage.Verse;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -16,9 +18,11 @@ import javax.inject.Inject;
|
|||||||
|
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
import butterknife.InjectView;
|
import butterknife.InjectView;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
|
||||||
|
|
||||||
public class BasicSearch extends BaseActivity {
|
public class BasicSearch extends BaseActivity
|
||||||
|
implements Injector {
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
SearchProvider searchProvider;
|
SearchProvider searchProvider;
|
||||||
@ -29,13 +33,25 @@ public class BasicSearch extends BaseActivity {
|
|||||||
@InjectView(R.id.toolbar)
|
@InjectView(R.id.toolbar)
|
||||||
Toolbar toolbar;
|
Toolbar toolbar;
|
||||||
|
|
||||||
|
private ObjectGraph searchObjGraph;
|
||||||
|
|
||||||
public void inject() {
|
private void buildObjGraph() {
|
||||||
// TODO: Cache the component
|
if (searchObjGraph == null) {
|
||||||
BasicSearchComponent component = DaggerBasicSearchComponent.builder()
|
OGHolder holder = OGHolder.get(this);
|
||||||
.mainBookModule(new MainBookModule(this))
|
searchObjGraph = holder.fetchGraph();
|
||||||
.build();
|
if (searchObjGraph == null) {
|
||||||
component.injectBasicSearch(this);
|
searchObjGraph = MinimalBible.get(this)
|
||||||
|
.plus(new SearchModules());
|
||||||
|
holder.persistGraph(searchObjGraph);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
searchObjGraph.inject(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void inject(Object o) {
|
||||||
|
buildObjGraph();
|
||||||
|
searchObjGraph.inject(o);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -43,7 +59,7 @@ public class BasicSearch extends BaseActivity {
|
|||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_search_results);
|
setContentView(R.layout.activity_search_results);
|
||||||
|
|
||||||
inject();
|
inject(this);
|
||||||
ButterKnife.inject(this);
|
ButterKnife.inject(this);
|
||||||
|
|
||||||
setSupportActionBar(toolbar);
|
setSupportActionBar(toolbar);
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.search;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.common.injection.InvalidBookModule;
|
|
||||||
import org.bspeice.minimalbible.common.injection.MainBookModule;
|
|
||||||
|
|
||||||
import dagger.Component;
|
|
||||||
|
|
||||||
@Component(modules = {SearchModules.class, MainBookModule.class, InvalidBookModule.class})
|
|
||||||
public interface BasicSearchComponent {
|
|
||||||
|
|
||||||
BasicSearch injectBasicSearch(BasicSearch basicSearch);
|
|
||||||
}
|
|
@ -1,19 +1,25 @@
|
|||||||
package org.bspeice.minimalbible.activity.search;
|
package org.bspeice.minimalbible.activity.search;
|
||||||
|
|
||||||
import android.support.annotation.Nullable;
|
import org.bspeice.minimalbible.MinimalBibleModules;
|
||||||
|
|
||||||
import org.crosswire.jsword.book.Book;
|
import org.crosswire.jsword.book.Book;
|
||||||
import org.crosswire.jsword.index.IndexManager;
|
import org.crosswire.jsword.index.IndexManager;
|
||||||
|
|
||||||
|
import javax.inject.Named;
|
||||||
|
|
||||||
import dagger.Module;
|
import dagger.Module;
|
||||||
import dagger.Provides;
|
import dagger.Provides;
|
||||||
|
|
||||||
@Module
|
@Module(
|
||||||
|
injects = BasicSearch.class,
|
||||||
|
addsTo = MinimalBibleModules.class
|
||||||
|
)
|
||||||
public class SearchModules {
|
public class SearchModules {
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
SearchProvider searchProvider(@Nullable Book book,
|
SearchProvider searchProvider(@Named("MainBook") Book book,
|
||||||
IndexManager indexManager) {
|
IndexManager indexManager) {
|
||||||
return new SearchProvider(indexManager, book);
|
return new SearchProvider(indexManager, book);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -5,14 +5,24 @@ import android.preference.PreferenceActivity;
|
|||||||
import android.support.v7.widget.Toolbar;
|
import android.support.v7.widget.Toolbar;
|
||||||
import android.widget.LinearLayout;
|
import android.widget.LinearLayout;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.MinimalBible;
|
||||||
|
import org.bspeice.minimalbible.MinimalBibleModules;
|
||||||
import org.bspeice.minimalbible.R;
|
import org.bspeice.minimalbible.R;
|
||||||
import org.bspeice.minimalbible.activity.BaseActivity;
|
import org.bspeice.minimalbible.activity.BaseActivity;
|
||||||
|
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
import butterknife.InjectView;
|
import butterknife.InjectView;
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
|
|
||||||
public class MinimalBibleSettings extends PreferenceActivity {
|
/**
|
||||||
|
* Created by bspeice on 12/29/14.
|
||||||
|
*/
|
||||||
|
public class MinimalBibleSettings extends PreferenceActivity
|
||||||
|
implements Injector {
|
||||||
|
|
||||||
|
ObjectGraph settingsGraph;
|
||||||
@InjectView(R.id.toolbar)
|
@InjectView(R.id.toolbar)
|
||||||
Toolbar toolbar;
|
Toolbar toolbar;
|
||||||
@InjectView(R.id.container)
|
@InjectView(R.id.container)
|
||||||
@ -31,4 +41,24 @@ public class MinimalBibleSettings extends PreferenceActivity {
|
|||||||
toolbar.setTitle(R.string.action_settings);
|
toolbar.setTitle(R.string.action_settings);
|
||||||
BaseActivity.setupInsets(this, root);
|
BaseActivity.setupInsets(this, root);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private ObjectGraph buildObjGraph() {
|
||||||
|
MinimalBible app = (MinimalBible) getApplicationContext();
|
||||||
|
|
||||||
|
return app.plus(new SettingsModule());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void inject(Object o) {
|
||||||
|
if (settingsGraph == null) {
|
||||||
|
settingsGraph = buildObjGraph();
|
||||||
|
}
|
||||||
|
settingsGraph.inject(o);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Module(injects = AvailableBookPreference.class,
|
||||||
|
addsTo = MinimalBibleModules.class)
|
||||||
|
class SettingsModule {
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -5,7 +5,6 @@ import android.content.ComponentName;
|
|||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.annotation.Nullable;
|
|
||||||
import android.support.v4.view.MenuItemCompat;
|
import android.support.v4.view.MenuItemCompat;
|
||||||
import android.support.v4.widget.DrawerLayout;
|
import android.support.v4.widget.DrawerLayout;
|
||||||
import android.support.v7.app.ActionBarDrawerToggle;
|
import android.support.v7.app.ActionBarDrawerToggle;
|
||||||
@ -14,31 +13,32 @@ import android.support.v7.widget.Toolbar;
|
|||||||
import android.view.Menu;
|
import android.view.Menu;
|
||||||
import android.view.MenuItem;
|
import android.view.MenuItem;
|
||||||
|
|
||||||
|
import org.bspeice.minimalbible.Injector;
|
||||||
|
import org.bspeice.minimalbible.MinimalBible;
|
||||||
|
import org.bspeice.minimalbible.OGHolder;
|
||||||
import org.bspeice.minimalbible.R;
|
import org.bspeice.minimalbible.R;
|
||||||
import org.bspeice.minimalbible.activity.BaseActivity;
|
import org.bspeice.minimalbible.activity.BaseActivity;
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadActivity;
|
import org.bspeice.minimalbible.activity.downloader.DownloadActivity;
|
||||||
import org.bspeice.minimalbible.activity.search.BasicSearch;
|
import org.bspeice.minimalbible.activity.search.BasicSearch;
|
||||||
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
||||||
import org.bspeice.minimalbible.activity.settings.MinimalBibleSettings;
|
import org.bspeice.minimalbible.activity.settings.MinimalBibleSettings;
|
||||||
import org.bspeice.minimalbible.activity.viewer.injection.BibleViewerModules;
|
|
||||||
import org.bspeice.minimalbible.activity.viewer.injection.DaggerViewerComponent;
|
|
||||||
import org.bspeice.minimalbible.activity.viewer.injection.ViewerComponent;
|
|
||||||
import org.bspeice.minimalbible.common.injection.MainBookModule;
|
|
||||||
import org.crosswire.jsword.book.Book;
|
import org.crosswire.jsword.book.Book;
|
||||||
import org.crosswire.jsword.index.IndexStatus;
|
import org.crosswire.jsword.index.IndexStatus;
|
||||||
|
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
|
import javax.inject.Named;
|
||||||
|
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
import butterknife.InjectView;
|
import butterknife.InjectView;
|
||||||
|
import dagger.ObjectGraph;
|
||||||
import rx.android.schedulers.AndroidSchedulers;
|
import rx.android.schedulers.AndroidSchedulers;
|
||||||
import rx.functions.Action1;
|
import rx.functions.Action1;
|
||||||
import rx.subjects.PublishSubject;
|
import rx.subjects.PublishSubject;
|
||||||
|
|
||||||
public class BibleViewer extends BaseActivity {
|
public class BibleViewer extends BaseActivity implements Injector {
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
@Nullable
|
@Named("MainBook")
|
||||||
Book mainBook;
|
Book mainBook;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
@ -62,14 +62,30 @@ public class BibleViewer extends BaseActivity {
|
|||||||
@InjectView(R.id.drawer_layout)
|
@InjectView(R.id.drawer_layout)
|
||||||
DrawerLayout drawerLayout;
|
DrawerLayout drawerLayout;
|
||||||
|
|
||||||
public void inject() {
|
private ObjectGraph bvObjectGraph;
|
||||||
// TODO: Cache the component
|
|
||||||
// TODO: Refactor the component design
|
/**
|
||||||
ViewerComponent component = DaggerViewerComponent.builder()
|
* Build a scoped object graph for anything used by the BibleViewer
|
||||||
.mainBookModule(new MainBookModule(this))
|
* and inject ourselves
|
||||||
.bibleViewerModules(new BibleViewerModules(this))
|
* TODO: Refactor so buildObjGraph doesn't have side effects
|
||||||
.build();
|
*/
|
||||||
component.injectBibleViewer(this);
|
private void buildObjGraph() {
|
||||||
|
if (bvObjectGraph == null) {
|
||||||
|
OGHolder holder = OGHolder.get(this);
|
||||||
|
bvObjectGraph = holder.fetchGraph();
|
||||||
|
if (bvObjectGraph == null) {
|
||||||
|
bvObjectGraph = MinimalBible.get(this)
|
||||||
|
.plus(new BibleViewerModules(this));
|
||||||
|
holder.persistGraph(bvObjectGraph);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
bvObjectGraph.inject(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void inject(Object o) {
|
||||||
|
buildObjGraph();
|
||||||
|
bvObjectGraph.inject(o);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -80,7 +96,7 @@ public class BibleViewer extends BaseActivity {
|
|||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
this.inject();
|
this.inject(this);
|
||||||
|
|
||||||
// Check that we have a book installed
|
// Check that we have a book installed
|
||||||
if (mainBook == null) {
|
if (mainBook == null) {
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
package org.bspeice.minimalbible.activity.viewer.injection;
|
package org.bspeice.minimalbible.activity.viewer;
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.viewer.BibleViewer;
|
import org.bspeice.minimalbible.MinimalBibleModules;
|
||||||
import org.bspeice.minimalbible.activity.viewer.BookScrollEvent;
|
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
import dagger.Module;
|
import dagger.Module;
|
||||||
import dagger.Provides;
|
import dagger.Provides;
|
||||||
@ -10,7 +11,13 @@ import rx.subjects.PublishSubject;
|
|||||||
/**
|
/**
|
||||||
* Modules used for the BibleViewer activity
|
* Modules used for the BibleViewer activity
|
||||||
*/
|
*/
|
||||||
@Module
|
@Module(
|
||||||
|
injects = {
|
||||||
|
BibleViewer.class,
|
||||||
|
},
|
||||||
|
addsTo = MinimalBibleModules.class
|
||||||
|
)
|
||||||
|
@SuppressWarnings("unused")
|
||||||
public class BibleViewerModules {
|
public class BibleViewerModules {
|
||||||
BibleViewer activity;
|
BibleViewer activity;
|
||||||
|
|
||||||
@ -20,6 +27,7 @@ public class BibleViewerModules {
|
|||||||
|
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
|
@Singleton
|
||||||
PublishSubject<BookScrollEvent> scrollEventPublisher() {
|
PublishSubject<BookScrollEvent> scrollEventPublisher() {
|
||||||
return PublishSubject.create();
|
return PublishSubject.create();
|
||||||
}
|
}
|
@ -1,14 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.activity.viewer.injection;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.viewer.BibleViewer;
|
|
||||||
import org.bspeice.minimalbible.common.injection.InvalidBookModule;
|
|
||||||
import org.bspeice.minimalbible.common.injection.MainBookModule;
|
|
||||||
|
|
||||||
import dagger.Component;
|
|
||||||
|
|
||||||
@Component(modules = {MainBookModule.class, BibleViewerModules.class,
|
|
||||||
InvalidBookModule.class})
|
|
||||||
public interface ViewerComponent {
|
|
||||||
|
|
||||||
public BibleViewer injectBibleViewer(BibleViewer viewer);
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.common.injection;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import dagger.Module;
|
|
||||||
import dagger.Provides;
|
|
||||||
|
|
||||||
@Module
|
|
||||||
public class InvalidBookModule {
|
|
||||||
/**
|
|
||||||
* Provide a list of book names that are known bad. This can be because they trigger NPE,
|
|
||||||
* or are just missing lots of content, etc.
|
|
||||||
*
|
|
||||||
* @return the list of books (by name) to ignore
|
|
||||||
*/
|
|
||||||
@Provides
|
|
||||||
List<String> invalidBooks() {
|
|
||||||
List<String> list = new ArrayList<>();
|
|
||||||
list.add("ABU"); // Missing content
|
|
||||||
list.add("ERen_no"); // Thinks its installed, when it isn't. Triggers NPE
|
|
||||||
list.add("ot1nt2"); // Thinks its installed, when it isn't. Triggers NPE
|
|
||||||
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,124 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.common.injection;
|
|
||||||
|
|
||||||
import android.content.Context;
|
|
||||||
import android.support.annotation.Nullable;
|
|
||||||
import android.util.Log;
|
|
||||||
|
|
||||||
import org.bspeice.minimalbible.activity.search.MBIndexManager;
|
|
||||||
import org.bspeice.minimalbible.activity.viewer.BibleViewerPreferences;
|
|
||||||
import org.bspeice.minimalbible.service.manager.BookManager;
|
|
||||||
import org.crosswire.jsword.book.Book;
|
|
||||||
import org.crosswire.jsword.book.Books;
|
|
||||||
import org.crosswire.jsword.index.IndexManager;
|
|
||||||
import org.crosswire.jsword.index.IndexManagerFactory;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.NoSuchElementException;
|
|
||||||
import java.util.concurrent.atomic.AtomicReference;
|
|
||||||
|
|
||||||
import dagger.Module;
|
|
||||||
import dagger.Provides;
|
|
||||||
import de.devland.esperandro.Esperandro;
|
|
||||||
import rx.Observable;
|
|
||||||
import rx.functions.Action1;
|
|
||||||
import rx.functions.Func1;
|
|
||||||
|
|
||||||
@Module
|
|
||||||
public class MainBookModule {
|
|
||||||
|
|
||||||
private Context context;
|
|
||||||
|
|
||||||
public MainBookModule(Context context) {
|
|
||||||
this.context = context;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Use this to get the list of books installed, as filtered by what should be excluded
|
|
||||||
*
|
|
||||||
* @param b The raw Books instance to get the installed list from
|
|
||||||
* @param invalidBooks The books to exclude from usage
|
|
||||||
* @return The books available for using
|
|
||||||
*/
|
|
||||||
@Provides
|
|
||||||
List<Book> provideInstalledBooks(Books b, final List<String> invalidBooks) {
|
|
||||||
List<Book> rawBooks = b.getBooks();
|
|
||||||
return Observable.from(rawBooks)
|
|
||||||
.filter(new Func1<Book, Boolean>() {
|
|
||||||
@Override
|
|
||||||
public Boolean call(Book book) {
|
|
||||||
return !invalidBooks.contains(book.getInitials());
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.toList().toBlocking().first();
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO: Preferences to a separate module?
|
|
||||||
@Provides
|
|
||||||
BibleViewerPreferences providePrefs() {
|
|
||||||
return Esperandro.getPreferences(BibleViewerPreferences.class, context);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
@Nullable
|
|
||||||
Book provideMainBook(BookManager bookManager, final BibleViewerPreferences prefs) {
|
|
||||||
final AtomicReference<Book> mBook = new AtomicReference<>(null);
|
|
||||||
bookManager.getInstalledBooks()
|
|
||||||
.first(new Func1<Book, Boolean>() {
|
|
||||||
@Override
|
|
||||||
public Boolean call(Book book) {
|
|
||||||
return book.getInitials().equals(prefs.defaultBookInitials());
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.subscribe(new Action1<Book>() {
|
|
||||||
@Override
|
|
||||||
public void call(Book book) {
|
|
||||||
mBook.set(book);
|
|
||||||
}
|
|
||||||
}, new Action1<Throwable>() {
|
|
||||||
@Override
|
|
||||||
public void call(Throwable throwable) {
|
|
||||||
Log.d("BibleViewerModules", throwable.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
if (mBook.get() == null) {
|
|
||||||
try {
|
|
||||||
Book fallback;
|
|
||||||
fallback = bookManager.getInstalledBooks()
|
|
||||||
.onErrorReturn(new Func1<Throwable, Book>() {
|
|
||||||
@Override
|
|
||||||
public Book call(Throwable throwable) {
|
|
||||||
// If there's no book installed, we can't select the main one...
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.toBlocking().first();
|
|
||||||
|
|
||||||
prefs.defaultBookInitials(fallback.getName());
|
|
||||||
mBook.set(fallback);
|
|
||||||
} catch (NoSuchElementException e) {
|
|
||||||
// If no books are installed, there's really nothing we can do...
|
|
||||||
Log.d("BibleViewerModules", "No books are installed, so can't select a main book.");
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return mBook.get();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
BookManager bookManager(List<String> exclude) {
|
|
||||||
return new BookManager(exclude);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
IndexManager indexManager() {
|
|
||||||
return IndexManagerFactory.getIndexManager();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Provides
|
|
||||||
MBIndexManager mbIndexManager(IndexManager indexManager) {
|
|
||||||
return new MBIndexManager(indexManager);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,6 +1,5 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.manager
|
package org.bspeice.minimalbible.activity.downloader.manager
|
||||||
|
|
||||||
import android.util.Log
|
|
||||||
import org.crosswire.common.util.Language
|
import org.crosswire.common.util.Language
|
||||||
import org.crosswire.jsword.book.BookCategory
|
import org.crosswire.jsword.book.BookCategory
|
||||||
import rx.Observable
|
import rx.Observable
|
||||||
@ -34,7 +33,6 @@ class LocaleManager(val rM: RefreshManager) {
|
|||||||
|
|
||||||
fun sortedLanguagesForCategory(cat: BookCategory): List<Language> =
|
fun sortedLanguagesForCategory(cat: BookCategory): List<Language> =
|
||||||
languagesForCategory(cat)
|
languagesForCategory(cat)
|
||||||
.doOnNext { Log.d("LocaleManager", "Just trying to do something... ${it}") }
|
|
||||||
// Finally, sort all languages, prioritizing the current
|
// Finally, sort all languages, prioritizing the current
|
||||||
.toSortedList { left, right -> compareLanguages(left, right, currentLanguage) }
|
.toSortedList { left, right -> compareLanguages(left, right, currentLanguage) }
|
||||||
// And flatten this into the actual List needed
|
// And flatten this into the actual List needed
|
||||||
|
@ -1,13 +1,17 @@
|
|||||||
package org.bspeice.minimalbible.activity.downloader.manager
|
package org.bspeice.minimalbible.activity.downloader.manager
|
||||||
|
|
||||||
import android.net.ConnectivityManager
|
|
||||||
import android.util.Log
|
|
||||||
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs
|
|
||||||
import org.crosswire.jsword.book.Book
|
|
||||||
import org.crosswire.jsword.book.install.Installer
|
import org.crosswire.jsword.book.install.Installer
|
||||||
import rx.Observable
|
import rx.Observable
|
||||||
|
import org.crosswire.jsword.book.Book
|
||||||
import rx.schedulers.Schedulers
|
import rx.schedulers.Schedulers
|
||||||
import java.util.Calendar
|
import java.util.Calendar
|
||||||
|
import org.bspeice.minimalbible.activity.downloader.DownloadPrefs
|
||||||
|
import android.net.ConnectivityManager
|
||||||
|
import org.crosswire.jsword.book.BookComparators
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by bspeice on 10/22/14.
|
||||||
|
*/
|
||||||
|
|
||||||
class RefreshManager(val installers: Collection<Installer>,
|
class RefreshManager(val installers: Collection<Installer>,
|
||||||
val exclude: List<String>,
|
val exclude: List<String>,
|
||||||
@ -17,13 +21,11 @@ class RefreshManager(val installers: Collection<Installer>,
|
|||||||
val currentTime = Calendar.getInstance().getTime().getTime()
|
val currentTime = Calendar.getInstance().getTime().getTime()
|
||||||
val fifteenDaysAgo = currentTime - 1296000
|
val fifteenDaysAgo = currentTime - 1296000
|
||||||
|
|
||||||
val availableModules: Observable<Map<Installer, List<Book>>> = Observable.from(installers)
|
val availableModules: Observable<Map<Installer, List<Book>>> =
|
||||||
|
Observable.from(installers)
|
||||||
.map {
|
.map {
|
||||||
/*
|
|
||||||
if (performReload())
|
if (performReload())
|
||||||
it.reloadBookList()
|
it.reloadBookList()
|
||||||
*/
|
|
||||||
Log.d("RefreshManager", "Just trying to do something...")
|
|
||||||
|
|
||||||
// TODO: mapOf(it to booksFromInstaller)
|
// TODO: mapOf(it to booksFromInstaller)
|
||||||
mapOf(Pair(it,
|
mapOf(Pair(it,
|
||||||
@ -33,7 +35,6 @@ class RefreshManager(val installers: Collection<Installer>,
|
|||||||
// part of the pipeline, so it remains a cold observable
|
// part of the pipeline, so it remains a cold observable
|
||||||
.doOnCompleted { prefs.downloadRefreshedOn(currentTime) }
|
.doOnCompleted { prefs.downloadRefreshedOn(currentTime) }
|
||||||
.subscribeOn(Schedulers.io())
|
.subscribeOn(Schedulers.io())
|
||||||
.doOnError({ Log.e("RefreshManager", "Testing", it) })
|
|
||||||
.cache()
|
.cache()
|
||||||
|
|
||||||
val flatModules: Observable<Book> =
|
val flatModules: Observable<Book> =
|
||||||
@ -43,6 +44,10 @@ class RefreshManager(val installers: Collection<Installer>,
|
|||||||
// Lists -> Single list
|
// Lists -> Single list
|
||||||
.flatMap { Observable.from(it) }
|
.flatMap { Observable.from(it) }
|
||||||
|
|
||||||
|
val flatModulesSorted = flatModules.toSortedList {(book1, book2) ->
|
||||||
|
BookComparators.getInitialComparator().compare(book1, book2)
|
||||||
|
}
|
||||||
|
|
||||||
fun doReload(downloadEnabled: Boolean, lastUpdated: Long,
|
fun doReload(downloadEnabled: Boolean, lastUpdated: Long,
|
||||||
networkState: Int? = ConnectivityManager.TYPE_DUMMY): Boolean =
|
networkState: Int? = ConnectivityManager.TYPE_DUMMY): Boolean =
|
||||||
if (!downloadEnabled || networkState != ConnectivityManager.TYPE_WIFI)
|
if (!downloadEnabled || networkState != ConnectivityManager.TYPE_WIFI)
|
||||||
@ -57,10 +62,8 @@ class RefreshManager(val installers: Collection<Installer>,
|
|||||||
prefs.downloadRefreshedOn(),
|
prefs.downloadRefreshedOn(),
|
||||||
connManager?.getActiveNetworkInfo()?.getType())
|
connManager?.getActiveNetworkInfo()?.getType())
|
||||||
|
|
||||||
fun booksFromInstaller(inst: Installer, exclude: List<String>): List<Book> {
|
fun booksFromInstaller(inst: Installer, exclude: List<String>) =
|
||||||
Log.d("Getting books from: ", "${inst.getInstallerDefinition()}")
|
inst.getBooks().filterNot { exclude contains it.getInitials() }
|
||||||
return inst.getBooks().filterNot { exclude contains it.getInitials() }
|
|
||||||
}
|
|
||||||
|
|
||||||
fun installerFromBook(b: Book): Observable<Installer> = Observable.just(
|
fun installerFromBook(b: Book): Observable<Installer> = Observable.just(
|
||||||
availableModules.filter {
|
availableModules.filter {
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
package org.bspeice.minimalbible.activity.search
|
package org.bspeice.minimalbible.activity.search
|
||||||
|
|
||||||
import android.util.Log
|
|
||||||
import org.crosswire.jsword.book.Book
|
|
||||||
import org.crosswire.jsword.index.IndexManager
|
|
||||||
import org.crosswire.jsword.index.search.SearchType
|
|
||||||
import org.crosswire.jsword.passage.Verse
|
import org.crosswire.jsword.passage.Verse
|
||||||
|
import org.crosswire.jsword.index.search.SearchType
|
||||||
|
import org.crosswire.jsword.book.Book
|
||||||
|
import android.util.Log
|
||||||
|
import org.crosswire.jsword.index.IndexManager
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is the entry point for handling the actual bible search. Likely will support
|
* This is the entry point for handling the actual bible search. Likely will support
|
||||||
@ -14,7 +14,7 @@ class SearchProvider(val indexManager: IndexManager, val book: Book?) {
|
|||||||
|
|
||||||
val defaultSearchType = SearchType.ANY_WORDS
|
val defaultSearchType = SearchType.ANY_WORDS
|
||||||
|
|
||||||
@suppress("UNUSED_PARAMETER")
|
[suppress("UNUSED_PARAMETER")]
|
||||||
public fun basicTextSearch(text: String): List<Verse> {
|
public fun basicTextSearch(text: String): List<Verse> {
|
||||||
if (!isSearchAvailable()) {
|
if (!isSearchAvailable()) {
|
||||||
Log.w("SearchProvider", "Search unavailable, index status of ${book?.getInitials()}: ${book?.getIndexStatus()}")
|
Log.w("SearchProvider", "Search unavailable, index status of ${book?.getInitials()}: ${book?.getIndexStatus()}")
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package org.bspeice.minimalbible.activity.viewer
|
package org.bspeice.minimalbible.activity.viewer
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
import android.content.res.Resources
|
||||||
import android.util.AttributeSet
|
import android.util.AttributeSet
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.View
|
import android.view.View
|
||||||
@ -28,7 +29,7 @@ class BibleMenu(val ctx: Context, val attrs: AttributeSet) : LinearLayout(ctx, a
|
|||||||
|
|
||||||
class BibleMenuGroup(val bindTo: View) {
|
class BibleMenuGroup(val bindTo: View) {
|
||||||
val content = bindTo.findViewById(R.id.content) as TextView
|
val content = bindTo.findViewById(R.id.content) as TextView
|
||||||
val resources = bindTo.getResources()
|
val resources = bindTo.getResources(): Resources
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
fun init(v: View, obj: Any, highlighted: Boolean): View {
|
fun init(v: View, obj: Any, highlighted: Boolean): View {
|
||||||
|
@ -2,6 +2,7 @@ package org.bspeice.minimalbible.activity.viewer
|
|||||||
|
|
||||||
import android.support.v7.widget.RecyclerView
|
import android.support.v7.widget.RecyclerView
|
||||||
import android.text.SpannableStringBuilder
|
import android.text.SpannableStringBuilder
|
||||||
|
import android.util.Log
|
||||||
import android.widget.TextView
|
import android.widget.TextView
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.OsisParser
|
import org.bspeice.minimalbible.service.format.osisparser.OsisParser
|
||||||
import org.crosswire.jsword.book.Book
|
import org.crosswire.jsword.book.Book
|
||||||
@ -10,18 +11,18 @@ import org.crosswire.jsword.book.getVersification
|
|||||||
class PassageView(val v: TextView, val b: Book)
|
class PassageView(val v: TextView, val b: Book)
|
||||||
: RecyclerView.ViewHolder(v) {
|
: RecyclerView.ViewHolder(v) {
|
||||||
|
|
||||||
val parser = OsisParser()
|
|
||||||
|
|
||||||
fun buildOrdinal(verse: Int, info: BookAdapter.ChapterInfo) =
|
fun buildOrdinal(verse: Int, info: BookAdapter.ChapterInfo) =
|
||||||
b.getVersification().decodeOrdinal(verse + info.vOffset)
|
b.getVersification().decodeOrdinal(verse + info.vOffset)
|
||||||
|
|
||||||
fun getAllVerses(verses: Progression<Int>, info: BookAdapter.ChapterInfo): SpannableStringBuilder {
|
fun getAllVerses(verses: Progression<Int>, info: BookAdapter.ChapterInfo): SpannableStringBuilder {
|
||||||
val builder = SpannableStringBuilder()
|
val builder = SpannableStringBuilder()
|
||||||
|
val parser = OsisParser()
|
||||||
verses.forEach { parser.appendVerse(b, buildOrdinal(it, info), builder) }
|
verses.forEach { parser.appendVerse(b, buildOrdinal(it, info), builder) }
|
||||||
return builder
|
return builder
|
||||||
}
|
}
|
||||||
|
|
||||||
fun bind(info: BookAdapter.ChapterInfo) {
|
fun bind(info: BookAdapter.ChapterInfo) {
|
||||||
|
Log.d("PassageView", "Binding chapter ${info.chapter}")
|
||||||
v setText getAllVerses(info.vStart..info.vEnd, info)
|
v setText getAllVerses(info.vStart..info.vEnd, info)
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,17 +1,18 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser
|
package org.bspeice.minimalbible.service.format.osisparser
|
||||||
|
|
||||||
import android.text.SpannableStringBuilder
|
|
||||||
import org.bspeice.minimalbible.MinimalBible
|
|
||||||
import org.bspeice.minimalbible.R
|
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.handler.*
|
|
||||||
import org.crosswire.jsword.book.Book
|
|
||||||
import org.crosswire.jsword.book.BookData
|
|
||||||
import org.crosswire.jsword.book.OSISUtil
|
|
||||||
import org.crosswire.jsword.passage.Verse
|
|
||||||
import org.xml.sax.Attributes
|
|
||||||
import org.xml.sax.helpers.DefaultHandler
|
import org.xml.sax.helpers.DefaultHandler
|
||||||
|
import org.crosswire.jsword.passage.Verse
|
||||||
import java.util.ArrayDeque
|
import java.util.ArrayDeque
|
||||||
|
import org.xml.sax.Attributes
|
||||||
|
import org.crosswire.jsword.book.OSISUtil
|
||||||
|
import org.crosswire.jsword.book.BookData
|
||||||
|
import org.crosswire.jsword.book.Book
|
||||||
import kotlin.properties.Delegates
|
import kotlin.properties.Delegates
|
||||||
|
import org.bspeice.minimalbible.service.format.osisparser.handler.TagHandler
|
||||||
|
import org.bspeice.minimalbible.service.format.osisparser.handler.VerseHandler
|
||||||
|
import org.bspeice.minimalbible.service.format.osisparser.handler.UnknownHandler
|
||||||
|
import android.text.SpannableStringBuilder
|
||||||
|
import org.bspeice.minimalbible.service.format.osisparser.handler.DivineHandler
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Parse out the OSIS XML into whatever we want!
|
* Parse out the OSIS XML into whatever we want!
|
||||||
@ -25,11 +26,8 @@ class OsisParser() : DefaultHandler() {
|
|||||||
// Don't pass a verse as part of the constructor, but still guarantee
|
// Don't pass a verse as part of the constructor, but still guarantee
|
||||||
// that it will exist
|
// that it will exist
|
||||||
var verseContent: VerseContent by Delegates.notNull()
|
var verseContent: VerseContent by Delegates.notNull()
|
||||||
|
|
||||||
var builder: SpannableStringBuilder by Delegates.notNull()
|
var builder: SpannableStringBuilder by Delegates.notNull()
|
||||||
|
|
||||||
var state: ParseState = ParseState(listOf())
|
|
||||||
|
|
||||||
// TODO: Implement a stack to keep min API 8
|
// TODO: Implement a stack to keep min API 8
|
||||||
val handlerStack = ArrayDeque<TagHandler>()
|
val handlerStack = ArrayDeque<TagHandler>()
|
||||||
|
|
||||||
@ -55,25 +53,18 @@ class OsisParser() : DefaultHandler() {
|
|||||||
|
|
||||||
override fun startElement(uri: String, localName: String,
|
override fun startElement(uri: String, localName: String,
|
||||||
qName: String, attributes: Attributes) {
|
qName: String, attributes: Attributes) {
|
||||||
val tag = when (localName) {
|
when (localName) {
|
||||||
OSISUtil.OSIS_ELEMENT_VERSE -> VerseHandler()
|
OSISUtil.OSIS_ELEMENT_VERSE -> handlerStack push VerseHandler()
|
||||||
"divineName" -> DivineHandler()
|
"divineName" -> handlerStack push DivineHandler()
|
||||||
"q" -> QHandler(MinimalBible.getAppContext()
|
else -> handlerStack push UnknownHandler(localName)
|
||||||
.getResources().getColor(R.color.divineSpeech))
|
|
||||||
else -> UnknownHandler(localName)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
state = tag.start(attributes, verseContent, builder, state)
|
|
||||||
handlerStack push tag
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun endElement(uri: String, localName: String, qName: String) {
|
override fun endElement(uri: String, localName: String, qName: String) {
|
||||||
val tagHandler = handlerStack.pop()
|
handlerStack.pop()
|
||||||
state = tagHandler.end(verseContent, builder, state) build builder
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun characters(ch: CharArray, start: Int, length: Int) {
|
override fun characters(ch: CharArray, start: Int, length: Int) {
|
||||||
val tag = handlerStack.peek()
|
handlerStack.peek().render(builder, verseContent, String(ch))
|
||||||
state = tag.render(builder, verseContent, String(ch), state)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,23 +1,19 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser.handler
|
package org.bspeice.minimalbible.service.format.osisparser.handler
|
||||||
|
|
||||||
import android.text.SpannableStringBuilder
|
import android.text.SpannableStringBuilder
|
||||||
import android.text.style.RelativeSizeSpan
|
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
||||||
import org.xml.sax.Attributes
|
import android.text.style.RelativeSizeSpan
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by bspeice on 12/1/14.
|
||||||
|
*/
|
||||||
class DivineHandler() : TagHandler {
|
class DivineHandler() : TagHandler {
|
||||||
override fun end(info: VerseContent, builder: SpannableStringBuilder,
|
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String) {
|
||||||
state: ParseState) = state
|
this buildDivineName chars forEach { it apply builder }
|
||||||
|
}
|
||||||
override fun start(attrs: Attributes, info: VerseContent, builder: SpannableStringBuilder,
|
|
||||||
state: ParseState) = state
|
|
||||||
|
|
||||||
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String,
|
|
||||||
state: ParseState) =
|
|
||||||
state append(buildDivineName(chars))
|
|
||||||
|
|
||||||
fun buildDivineName(chars: String) =
|
fun buildDivineName(chars: String) =
|
||||||
listOf(AppendArgs(chars take 1),
|
listOf(AppendArgs(chars take 1, null),
|
||||||
AppendArgs((chars drop 1).toUpperCase(), RelativeSizeSpan(.8f))
|
AppendArgs((chars drop 1).toUpperCase(), RelativeSizeSpan(.8f))
|
||||||
)
|
)
|
||||||
}
|
}
|
@ -1,22 +0,0 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser.handler
|
|
||||||
|
|
||||||
import android.text.SpannableStringBuilder
|
|
||||||
import android.text.style.ForegroundColorSpan
|
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
|
||||||
import org.xml.sax.Attributes
|
|
||||||
|
|
||||||
class QHandler(val color: Int) : TagHandler {
|
|
||||||
|
|
||||||
fun retrieveMarker(attrs: Attributes) =
|
|
||||||
AppendArgs(attrs getValue "marker" ?: "")
|
|
||||||
|
|
||||||
override fun start(attrs: Attributes, info: VerseContent, builder: SpannableStringBuilder,
|
|
||||||
state: ParseState) = state append retrieveMarker(attrs)
|
|
||||||
|
|
||||||
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String,
|
|
||||||
state: ParseState) =
|
|
||||||
state append AppendArgs(chars.trim() + " ", ForegroundColorSpan(color))
|
|
||||||
|
|
||||||
override fun end(info: VerseContent, builder: SpannableStringBuilder,
|
|
||||||
state: ParseState) = state
|
|
||||||
}
|
|
@ -1,41 +1,25 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser.handler
|
package org.bspeice.minimalbible.service.format.osisparser.handler
|
||||||
|
|
||||||
import android.text.SpannableStringBuilder
|
import android.text.SpannableStringBuilder
|
||||||
import android.text.style.CharacterStyle
|
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
||||||
import org.xml.sax.Attributes
|
import android.text.style.CharacterStyle
|
||||||
|
|
||||||
interface TagHandler {
|
/**
|
||||||
fun start(attrs: Attributes, info: VerseContent, builder: SpannableStringBuilder,
|
* Created by bspeice on 12/1/14.
|
||||||
state: ParseState): ParseState
|
*/
|
||||||
|
|
||||||
fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String,
|
trait TagHandler {
|
||||||
state: ParseState): ParseState
|
fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String)
|
||||||
|
|
||||||
fun end(info: VerseContent, builder: SpannableStringBuilder,
|
|
||||||
state: ParseState): ParseState
|
|
||||||
}
|
}
|
||||||
|
|
||||||
class ParseState(val spans: List<AppendArgs>) {
|
data class AppendArgs(val text: String, val span: Any?) {
|
||||||
|
|
||||||
fun build(builder: SpannableStringBuilder): ParseState {
|
|
||||||
spans.forEach { it apply builder }
|
|
||||||
return ParseState(listOf())
|
|
||||||
}
|
|
||||||
|
|
||||||
fun append(arg: AppendArgs) = ParseState(spans + arg)
|
|
||||||
|
|
||||||
fun append(args: List<AppendArgs>) = ParseState(spans + args)
|
|
||||||
}
|
|
||||||
|
|
||||||
data class AppendArgs(val text: String, val span: Any? = null) {
|
|
||||||
fun apply(builder: SpannableStringBuilder) {
|
fun apply(builder: SpannableStringBuilder) {
|
||||||
val offset = builder.length()
|
val offset = builder.length()
|
||||||
builder.append(text)
|
builder.append(text)
|
||||||
when (span) {
|
when (span) {
|
||||||
is List<*> -> span.forEach { builder.setSpan(it, offset, offset + text.length(), 0) }
|
is List<*> -> span.forEach { builder.setSpan(it, offset, offset + text.length, 0) }
|
||||||
is CharacterStyle -> builder.setSpan(span, offset, offset + text.length(), 0)
|
is CharacterStyle -> builder.setSpan(span, offset, offset + text.length, 0)
|
||||||
}
|
}
|
||||||
builder.setSpan(span, offset, offset + text.length(), 0)
|
builder.setSpan(span, offset, offset + text.length, 0)
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,20 +1,14 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser.handler
|
package org.bspeice.minimalbible.service.format.osisparser.handler
|
||||||
|
|
||||||
import android.text.SpannableStringBuilder
|
import android.text.SpannableStringBuilder
|
||||||
import com.orhanobut.logger.Logger
|
import android.util.Log
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
||||||
import org.xml.sax.Attributes
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by bspeice on 12/1/14.
|
||||||
|
*/
|
||||||
class UnknownHandler(val tagName: String) : TagHandler {
|
class UnknownHandler(val tagName: String) : TagHandler {
|
||||||
override fun end(info: VerseContent, builder: SpannableStringBuilder,
|
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String) {
|
||||||
state: ParseState): ParseState = state
|
Log.d("UnknownHandler", "Unknown tag $tagName received text: $chars")
|
||||||
|
|
||||||
override fun start(attrs: Attributes, info: VerseContent, builder: SpannableStringBuilder,
|
|
||||||
state: ParseState) = state
|
|
||||||
|
|
||||||
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String,
|
|
||||||
state: ParseState): ParseState {
|
|
||||||
Logger.v("Unknown tag '$tagName' received text: '$chars'")
|
|
||||||
return state
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,28 +1,28 @@
|
|||||||
package org.bspeice.minimalbible.service.format.osisparser.handler
|
package org.bspeice.minimalbible.service.format.osisparser.handler
|
||||||
|
|
||||||
import android.graphics.Typeface
|
|
||||||
import android.text.SpannableStringBuilder
|
import android.text.SpannableStringBuilder
|
||||||
import android.text.style.RelativeSizeSpan
|
|
||||||
import android.text.style.StyleSpan
|
|
||||||
import android.text.style.SuperscriptSpan
|
|
||||||
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
import org.bspeice.minimalbible.service.format.osisparser.VerseContent
|
||||||
import org.xml.sax.Attributes
|
import android.text.style.StyleSpan
|
||||||
|
import android.graphics.Typeface
|
||||||
|
import android.text.style.SuperscriptSpan
|
||||||
|
import android.text.style.RelativeSizeSpan
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by bspeice on 12/1/14.
|
||||||
|
*/
|
||||||
class VerseHandler() : TagHandler {
|
class VerseHandler() : TagHandler {
|
||||||
|
var isVerseStart = true
|
||||||
|
|
||||||
override fun end(info: VerseContent, builder: SpannableStringBuilder,
|
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String) {
|
||||||
state: ParseState) =
|
buildVerseHeader(info.chapter, info.verseNum, isVerseStart) apply builder
|
||||||
state append AppendArgs(" ")
|
builder append chars
|
||||||
|
isVerseStart = false
|
||||||
override fun start(attrs: Attributes, info: VerseContent,
|
|
||||||
builder: SpannableStringBuilder, state: ParseState) =
|
|
||||||
state append when {
|
|
||||||
info.verseNum == 1 -> AppendArgs("${info.chapter} ", StyleSpan(Typeface.BOLD))
|
|
||||||
else -> AppendArgs("${info.verseNum}",
|
|
||||||
listOf(SuperscriptSpan(), RelativeSizeSpan(.75f)))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun render(builder: SpannableStringBuilder, info: VerseContent, chars: String,
|
fun buildVerseHeader(chapter: Int, verseNum: Int, verseStart: Boolean): AppendArgs =
|
||||||
state: ParseState) =
|
when {
|
||||||
state append AppendArgs(chars)
|
!verseStart -> AppendArgs("", null)
|
||||||
|
verseNum == 1 -> AppendArgs("$chapter ", StyleSpan(Typeface.BOLD))
|
||||||
|
else -> AppendArgs("${verseNum}", listOf(SuperscriptSpan(), RelativeSizeSpan(.75f)))
|
||||||
|
}
|
||||||
}
|
}
|
@ -6,7 +6,7 @@ import java.util.ArrayList
|
|||||||
* VersificationUtil class allows Java to easily reach in to Kotlin
|
* VersificationUtil class allows Java to easily reach in to Kotlin
|
||||||
*/
|
*/
|
||||||
object INTRO_BOOKS {
|
object INTRO_BOOKS {
|
||||||
val INTROS = arrayOf(
|
val INTROS = array(
|
||||||
BibleBook.INTRO_BIBLE,
|
BibleBook.INTRO_BIBLE,
|
||||||
BibleBook.INTRO_OT,
|
BibleBook.INTRO_OT,
|
||||||
BibleBook.INTRO_NT
|
BibleBook.INTRO_NT
|
||||||
|
Binary file not shown.
@ -1,2 +0,0 @@
|
|||||||
- Search results now are Material-compliant!
|
|
||||||
- Android 5.1 devices now supported
|
|
@ -1,16 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:card_view="http://schemas.android.com/apk/res-auto"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="?android:attr/listPreferredItemHeight"
|
||||||
android:layout_gravity="center"
|
|
||||||
android:layout_margin="@dimen/cardview_padding"
|
|
||||||
card_view:cardCornerRadius="4dp"
|
|
||||||
card_view:contentPadding="@dimen/cardview_padding">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
@ -26,4 +17,3 @@
|
|||||||
android:ellipsize="end"
|
android:ellipsize="end"
|
||||||
android:textAppearance="?android:attr/textAppearanceSmall" />
|
android:textAppearance="?android:attr/textAppearanceSmall" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</android.support.v7.widget.CardView>
|
|
||||||
|
@ -13,6 +13,4 @@
|
|||||||
|
|
||||||
<color name="settingsTextColor">@color/textColor</color>
|
<color name="settingsTextColor">@color/textColor</color>
|
||||||
<color name="settingsTextColorSecondary">@color/textColorSecondary</color>
|
<color name="settingsTextColorSecondary">@color/textColorSecondary</color>
|
||||||
|
|
||||||
<color name="divineSpeech">@color/colorPrimary</color>
|
|
||||||
</resources>
|
</resources>
|
||||||
|
@ -11,6 +11,4 @@
|
|||||||
<dimen name="toolbar_height">56dp</dimen>
|
<dimen name="toolbar_height">56dp</dimen>
|
||||||
|
|
||||||
<dimen name="biblemenu_child_padding">8dp</dimen>
|
<dimen name="biblemenu_child_padding">8dp</dimen>
|
||||||
|
|
||||||
<dimen name="cardview_padding">4dp</dimen>
|
|
||||||
</resources>
|
</resources>
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user