Changeset 745


Ignore:
Timestamp:
Aug 26, 2008, 4:37:45 PM (13 years ago)
Author:
Martin Svensson
Message:

References #117 Bug-fixing

Location:
plugins/base2/net.sf.basedb.normalizers/trunk/src/net/sf/basedb/plugins
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • plugins/base2/net.sf.basedb.normalizers/trunk/src/net/sf/basedb/plugins/AbstractNormalizationPlugin.java

    r742 r745  
    6363    Expression used to get data from channel 2
    6464   */
    65   protected Expression ch2 = Dynamic.column(VirtualColumn.channel(1)); 
     65  protected Expression ch2 = Dynamic.column(VirtualColumn.channel(2)); 
    6666 
    6767  /**
  • plugins/base2/net.sf.basedb.normalizers/trunk/src/net/sf/basedb/plugins/AverageNormalization.java

    r744 r745  
    5353import net.sf.basedb.core.query.Expression;
    5454import net.sf.basedb.core.query.Expressions;
    55 import net.sf.basedb.core.query.Restriction;
    56 import net.sf.basedb.core.query.Restrictions;
    5755import net.sf.basedb.core.query.Selects;
    5856import net.sf.basedb.core.query.SqlResult;
     
    10098      "Use global average intensity",
    10199      "Select if the global average intensity or an user defined value should be used as a reference value\n" +
    102       noOption + " = User defined value(defalut)\n" +
     100      noOption + " = User defined value(default)\n" +
    103101      yesOption + " = Global average intensity",
    104       new StringParameterType(null, noOption, true, 0, 0, 0, Arrays.asList(new String[] {noOption, yesOption}))
     102      new StringParameterType(null, noOption, true, 1, 0, 0, Arrays.asList(new String[] {noOption, yesOption}))
    105103    );
    106104 
     
    166164        storeValue(job, request, ri.getParameter(CHILD_NAME));
    167165        storeValue(job, request, ri.getParameter(CHILD_DESCRIPTION));       
    168         storeValue(job, request, ri.getParameter("useGlobalAverageIntensity"));
     166        storeValue(job, request, ri.getParameter("useGlobalAvgInt"));
    169167       
    170168        // Reference value cannot be null if the global average intensity shouldn't be used.
    171         if (noOption.equals((String)request.getParameterValue("useGlobalAverageIntensity")) )
     169        String useGlobal = (String)request.getParameterValue("useGlobalAvgInt");
     170        if (noOption.equals(useGlobal) )
    172171        {
    173172          if (request.getParameterValue("referenceValue") != null)
     
    177176          else
    178177          {
    179             throw new InvalidUseOfNullException("referenceValue");
     178            throw new InvalidUseOfNullException("Reference value");
    180179          }
    181180        }
     
    217216    return about;
    218217  }
    219 
     218  @Override
     219  public boolean supportsConfigurations()
     220  {
     221    return false;
     222  }
     223  @Override
     224  public boolean requiresConfiguration()
     225  {
     226    return false;
     227  }
     228 
    220229  @Override
    221230  public void run(Request request, Response response, ProgressReporter progress)
     
    237246        Job currentJob = this.getCurrentJob(dc);
    238247       
    239         boolean useGlobalAvgInt = yesOption.equals((String)job.getValue("useGlobalAverageIntensity"));
     248        boolean useGlobalAvgInt = yesOption.equals((String)job.getValue("useGlobalAvgInt"));
    240249        float refValue = 0;
    241250       
     
    283292    try
    284293    {
     294      dc = sc.newDbControl();
    285295      if (configureJob == null)
    286296      {
Note: See TracChangeset for help on using the changeset viewer.