Class SearchController

All Implemented Interfaces:
PComponentController, PControllerBean, PropertyChangeListener, Serializable, Remote, Unreferenced, EventListener

public class SearchController extends PIAPanelController
A Template Based search front-end for Portal. This is a front end for the Portal search engine that trys to hide the details of storable classes from the user. Instead, users supply data in form-lets oriented to specific sources they might wish to search from, and designed to search for specific storable classes determined by their creator. These form-lets are created by interpreting a set of properties passed to the front-end. These properties also contain the information needed to form the proper search strings for Portal. Search results are passed back to the caller via the search event/listener mechanism, in batches.
Version:
%version: 19 % %date_modified: Tue May 28 10:23:18 2002 %
Author:
Monica Gaines
See Also:
  • Constructor Details

  • Method Details

    • getSearchData

      public String[] getSearchData()
      Get the 'searchData' property array. This is a collection of the data set by the user for each template.
      Returns:
      A string array with each string containing the information for a single template.
    • setSearchData

      public void setSearchData(String[] data)
      Set the 'searchData' property array. This will be used to pre-load templates with the given information.
      Parameters:
      data - A String array containing data for each template.
    • setResultFields

      public void setResultFields(FList flds)
      Set the 'resultFields' property, which is used in the search.
      Parameters:
      flds - the new list of fields expected for each found result
    • actionPerformed

      public Object actionPerformed(ActionEvent event) throws RemoteException
      Initiates a search using data provided by the client through the event or obtains data neccessay for displaying a generic search.
      Specified by:
      actionPerformed in interface PComponentController
      Overrides:
      actionPerformed in class PIAPanelController
      Parameters:
      event - issued by the client to begin the search
      Returns:
      An object may be returned as a result of action processing.
      Throws:
      RemoteException - thrown for errors
    • fireProgress

      protected void fireProgress(int amt) throws RemoteException
      Sends a DataChangeEvent indicating the amount of progress of the search.
      Parameters:
      amt - the number of items found in search
      Throws:
      RemoteException
    • fireResults

      protected void fireResults(PModelHandle[] res) throws RemoteException
      Throws:
      RemoteException
    • fireLabels

      protected void fireLabels(ResultData[] res) throws RemoteException
      Throws:
      RemoteException
    • fireSearchEvent

      protected void fireSearchEvent(SearchEvent event)
    • fireError

      protected void fireError() throws RemoteException
      Throws:
      RemoteException
    • handleDistributeToListener

      protected void handleDistributeToListener(Object l, EventObject evt)
      Description copied from class: PControllerImpl
      Called by distributeEventToListeners to pass an event to specific listener methods. When overriding this method, be sure to pass calls for unknown listener classes to the parent controller to handle other types of event objects.
      Overrides:
      handleDistributeToListener in class PControllerImpl
      Parameters:
      l - the listener to call a method for
      evt - the event object to distribute