stella.parameter
Class FlatMatch

java.lang.Object
  extended by util.PropertyContainer
      extended by util.PropertyResources
          extended by util.PropertyBundles
              extended by stella.parameter.AbstractParameter
                  extended by stella.parameter.AbstractTrigger
                      extended by stella.parameter.SimpleTrigger
                          extended by stella.parameter.FlatMatch
All Implemented Interfaces:
Cloneable, Parameter, ParameterDepending, TargetDepending, TargetDependingParameter, Trigger, ExitCleaning, Initializable, LocalizedSupplying, PropertySupplying, Reloadable, ResourceSupplying

public class FlatMatch
extends SimpleTrigger
implements ParameterDepending, TargetDependingParameter

This trigger is true only when the currently requested flat group, as defined by the FlatGroup parameter matches the flat group assigned to a sky flat field target. This trigger can then be used in a requires clause of a target selection. This trigger needs the flat group parameter and it is also target depending.


Nested Class Summary
 
Nested classes/interfaces inherited from class util.PropertyResources
PropertyResources.URLResource
 
Field Summary
private static String DEFGROUPID
          Default reference of the setup section that holds the flat group.
private static boolean DEFINITBOOLEAN
          Default value.
static String DEFNAME
          Default name of this parameter.
private  FlatGroup group
          The flat group parameter.
static String KEY_FLATGROUP
          The name of the parameter that is the filter group.
static String KEY_GROUPID
          The setup of the target that carries the flat group.
 
Fields inherited from class stella.parameter.SimpleTrigger
KEY_INITBOOLEAN
 
Fields inherited from class stella.parameter.AbstractParameter
KEY_FORMAT, KEY_NAME, KEY_PRESERVE, UNKNOWN
 
Fields inherited from class util.PropertyBundles
KEY_LOCALECOUNTRY, KEY_LOCALELANGUAGE, KEY_RESOURCEBUNDLES
 
Fields inherited from class util.PropertyResources
KEY_NOINITONCREATE, localurl, locate, POSTFIX_DIR, POSTFIX_EXT, POSTFIX_FILE, POSTFIX_LIST, POSTFIX_URL, urlset
 
Fields inherited from class util.PropertyContainer
KEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATOR
 
Fields inherited from interface util.PropertySupplying
CONFIG, KEY_CLASS
 
Fields inherited from interface util.ResourceSupplying
KEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOME
 
Constructor Summary
FlatMatch(Map<String,String> prop)
          Constructs a bew Flat match trigger, defaulting all properties.
 
Method Summary
private  boolean checkGroup(TargetDefinition td)
          Matches the target's flat group setup to the current requested flat group.
 String getFormattedFor(TargetDefinition td)
          Returns true, if the target's assigned flat group matches the requested one.
 Object getForTarget(TargetDefinition td)
          Returns true, if the target's assigned flat group matches the requested one.
 void registerParameter(Parameter p)
          Keeps the flat group parameter.
 void registerTarget(TargetDefinition td)
          Registers the target, setting the trigger value.
 
Methods inherited from class stella.parameter.SimpleTrigger
getLastToggleTime, getTrigger, init, rescanned, setTrigger
 
Methods inherited from class stella.parameter.AbstractTrigger
get, getElapsedToggleTime, isTrue, set, toggleTrigger
 
Methods inherited from class stella.parameter.AbstractParameter
createParameter, delivers, exit, getFormatted, getFormatted, getName, getPreserveFile, getString, getString, register, setName, toString
 
Methods inherited from class util.PropertyBundles
clone, getLocalized, getLocalized, getLocalizedString, getLocalizedString, loadResource
 
Methods inherited from class util.PropertyResources
createFrom, createFrom, createFrom, getApplet, getAsResources, getLocalClassLoader, getPropertiesToKey, getPropertiesToKey, getResource, getResourceAsStream, getResourceFromKey, getResources, keyCreate, keyCreate, reload, setApplet
 
Methods inherited from class util.PropertyContainer
augment, augment, augment, defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsEnums, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, isNew, parseObject, reload, removeProperty, setObject, setProperties, setProperty, stringProperties
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface stella.Parameter
get, getFormatted, getName, getString, set
 
Methods inherited from interface util.PropertySupplying
defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, parseObject, removeProperty, setObject, setProperty, stringProperties
 
Methods inherited from interface util.Initializable
init
 
Methods inherited from interface util.Reloadable
reload
 
Methods inherited from interface util.ResourceSupplying
getResource, getResourceAsStream, getResources
 

Field Detail

KEY_FLATGROUP

public static final String KEY_FLATGROUP
The name of the parameter that is the filter group.

See Also:
Constant Field Values

KEY_GROUPID

public static final String KEY_GROUPID
The setup of the target that carries the flat group.

See Also:
Constant Field Values

DEFNAME

public static final String DEFNAME
Default name of this parameter.

See Also:
Constant Field Values

DEFGROUPID

private static final String DEFGROUPID
Default reference of the setup section that holds the flat group.

See Also:
Constant Field Values

DEFINITBOOLEAN

private static final boolean DEFINITBOOLEAN
Default value.

See Also:
Constant Field Values

group

private FlatGroup group
The flat group parameter.

Constructor Detail

FlatMatch

public FlatMatch(Map<String,String> prop)
Constructs a bew Flat match trigger, defaulting all properties.

Method Detail

registerParameter

public void registerParameter(Parameter p)
Keeps the flat group parameter.

Specified by:
registerParameter in interface ParameterDepending

registerTarget

public void registerTarget(TargetDefinition td)
Registers the target, setting the trigger value.

Specified by:
registerTarget in interface TargetDepending

getForTarget

public Object getForTarget(TargetDefinition td)
Returns true, if the target's assigned flat group matches the requested one. Returns false in any other case.

Specified by:
getForTarget in interface TargetDependingParameter

getFormattedFor

public String getFormattedFor(TargetDefinition td)
Returns true, if the target's assigned flat group matches the requested one. Returns false in any other case.

Specified by:
getFormattedFor in interface TargetDependingParameter

checkGroup

private boolean checkGroup(TargetDefinition td)
Matches the target's flat group setup to the current requested flat group.