mirror of
https://github.com/nicobo/dataprovence.git
synced 2026-04-10 07:55:35 +02:00
+ qques fixes
This commit is contained in:
parent
2e1ad141d1
commit
f88ebde1f3
File diff suppressed because one or more lines are too long
1
bin/classes/CentresEquestres.json
Normal file
1
bin/classes/CentresEquestres.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/GolfsEtMinigolfs.json
Normal file
1
bin/classes/GolfsEtMinigolfs.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/LocationDeVelo.json
Normal file
1
bin/classes/LocationDeVelo.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/MonumentsEtStesCulturels.json
Normal file
1
bin/classes/MonumentsEtStesCulturels.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/Musees.json
Normal file
1
bin/classes/Musees.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/ParcsAThemesEtAnimaliers.json
Normal file
1
bin/classes/ParcsAThemesEtAnimaliers.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/ParcsAcrobatiquesForestiers.json
Normal file
1
bin/classes/ParcsAcrobatiquesForestiers.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/ParcsEtJardins.json
Normal file
1
bin/classes/ParcsEtJardins.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/Plages.json
Normal file
1
bin/classes/Plages.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/Restaurants.json
Normal file
1
bin/classes/Restaurants.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/RestaurantsGastronomiques.json
Normal file
1
bin/classes/RestaurantsGastronomiques.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/ServicesDeGuides.json
Normal file
1
bin/classes/ServicesDeGuides.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/SitesNaturelsIncontournables.json
Normal file
1
bin/classes/SitesNaturelsIncontournables.json
Normal file
File diff suppressed because one or more lines are too long
1
bin/classes/SportNautique.json
Normal file
1
bin/classes/SportNautique.json
Normal file
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -3,7 +3,7 @@ package bma.groomservice.data;
|
|||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
public class Poi implements Parcelable {
|
||||
public class Poi implements Parcelable, Comparable<Poi> {
|
||||
|
||||
/** Ex: "65c6fb5e-aa10-4711-8002-74d1ec31f9d6" */
|
||||
public String entityid;
|
||||
|
|
@ -42,6 +42,11 @@ public class Poi implements Parcelable {
|
|||
super();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int compareTo(Poi another) {
|
||||
return entityid.compareTo(another.entityid);
|
||||
}
|
||||
|
||||
public Poi(Parcel p) {
|
||||
this();
|
||||
entityid = p.readString();
|
||||
|
|
|
|||
|
|
@ -67,11 +67,11 @@ public class DataprovenceManager implements PoiListener {
|
|||
|
||||
// false -> lit les données en local (fichiers *.json)
|
||||
// true -> lit les données depuis le net
|
||||
public static final boolean online = false;
|
||||
public boolean online = false;
|
||||
|
||||
private class LoadDataTask extends
|
||||
AsyncTask<DataprovenceHelper, Integer, Long> {
|
||||
List<Poi> taskPois;
|
||||
List<Poi> taskPois = new ArrayList<Poi>();
|
||||
PoiListener listener;
|
||||
|
||||
public LoadDataTask(PoiListener listener) {
|
||||
|
|
@ -99,13 +99,14 @@ public class DataprovenceManager implements PoiListener {
|
|||
}
|
||||
}
|
||||
|
||||
public DataprovenceManager(PoiListener listener) {
|
||||
public DataprovenceManager(PoiListener listener, boolean online) {
|
||||
super();
|
||||
this.listener = listener;
|
||||
this.online = online;
|
||||
this.pois = new TreeSet<Poi>();
|
||||
}
|
||||
|
||||
private static Collection<DataprovenceHelper> findHelpers(
|
||||
Collection<String> tags) {
|
||||
private Collection<DataprovenceHelper> findHelpers(Collection<String> tags) {
|
||||
ArrayList<DataprovenceHelper> helpers = new ArrayList<DataprovenceHelper>();
|
||||
for (String tag : tags) {
|
||||
String[] datasets = DATASETS.get(tag);
|
||||
|
|
@ -134,7 +135,7 @@ public class DataprovenceManager implements PoiListener {
|
|||
}
|
||||
}
|
||||
|
||||
public void findAll(Collection<String> tags) throws IOException {
|
||||
public void findAll(Collection<String> tags) {
|
||||
|
||||
synchronized (this) {
|
||||
count = 0;
|
||||
|
|
@ -153,7 +154,7 @@ public class DataprovenceManager implements PoiListener {
|
|||
}
|
||||
}
|
||||
|
||||
public void findAll(String[] tags) throws IOException {
|
||||
public void findAll(String[] tags) {
|
||||
findAll(Arrays.asList(tags));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue