jetweb is hosted by Hepforge, IPPP Durham

cedar.jetweb.model
Class ResultSearchPattern

java.lang.Object
  extended by cedar.jetweb.model.ResultSearchPattern
All Implemented Interfaces:
java.lang.Cloneable
Direct Known Subclasses:
Model, RunSeries

public class ResultSearchPattern
extends java.lang.Object
implements java.lang.Cloneable

Container a general set of generators and parameters. May be used to search for models and logs of jobs. This search facility includes the ability to specify a list of some of the parameters; generator, version, photonPDF and protonPDF as well as a MCProcessType (which specifies the beams etc)

Version:
$Date: 2006-06-19 13:15:40 +0100 (Mon, 19 Jun 2006) $ $Revision: 1189 $
Author:
Jon Butterworth
See Also:
getGenerator(int), getPhotonPDF(int), getProtonPDF(int)

Field Summary
protected  java.util.Vector<Generator> generatorList
          List of generators.
protected  java.util.Vector<Match> notMatching
          Vector of Match objects - contains differences between this pattern and another.
protected  java.util.Vector<PDF> photonpdfList
          List of Photon Particle Density Functions
protected  java.util.Vector<PDF> protonpdfList
          List of Proton Particle Density Functions
 
Constructor Summary
ResultSearchPattern()
          Builds a completely general result search pattern - matches all parameters
 
Method Summary
 java.lang.Object clone()
           
 void dumpParms()
          Writes all the parameters to standard output.
 java.util.Vector<Model> getConsistentModels()
          Return all models consistent with this pattern.
 Generator getGenerator()
          Gets a generator
 Generator getGenerator(int i)
          Gets a generator
 java.util.Vector<Generator> getGeneratorList()
          Gets list of generators
 java.util.Enumeration<Match> getNonMatchingParameters()
          Returns enumeration of Match objects - results of matching this pattern with another
 java.lang.String getParms()
          Writes all the parameters to a String.
 PDF getPhotonPDF()
          Gets photon particle density function
 PDF getPhotonPDF(int i)
          Gets photon particle density function
 java.util.Vector<PDF> getPhotonPDFList()
          Gets a list of photon particle density functions
 PDF getProtonPDF()
          Gets proton particle density function
 PDF getProtonPDF(int i)
          Gets proton particle density function
 java.util.Vector<PDF> getProtonPDFList()
          Gets a list of proton particle density functions
 java.lang.Double getPthat()
          Gets PTHAT, the cutoff which seperates hard from soft scatters.
 boolean matches(Model model)
          Checks whether this pattern is consistent with a Model.
 boolean matches(ResultSearchPattern pattern)
          Checks whether this pattern is consistent with a ResultSearchPattern.
 boolean matches(RunSeries runSeries)
          Checks whether this pattern is consistent with a runseries.
 void setDefaults()
          Set all parameters to their default values.
 void setGenerator(Generator gen)
          Clear the list, then add the input Generator to it.
 void setSoftDefaults()
          Set any parameters which are not set to their default values.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

generatorList

protected java.util.Vector<Generator> generatorList
List of generators.


protonpdfList

protected java.util.Vector<PDF> protonpdfList
List of Proton Particle Density Functions


photonpdfList

protected java.util.Vector<PDF> photonpdfList
List of Photon Particle Density Functions


notMatching

protected java.util.Vector<Match> notMatching
Vector of Match objects - contains differences between this pattern and another.

Constructor Detail

ResultSearchPattern

public ResultSearchPattern()
Builds a completely general result search pattern - matches all parameters

Method Detail

getNonMatchingParameters

public java.util.Enumeration<Match> getNonMatchingParameters()
Returns enumeration of Match objects - results of matching this pattern with another


getProtonPDFList

public java.util.Vector<PDF> getProtonPDFList()
Gets a list of proton particle density functions

Returns:
vector of PDF names (Strings)


getProtonPDF

public PDF getProtonPDF(int i)
                 throws JetWebException
Gets proton particle density function

Returns:
protonPDF
Throws:
JetWebException


getProtonPDF

public PDF getProtonPDF()
                 throws JetWebException
Gets proton particle density function

Returns:
protonPDF
Throws:
JetWebException


getPhotonPDFList

public java.util.Vector<PDF> getPhotonPDFList()
Gets a list of photon particle density functions

Returns:
vector of PDFs


getPhotonPDF

public PDF getPhotonPDF(int i)
                 throws JetWebException
Gets photon particle density function

Returns:
photonPDF
Throws:
JetWebException


getPhotonPDF

public PDF getPhotonPDF()
                 throws JetWebException
Gets photon particle density function

Returns:
photonPDF
Throws:
JetWebException


getGeneratorList

public java.util.Vector<Generator> getGeneratorList()
Gets list of generators

Returns:
vector of generator names (Strings)


getGenerator

public Generator getGenerator(int i)
                       throws JetWebException
Gets a generator

Returns:
generator name (String)
Throws:
JetWebException


setGenerator

public void setGenerator(Generator gen)
Clear the list, then add the input Generator to it.


getGenerator

public Generator getGenerator()
                       throws JetWebException
Gets a generator

Returns:
generator
Throws:
JetWebException


getPthat

public java.lang.Double getPthat()
                          throws JetWebException
Gets PTHAT, the cutoff which seperates hard from soft scatters. In general this corresponds to a different parameter in each different generator, and should be provided by the generator class eventually. If its worth it... yes it is needed for the plotswitches.

Returns:
pthat
Throws:
JetWebException


clone

public java.lang.Object clone()
Overrides:
clone in class java.lang.Object

matches

public boolean matches(RunSeries runSeries)
                throws JetWebException
Checks whether this pattern is consistent with a runseries. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.

Parameters:
runSeries - to be compared with this pattern
Returns:
true if it matches, otherwise false
Throws:
JetWebException
See Also:
RunSeries


matches

public boolean matches(Model model)
                throws JetWebException
Checks whether this pattern is consistent with a Model. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.

Parameters:
model - to be compared with this pattern
Returns:
true if it matches, otherwise false
Throws:
JetWebException
See Also:
Model


matches

public boolean matches(ResultSearchPattern pattern)
                throws JetWebException
Checks whether this pattern is consistent with a ResultSearchPattern. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.

Parameters:
pattern - to be compared with this pattern
Returns:
true if it matches, otherwise false
Throws:
JetWebException


dumpParms

public void dumpParms()
Writes all the parameters to standard output.


getParms

public java.lang.String getParms()
Writes all the parameters to a String.

Returns:
parameter String


setSoftDefaults

public void setSoftDefaults()
                     throws JetWebException
Set any parameters which are not set to their default values.

Throws:
JetWebException


setDefaults

public void setDefaults()
                 throws JetWebException
Set all parameters to their default values.

Throws:
JetWebException


getConsistentModels

public java.util.Vector<Model> getConsistentModels()
                                            throws JetWebException
Return all models consistent with this pattern.

Throws:
JetWebException