org.gcube.application.framework.search.library.impl
Class SearchHelper

java.lang.Object
  extended by org.gcube.application.framework.search.library.impl.SearchHelper
All Implemented Interfaces:
SearchInfoI

public class SearchHelper
extends Object
implements SearchInfoI

Author:
rena - NKUA

Field Summary
static DocumentBuilderFactory dfactory
          Document factory instance
 
Constructor Summary
SearchHelper(org.gcube.application.framework.core.session.ASLSession session)
           
SearchHelper(String username, String extSessionID)
           
 
Method Summary
 int addQuery(QueryGroup query)
          
 int createQuery(int qid, boolean... previous)
          
 CollectionInfo findCollectionInfo(String collectionId)
           
 QueryGroup getActiveQueryGroup()
           
 int getActiveQueryGroupNo()
          
 List<QueryGroup> getAllQueries()
          
 HashMap<CollectionInfo,ArrayList<CollectionInfo>> getAvailableCollections()
          
 ArrayList<CollectionInfo> getExternalCollectionInfos()
           
 ArrayList<String> getExternalCollections()
           
 int getNumberOfQueryGroups()
          
 QueryGroup getQuery(int qid)
          
 HashMap<CollectionInfo,ArrayList<CollectionInfo>> refreshAvailableCollections()
          
 void removeQuery(int qid)
          
 List<CollectionInfo> searchCollections(String term, String whereToSearch)
          
 void setActiveQueryGroup(int i)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dfactory

public static final DocumentBuilderFactory dfactory
Document factory instance

Constructor Detail

SearchHelper

public SearchHelper(String username,
                    String extSessionID)
Parameters:
username - the username of the user that makes the request
extSessionID - the external session ID. In case of a web aplication using ASL, this is the http session ID

SearchHelper

public SearchHelper(org.gcube.application.framework.core.session.ASLSession session)
Parameters:
session -
Method Detail

getAllQueries

public List<QueryGroup> getAllQueries()


getAvailableCollections

public HashMap<CollectionInfo,ArrayList<CollectionInfo>> getAvailableCollections()
                                                                          throws InitialBridgingNotCompleteException,
                                                                                 InternalErrorException

Throws:
InitialBridgingNotCompleteException
InternalErrorException

getExternalCollections

public ArrayList<String> getExternalCollections()
                                         throws InitialBridgingNotCompleteException,
                                                InternalErrorException
Throws:
InitialBridgingNotCompleteException
InternalErrorException

getExternalCollectionInfos

public ArrayList<CollectionInfo> getExternalCollectionInfos()
                                                     throws InitialBridgingNotCompleteException,
                                                            InternalErrorException
Throws:
InitialBridgingNotCompleteException
InternalErrorException

getQuery

public QueryGroup getQuery(int qid)


addQuery

public int addQuery(QueryGroup query)


removeQuery

public void removeQuery(int qid)


createQuery

public int createQuery(int qid,
                       boolean... previous)


getNumberOfQueryGroups

public int getNumberOfQueryGroups()


getActiveQueryGroup

public QueryGroup getActiveQueryGroup()

getActiveQueryGroupNo

public int getActiveQueryGroupNo()


setActiveQueryGroup

public void setActiveQueryGroup(int i)


refreshAvailableCollections

public HashMap<CollectionInfo,ArrayList<CollectionInfo>> refreshAvailableCollections()
                                                                              throws InitialBridgingNotCompleteException,
                                                                                     InternalErrorException

Throws:
InitialBridgingNotCompleteException
InternalErrorException

findCollectionInfo

public CollectionInfo findCollectionInfo(String collectionId)
                                  throws InitialBridgingNotCompleteException,
                                         InternalErrorException
Throws:
InitialBridgingNotCompleteException
InternalErrorException

searchCollections

public List<CollectionInfo> searchCollections(String term,
                                              String whereToSearch)
                                       throws InitialBridgingNotCompleteException,
                                              InternalErrorException

Throws:
InitialBridgingNotCompleteException
InternalErrorException


Copyright © 2013. All Rights Reserved.