uk.ac.essex.ia.media
Class OperatorHelper

java.lang.Object
  extended by uk.ac.essex.ia.media.OperatorHelper

public class OperatorHelper
extends java.lang.Object



You should have received a copy of GNU public license with this code. If not please visit this site


Constructor Summary
OperatorHelper()
           
 
Method Summary
static void checkParameters(java.lang.Class<? extends Operator> operatorClass, java.awt.image.renderable.ParameterBlock parameters, java.lang.Class... expectedClassOfParams)
           
static void checkSources(java.lang.Class<? extends Operator> operatorClass, java.awt.image.renderable.ParameterBlock parameters, int numberOfReqSources)
          Checks the parameter block for a given number of sources, the source vector is also checked to see if the the objects stored are instances of RenderedImages.
static void throwInvalidParameters()
          This is used to indicate an operator has invalid parameters.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OperatorHelper

public OperatorHelper()
Method Detail

checkParameters

public static void checkParameters(java.lang.Class<? extends Operator> operatorClass,
                                   java.awt.image.renderable.ParameterBlock parameters,
                                   java.lang.Class... expectedClassOfParams)
                            throws InvalidParameterException
Throws:
InvalidParameterException

checkSources

public static void checkSources(java.lang.Class<? extends Operator> operatorClass,
                                java.awt.image.renderable.ParameterBlock parameters,
                                int numberOfReqSources)
                         throws java.lang.Exception
Checks the parameter block for a given number of sources, the source vector is also checked to see if the the objects stored are instances of RenderedImages.

Parameters:
operatorClass -
parameters -
numberOfReqSources - - The number of required sources
Throws:
java.lang.Exception

throwInvalidParameters

public static void throwInvalidParameters()
                                   throws InvalidParameterException
This is used to indicate an operator has invalid parameters. For now this method simply throws an exception. The message contains a translated string.

Throws:
InvalidParameterException