Commit Graph

935 Commits

Author SHA1 Message Date
Matthieu Gautier bba3c252e4 Make the member of the book protected.
It is up to the book to manage its attribute.

Also remove the `absolutePath` (and `indexAbsolutePath`). The `Book::path` is always stored
absolute.
The fact that the path can be stored absolute or relative in the
`library.xml` is not relevant for the book.
2018-09-06 18:30:37 +02:00
Matthieu Gautier 57ac6f0305 Use a map to store the Library's books.
Having the books sorted is useless.
We handle books by id not by index.
2018-09-06 18:30:37 +02:00
Matthieu Gautier 541fb0cfd1 Remove the "current" book functionnality.
- This is not used by any application.
- This is application specific and should not be stored in the library
  (who is a list of book).
2018-09-06 18:30:37 +02:00
Matthieu Gautier c9eac04050 Make the Library`s book vector private.
Move a lot of methods from Manager to Library. Because books is private
and thoses methods are better in Library.
2018-09-06 18:30:37 +02:00
Matthieu Gautier 741c67786a Add `update` method to `Book`. 2018-09-06 18:30:37 +02:00
Matthieu Gautier db9000f706 Make the downloader use the aria2c wrapper instead of the aria2 library. 2018-09-06 18:30:34 +02:00
Matthieu Gautier 0a93cb0872 Add aria2 downloader using subprocess aria2c. 2018-09-06 18:29:49 +02:00
Matthieu Gautier f4846c1ac8 Add a tool's function to get the data directory.
The data directory is where kiwix application should store data.
2018-08-29 15:28:52 +02:00
Matthieu Gautier 9b516ac35d Add a small wrapper around pugixml do handle xmprpc. 2018-08-29 15:28:52 +02:00
Matthieu Gautier 79b780b75b Move the function to convert from xml_node to string in otherTools.
This can be usefull elsewhere than in opds_dumper
2018-08-29 15:28:52 +02:00
Matthieu Gautier f3dd83907d Add backend to launch subprocess.
The windows backend is not tested.
2018-08-29 15:28:52 +02:00
Matthieu Gautier c351e7ccf1
Merge pull request #168 from kiwix/java_jdk8+
Update jni build script to java jdk 8+.
2018-08-20 17:53:39 +02:00
Matthieu Gautier 7c634738dd Update jni build script to java jdk 8+.
With jdk8, `javac` has an option `-h` to generate the header files of
native classes.
So there is no need to run `javah` several times.

As there is now only one command to run (`javac`), there is no need for
the wrapper script `gen_kiwix.sh`.

Fix #167
2018-08-20 12:17:29 +02:00
Matthieu Gautier 4378c52c27
Merge pull request #165 from kiwix/new_version
New version 2.0.2
2018-08-03 21:39:11 +02:00
Matthieu Gautier 790fa99143 New version 2.0.2 2018-08-03 19:37:21 +02:00
Matthieu Gautier db6717e199
Merge pull request #164 from kiwix/windows
Windows
2018-08-03 19:31:31 +02:00
Matthieu Gautier bf2188af14 [Windows] Add extra link arguments to build test on windows. 2018-08-03 19:22:39 +02:00
Matthieu Gautier fd9b6569af Include unistd.h only on unix platform. 2018-08-03 19:22:39 +02:00
Matthieu Gautier 3cf58b5f5b Make libaria2 an optional dependency.
We don't compile libaria2 on Windows.
2018-08-03 19:22:39 +02:00
Matthieu Gautier 182be5d124
Merge pull request #163 from kiwix/android_better_log
[Android] Better error message when failing to read in zim file.
2018-07-31 13:48:11 +02:00
Matthieu Gautier dbcc9140b9 [Android] Better error message when failing to read in zim file.
Let's print the exception's message to allow us to better understand
what went wrong.
2018-07-31 11:49:44 +02:00
Matthieu Gautier d46aff00d1
Merge pull request #159 from kiwix/mhutti1/kiwixlib-fixes
Various kiwixlib fixes
2018-07-27 10:47:21 +02:00
mhutti1 d61580f599 Set JNI values to NULL on error 2018-07-27 10:11:24 +02:00
mhutti1 3227b29c90 Follow redirects in favicons 2018-07-27 10:11:24 +02:00
Matthieu Gautier 4cb55e1eef
Merge pull request #161 from kiwix/new_dep_arrchive_root
New deps archives now contains the BUILD_${PLATFORM} directory.
2018-07-27 10:10:42 +02:00
Matthieu Gautier 9ec3358119 New deps archives now contains the BUILD_${PLATFORM} directory. 2018-07-27 09:36:35 +02:00
Kelson cf21f1793c
Merge pull request #158 from kiwix/compilation_fix
Use -llog only for Android
2018-07-07 22:08:11 +02:00
Kelson c0d5e091d3 Small update of the README 2018-07-07 21:15:48 +02:00
Kelson 620f1b5e13 Use -llog only for Android 2018-07-07 20:19:34 +02:00
Kelson 1e8e897f4a
Merge pull request #155 from kiwix/mhutti1/jni-corrupt-zim
JNI better log & stop crashing if exception thrown at ZIM file opening
2018-06-29 22:13:16 +02:00
Isaac Hutt 76ca4b0cee
Add -llog 2018-06-29 16:57:32 +02:00
mhutti1 709baae934 Convert all JNI cerrs to Android log messages 2018-06-29 16:35:11 +02:00
mhutti1 ea8cd9f1a9 Correctly pass 0 through JNI if ZIM file is corrupted 2018-06-29 15:30:13 +02:00
Kelson 452e7f8883
Merge pull request #152 from kiwix/updated_readme
Update README
2018-06-25 06:14:36 +02:00
Emmanuel Engelhart a66b178633 Update README 2018-06-24 22:16:16 +02:00
Matthieu Gautier 0c26b08dce
Merge pull request #149 from kiwix/version_2.0.1
New version 2.0.1
2018-06-15 18:22:04 +02:00
Matthieu Gautier 2a03147662 New version 2.0.1 2018-06-15 18:07:51 +02:00
Matthieu Gautier 1164cf7444
Merge pull request #150 from kiwix/gcc4.8
[TRAVIS] Compile using the default compiler version 4.8.
2018-06-15 18:07:22 +02:00
Matthieu Gautier 6ef2d5ff4b [TRAVIS] Compile using the default compiler version 4.8. 2018-06-15 08:47:28 +02:00
Matthieu Gautier 3a00c4d671
Merge pull request #147 from kiwix/icu_namespace
Icu namespace
2018-06-11 15:21:30 +02:00
Matthieu Gautier 5025ee4963 Fix icudt version.
We have move to icu version 58 a while ago.
2018-06-11 14:38:32 +02:00
Matthieu Gautier 9aaf82a36d Explicitly use icu namespace.
Fix #145
2018-06-11 14:36:34 +02:00
Kelson 2e38aa796f
Merge pull request #141 from kiwix/mhutti1/url-decoding
Decode reserved characters in URLs
2018-06-01 11:28:37 +02:00
mhutti1 fa99cce68d Decode reserved characters in URLs 2018-05-20 18:41:39 +01:00
Matthieu Gautier fc6a0bcea2
Merge pull request #140 from kiwix/no_stopwords_resources
Remove unused static resources.
2018-05-15 11:37:35 +02:00
Matthieu Gautier 622d2fc23d Remove unused static resources.
Stop words are not use anymore since a long time now that indexing has
been moved to libzim. No need to embedded them in kiwix-lib.
2018-05-15 11:30:30 +02:00
Matthieu Gautier 48933a3b3e
Merge pull request #139 from kiwix/fix_parseUrl
Fix parse url
2018-05-14 18:33:59 +02:00
Matthieu Gautier c0b1c6013e Fix parsing of url
Fix kiwix/kiwix-tools#193
2018-05-14 17:41:05 +02:00
Matthieu Gautier 433a47c3fe Add unittest structure.
No tests, just everything to add tests later.
2018-05-14 17:40:43 +02:00
Matthieu Gautier e9ab074b5d
Merge pull request #136 from kiwix/2.0.0
2.0.0
2018-04-23 20:15:45 +02:00