|
|
@ -24,7 +24,7 @@ public class SimilarSearchManeger implements AlphaFineSearchProvider { |
|
|
|
|
|
|
|
|
|
|
|
public static SimilarSearchManeger getInstance() { |
|
|
|
public static SimilarSearchManeger getInstance() { |
|
|
|
if (instance == null) { |
|
|
|
if (instance == null) { |
|
|
|
synchronized (SimilarSearchManeger.class){ |
|
|
|
synchronized (SimilarSearchManeger.class) { |
|
|
|
if (instance == null) { |
|
|
|
if (instance == null) { |
|
|
|
instance = new SimilarSearchManeger(); |
|
|
|
instance = new SimilarSearchManeger(); |
|
|
|
} |
|
|
|
} |
|
|
@ -41,7 +41,7 @@ public class SimilarSearchManeger implements AlphaFineSearchProvider { |
|
|
|
return new SearchResult(); |
|
|
|
return new SearchResult(); |
|
|
|
} |
|
|
|
} |
|
|
|
SearchResult noConnectList = AlphaFineHelper.getNoConnectList(instance); |
|
|
|
SearchResult noConnectList = AlphaFineHelper.getNoConnectList(instance); |
|
|
|
if(noConnectList != null){ |
|
|
|
if (noConnectList != null) { |
|
|
|
return noConnectList; |
|
|
|
return noConnectList; |
|
|
|
} |
|
|
|
} |
|
|
|
SearchResult allModelList = new SearchResult(); |
|
|
|
SearchResult allModelList = new SearchResult(); |
|
|
@ -51,9 +51,9 @@ public class SimilarSearchManeger implements AlphaFineSearchProvider { |
|
|
|
try { |
|
|
|
try { |
|
|
|
String result = HttpToolbox.get(url); |
|
|
|
String result = HttpToolbox.get(url); |
|
|
|
AlphaFineHelper.checkCancel(); |
|
|
|
AlphaFineHelper.checkCancel(); |
|
|
|
allModelList = AlphaFineHelper.getModelListFromJSONArray(result,"title"); |
|
|
|
allModelList = AlphaFineHelper.getModelListFromJSONArray(result, "title"); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
|
FineLoggerFactory.getLogger().debug("similar search error: " + e.getMessage()); |
|
|
|
FineLoggerFactory.getLogger().debug("similar search error.search str {}", searchText[j]); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
moreModelList.clear(); |
|
|
|
moreModelList.clear(); |
|
|
|