Changeset 10093


Ignore:
Timestamp:
2005-06-14T16:40:02+12:00 (19 years ago)
Author:
kjdon
Message:

The ServiceRack class's configure method is no longer abstract so all the
subclasses should call super.configure.

Location:
trunk/gsdl3/src/java/org/greenstone/gsdl3/service
Files:
22 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/AbstractBrowse.java

    r9280 r10093  
    7575    public boolean configure(Element info, Element extra_info)
    7676    {
     77    if (!super.configure(info, extra_info)){
     78        return false;
     79    }
     80
    7781    System.out.println("Configuring AbstractBrowse...");
    7882    this.config_info = info;
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/AbstractDocumentRetrieve.java

    r9874 r10093  
    8888    public boolean configure(Element info, Element extra_info)
    8989    {
     90    if (!super.configure(info, extra_info)){
     91        return false;
     92    }
     93
    9094    System.out.println("Configuring AbstractDocumentRetrieve...");
    9195    this.config_info = info;
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/AbstractGS2DocumentRetrieve.java

    r9874 r10093  
    7474    public boolean configure(Element info, Element extra_info)
    7575    {
    76    
     76    if (!super.configure(info, extra_info)){
     77        return false;
     78    }
     79
    7780    System.out.println("Configuring AbstractGS2DocumentRetrieve...");
    7881    //this.config_info = info;
     
    9497        this.index_stem = this.cluster_name;
    9598    }
    96 
    97 
    98     return super.configure(info, extra_info);
    99 
     99    return true;
    100100    }
    101101
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/AbstractGS3DocumentRetrieve.java

    r9874 r10093  
    7272    public boolean configure(Element info, Element extra_info)
    7373    {
    74    
     74    if (!super.configure(info, extra_info)){
     75        return false;
     76    }
     77
    7578    System.out.println("Configuring AbstractGS3DocumentRetrieve...");
    7679
     
    104107    }
    105108
    106     return super.configure(info, extra_info);
     109    return true;
    107110
    108111    }
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/AbstractSearch.java

    r9902 r10093  
    8787    public boolean configure(Element info, Element extra_info)
    8888    {
     89    if (!super.configure(info, extra_info)){
     90        return false;
     91    }
     92
    8993    System.out.println("Configuring AbstractSearch...");
    9094   
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2Browse.java

    r9874 r10093  
    6363    public boolean configure(Element info, Element extra_info)
    6464    {
     65    if (!super.configure(info, extra_info)){
     66        return false;
     67    }
     68
    6569    System.err.println("Configuring GS2Browse...");
    6670    // Open GDBM database for querying
     
    7074        return false;
    7175    }
    72     return super.configure(info, extra_info);
     76    return true;
    7377    }
    7478
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2Construct.java

    r8955 r10093  
    326326     */
    327327    public boolean configure(Element info, Element extra_info) {
     328    if (!super.configure(info, extra_info)){
     329        return false;
     330    }
     331
    328332    System.out.println("configuring GS2Construct");
    329333
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2MGPPRetrieve.java

    r9874 r10093  
    5858    public boolean configure(Element info, Element extra_info)
    5959    {
     60    if (!super.configure(info, extra_info)){
     61        return false;
     62    }
     63
    6064    // Do specific configuration
    6165    System.out.println("Configuring GS2MGPPRetrieve...");
     
    7781
    7882    // Do generic configuration
    79     return super.configure(info, extra_info);
     83    return true;
    8084 
    8185    }
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2MGPPSearch.java

    r9874 r10093  
    5252    public boolean configure(Element info, Element extra_info)
    5353    {
     54    if (!super.configure(info, extra_info)){
     55        return false;
     56    }
    5457
    5558        // Open GDBM database for querying
     
    5962        return false;
    6063    }
    61     return super.configure(info, extra_info);
     64    return true;
    6265    }
    6366    /** returns the document type of the doc that the specified node
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2MGRetrieve.java

    r9874 r10093  
    5555    public boolean configure(Element info, Element extra_info)
    5656    {
     57    if (!super.configure(info, extra_info)){
     58        return false;
     59    }
     60   
    5761    // Do specific configuration
    5862    System.out.println("Configuring GS2MGRetrieve...");
     
    7882    this.mg_src.setIndex(indexpath);
    7983
    80     // Do generic configuration
    81     return super.configure(info, extra_info);
     84    return true;
    8285    }
    8386   
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS2MGSearch.java

    r9874 r10093  
    5151    public boolean configure(Element info, Element extra_info)
    5252    {
     53    if (!super.configure(info, extra_info)){
     54        return false;
     55    }
    5356
    5457        // Open GDBM database for querying
     
    5861        return false;
    5962    }
    60     return super.configure(info, extra_info);
     63    return true;
    6164    }
    6265    /** returns the document type of the doc that the specified node
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS3Browse.java

    r9874 r10093  
    5959    public boolean configure(Element info, Element extra_info)
    6060    {
     61    if (!super.configure(info, extra_info)){
     62        return false;
     63    }
     64
    6165    System.err.println("Configuring GS3Browse...");
    6266   
     
    7983    }
    8084   
    81     // generic configure
    82     return super.configure(info, extra_info);
     85    return true;
    8386    }
    8487
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS3MGPPSearch.java

    r9874 r10093  
    6060    public boolean configure(Element info, Element extra_info)
    6161    {
    62    
     62    if (!super.configure(info, extra_info)){
     63        return false;
     64    }
     65
    6366    // get the base prefix
    6467    Element def = (Element) GSXML.getChildByTagName(info, "baseIndexPrefix");
     
    8083    }
    8184
    82     return super.configure(info, extra_info);
     85    return true;
    8386    }
    8487    /** returns the document type of the doc that the specified node
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/GS3MGSearch.java

    r9874 r10093  
    6060    public boolean configure(Element info, Element extra_info)
    6161    {
    62    
     62    if (!super.configure(info, extra_info)){
     63        return false;
     64    }
     65
    6366    // get the base prefix
    6467    Element def = (Element) GSXML.getChildByTagName(info, "baseIndexPrefix");
     
    8083    }
    8184
    82     return super.configure(info, extra_info);
     85    return true;
    8386    }
    8487    /** returns the document type of the doc that the specified node
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/IViaProxy.java

    r9874 r10093  
    4848    public boolean configure(Element info, Element extra_info) {
    4949   
     50    if (!super.configure(info, extra_info)){
     51        return false;
     52    }
     53
    5054    Element server_elem = (Element)GSXML.getChildByTagName(info, "iViaServer");
    5155    if (server_elem == null) {
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/IViaSearch.java

    r9902 r10093  
    3939    public boolean configure(Element info, Element extra_info)
    4040    {
     41    if (!super.configure(info, extra_info)){
     42        return false;
     43    }
     44
    4145    Element server_elem = (Element)GSXML.getChildByTagName(info, "iViaServer");
    4246    if (server_elem == null) {
     
    5256    does_multi_index_search = true;
    5357    this.default_index = ",kw,au,su,ti,de,fu,"; // all of them
    54     return super.configure(info, extra_info);
     58    return true;
    5559    }
    5660   
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/MapRetrieve.java

    r9874 r10093  
    5555    public boolean configure(Element info, Element extra_info)
    5656    {
     57    if (!super.configure(info, extra_info)){
     58        return false;
     59    }
     60
    5761    System.out.println("Configuring MapRetrieve...");
    5862    this.config_info = info;
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/PhindPhraseBrowse.java

    r10065 r10093  
    6969    public boolean configure(Element info, Element extra_info) {
    7070
     71    if (!super.configure(info, extra_info)){
     72        return false;
     73    }
     74
    7175    System.out.println("configuring PhindPhraseBrowse");
    7276
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/ServiceRack.java

    r10088 r10093  
    135135     */
    136136    public boolean configure(Element info) {
     137    return configure(info, null);
     138    }
     139   
     140    public boolean configure(Element info, Element extra_info) {
    137141    // set up the class loader
    138142    this.class_loader = new CollectionClassLoader(this.getClass().getClassLoader(), this.site_home, this.cluster_name);
    139    
    140     return configure(info, null);
    141     }
    142    
    143     abstract public boolean configure(Element info, Element extra_info);
     143    return true;
     144    }
    144145
    145146    /**
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/Visualizer.java

    r9874 r10093  
    5555    public boolean configure(Element info, Element extra_info)
    5656    {
     57    if (!super.configure(info, extra_info)){
     58        return false;
     59    }
     60
    5761    Element e = this.doc.createElement(GSXML.SERVICE_ELEM);
    5862    e.setAttribute(GSXML.TYPE_ATT, GSXML.SERVICE_TYPE_APPLET);
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/XMLRetrieve.java

    r10089 r10093  
    3838
    3939    public boolean configure(Element info, Element extra_info) {
    40    
     40    if (!super.configure(info, extra_info)){
     41        return false;
     42    }
    4143    System.out.println("configuring XMLRetrieve...");
    4244    // look for the parameters
  • trunk/gsdl3/src/java/org/greenstone/gsdl3/service/XSLTServices.java

    r6273 r10093  
    102102    /** configure this service */
    103103    public boolean configure(Element info, Element extra_info) {
    104      
     104        if (!super.configure(info, extra_info)){
     105        return false;
     106    }
     107
    105108      System.out.println("configuring XSLTServices");
    106109      this.config_info = info;
Note: See TracChangeset for help on using the changeset viewer.