public class ClientResultService extends Object
Modifier and Type | Field and Description |
---|---|
protected CoserBusinessConfig |
config |
protected ProjectService |
projectService |
Constructor and Description |
---|
ClientResultService(CoserBusinessConfig config) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkDataCollision(Collection<GlobalResult> selectedResults)
Met à jour les fichiers de propriétés des resultats (maps, dataSource)
and check for duplicated couple (zoneid/resulttype (map) upload).
|
List<GlobalResult> |
findAllProjectWithResult(Date beginDate,
Date endDate,
boolean onlyPubliableResult)
Retourne tous les projets qui ont des résultats.
|
protected Collection<GlobalResult> |
getEchoBaseResults(File existingProject,
Date beginDate,
Date endDate,
boolean onlyPubliableResult) |
protected Collection<GlobalResult> |
getRsufiResults(File existingProject,
Date beginDate,
Date endDate,
boolean onlyPubliableResult) |
protected boolean |
isCandidateResult(GlobalResult rsufiResult,
Date beginDate,
Date endDate,
boolean onlyPubliableResult)
Test if result is valid with filtering.
|
protected void |
modifyRSufiResults(Collection<GlobalResult> selectedResults,
Collection<GlobalResult> indicatorsResults,
Collection<GlobalResult> mapResults,
Collection<GlobalResult> publishDataResults)
Modifie les types et options de certains résultats rsufi (map result,
data sources result).
|
File |
performResultExtract(Collection<GlobalResult> selectedResults,
Collection<GlobalResult> publishDataResults,
File extractDirectory)
Extract directory to custom directory.
|
protected void |
performResultExtractForEchoBase(File extractDirectory,
Collection<GlobalResult> selectedResults,
Collection<GlobalResult> publishDataResults)
Extract directory to custom directory.
|
protected void |
performResultExtractForRSufi(File extractDirectory,
Collection<GlobalResult> selectedResults,
Collection<GlobalResult> publishDataResults)
Extract directory to custom directory.
|
String |
performResultUpload(Collection<GlobalResult> selectedResults,
Collection<GlobalResult> indicatorsResults,
Collection<GlobalResult> mapResults,
Collection<GlobalResult> publishDataResults,
String login,
String password,
ProgressMonitor progress)
Upload user selected result to coser web front-end using common http
client.
|
protected CoserBusinessConfig config
protected ProjectService projectService
public ClientResultService(CoserBusinessConfig config)
public List<GlobalResult> findAllProjectWithResult(Date beginDate, Date endDate, boolean onlyPubliableResult) throws CoserBusinessException
beginDate
- begin date (can be null)endDate
- end date (can be null)onlyPubliableResult
- select only publiable resultsCoserBusinessException
public String performResultUpload(Collection<GlobalResult> selectedResults, Collection<GlobalResult> indicatorsResults, Collection<GlobalResult> mapResults, Collection<GlobalResult> publishDataResults, String login, String password, ProgressMonitor progress) throws CoserBusinessException
selectedResults
- selected result (collection of project/selection/rsufiresult)indicatorsResults
- results selected as indicator resultsmapResults
- results selected as map resultpublishDataResults
- results selected as results published with datalogin
- remote admin loginpassword
- remote admin passwordprogress
- progress monitornull
if no errorCoserBusinessException
protected Collection<GlobalResult> getEchoBaseResults(File existingProject, Date beginDate, Date endDate, boolean onlyPubliableResult)
protected Collection<GlobalResult> getRsufiResults(File existingProject, Date beginDate, Date endDate, boolean onlyPubliableResult)
protected boolean isCandidateResult(GlobalResult rsufiResult, Date beginDate, Date endDate, boolean onlyPubliableResult)
rsufiResult
- rsufi result to testbeginDate
- begin date (can be null)endDate
- end date (can be null)onlyPubliableResult
- select only publiable resultsprotected void modifyRSufiResults(Collection<GlobalResult> selectedResults, Collection<GlobalResult> indicatorsResults, Collection<GlobalResult> mapResults, Collection<GlobalResult> publishDataResults)
selectedResults
- selected result (collection of project/selection/rsufiresult)indicatorsResults
- results selected as indicator resultsmapResults
- map resultspublishDataResults
- publish data resultsprotected void checkDataCollision(Collection<GlobalResult> selectedResults)
selectedResults
- result id to checkpublic File performResultExtract(Collection<GlobalResult> selectedResults, Collection<GlobalResult> publishDataResults, File extractDirectory)
selectedResults
- selected result pathsextractDirectory
- extract directory (can be null)publishDataResults
- result paths flaged with results exportprotected void performResultExtractForRSufi(File extractDirectory, Collection<GlobalResult> selectedResults, Collection<GlobalResult> publishDataResults)
extractDirectory
- extract directoryselectedResults
- selected result pathspublishDataResults
- result paths flaged with results exportprotected void performResultExtractForEchoBase(File extractDirectory, Collection<GlobalResult> selectedResults, Collection<GlobalResult> publishDataResults)
selectedResults
- selected result pathspublishDataResults
- result paths flaged with results exportCopyright © 2010–2015 Ifremer. All rights reserved.