|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectutil.PropertyContainer
util.PropertyResources
util.PropertyBundles
jview.UserDrivenFitting
public class UserDrivenFitting
A small class that handles user clicks in an extrema-selectable canvas and
converts them to initial conditions or constant selection of a model
fitter. It bridges the gap for models that can not be automatically fitted,
i.e. that need user input for pre-selecting a starting range of a parameter.
It is used in Fourier applications, where the user selects a frequency out
of a periodogramm, which is than funneld to an orbit solver or a multiple
frequency fit to the data. The result of this fitting is normally displayed
in a JFitResidualFrame or JFitResidualDisplay, which
should register as property change listener to this component. A
non-null KEY_LISTENERFRAME can be used to construct an
individual model handler (a JFitResidualFrame) for this class. As
usual, such a attached frame can be retrieved with
PropertyContainer.getAsObject(java.lang.String), using #ATTACHED
| Nested Class Summary | |
|---|---|
static class |
UserDrivenFitting.PeriodError
|
static class |
UserDrivenFitting.PeriodExtrema
|
| Nested classes/interfaces inherited from class util.PropertyResources |
|---|
PropertyResources.URLResource |
| Field Summary | |
|---|---|
private Multidimensional |
error
The function to calculate a model parameter error from the extrema. |
private Multidimensional |
func
The function to calculate a model parameter from the extrema select. |
static String |
KEY_EXTREMAERROR
How to transfer the selected extrema to a model variable. |
static String |
KEY_EXTREMAFUNCTION
How to transfer the selected extrema to a model variable. |
static String |
KEY_EXTREMANAME
How to transfer the selected extrema to a model variable. |
static String |
KEY_EXTREMAUNIT
How to transfer the selected extrema to a model variable. |
static String |
KEY_LISTENERFRAME
The key to an individual listener frame. |
private ModelFitting |
model
The model fitter used to calculate new fits. |
static String |
MODELPARAMETER
Property to listen to for model soultion changes. |
static String |
MODELSOLUTION
Property to listen to for model soultion changes. |
private PropertyChangeSupport |
pipe
Used for property change events. |
| 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.BeanSupport |
|---|
CASTING |
| Fields inherited from interface util.ResourceSupplying |
|---|
KEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOME |
| Fields inherited from interface util.PropertySupplying |
|---|
CONFIG, KEY_CLASS |
| Constructor Summary | |
|---|---|
UserDrivenFitting(Map<String,String> pp)
We can handle extremal selects only if we have at least the parameter name that is going to be selected. |
|
| Method Summary | |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener pcl)
Adds, if new, this property change listeners. |
void |
addPropertyChangeListener(String p,
PropertyChangeListener pcl)
Adds, if new, this property change listeners. |
void |
init()
We initalize our extram converting function. |
boolean |
isInterested(String in)
We are interested in the model fitter, the model data and the extrema. |
void |
propertyChange(PropertyChangeEvent pce)
If we receive a property change event that the fitdisplay is interested in, we pass it along. |
void |
removePropertyChangeListener(PropertyChangeListener pcl)
Removes this property change listeners. |
void |
removePropertyChangeListener(String p,
PropertyChangeListener pcl)
Removes this property change listeners. |
private void |
select(Vector3D parabola)
The user selected an extremum. |
| 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, rescanned, setObject, setProperties, setProperty, stringProperties, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface util.ResourceSupplying |
|---|
getResource, getResourceAsStream, getResources |
| 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 |
| Field Detail |
|---|
public static final String MODELSOLUTION
public static final String MODELPARAMETER
public static final String KEY_LISTENERFRAME
public static final String KEY_EXTREMANAME
public static final String KEY_EXTREMAFUNCTION
public static final String KEY_EXTREMAERROR
public static final String KEY_EXTREMAUNIT
private PropertyChangeSupport pipe
private Multidimensional func
private Multidimensional error
private ModelFitting model
| Constructor Detail |
|---|
public UserDrivenFitting(Map<String,String> pp)
| Method Detail |
|---|
public void init()
init in interface Initializableinit in class PropertyResourcespublic boolean isInterested(String in)
isInterested in interface EclecticPropertyListenerin - The property name to query.
public void propertyChange(PropertyChangeEvent pce)
MODELFITTER properties and we do a fit on
EXTREMASELECT.
propertyChange in interface PropertyChangeListenerprivate void select(Vector3D parabola)
Variable
using our multidimensional transfer functions func and
error, together with the name of the variable
KEY_EXTREMANAME and possibly its unit
KEY_EXTREMAUNIT. If this variable is a constant to the model,
we generate a parameter changed event and pass that along to possible
listeners. If the variable is an initial condition, we fit the
entire model and pass a model solution event.
public void addPropertyChangeListener(PropertyChangeListener pcl)
addPropertyChangeListener in interface BeanSupport
public void addPropertyChangeListener(String p,
PropertyChangeListener pcl)
addPropertyChangeListener in interface BeanSupportpublic void removePropertyChangeListener(PropertyChangeListener pcl)
removePropertyChangeListener in interface BeanSupport
public void removePropertyChangeListener(String p,
PropertyChangeListener pcl)
removePropertyChangeListener in interface BeanSupport
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||