com.mindtree.techworks.insight.preferences.model
Interface PreferenceModelManager

All Known Implementing Classes:
PreferenceManager

public interface PreferenceModelManager

To be used by the Preference and Preference Attributes to notify the manager of a change of value. The manager may then notify all interested parties about the change in value.

Version:
$Revision: 27 $ $Date: 2007-12-16 04:58:03 -0700 (Sun, 16 Dec 2007) $
Author:
Bindul Bhowmik

Field Summary
static int OPERATION_CHILD_PREF_ADDED
          Operation to identify addition of a child preference
static int OPERATION_CHILD_PREF_REMOVED
          Operation to identify removal of a child preference
static int OPERATION_PREF_ATTR_ADDED
          Operation to identify addition of a child preference
static int OPERATION_PREF_ATTR_REMOVED
          Operation to identify removal of a child preference
 
Method Summary
 void attributeValueChanged(java.lang.String preferenceId, java.lang.String attributeId, java.lang.String newValue)
          Used by the Preference to notify the manager about a change in an attribute value.
 void childPreferenceChanged(java.lang.String preferenceId, java.lang.String childPreferenceId, int operation)
          This method is called on the Preference Model Manager by the Preference, whenever a child preference is added or deleted.
 void preferenceAttributeChanged(java.lang.String preferenceId, java.lang.String preferenceAttributeId, int operation)
          This method is called on the Preference Model Manager by the Preference, whenever a child preference is added or deleted.
 

Field Detail

OPERATION_CHILD_PREF_ADDED

static final int OPERATION_CHILD_PREF_ADDED
Operation to identify addition of a child preference

See Also:
Constant Field Values

OPERATION_CHILD_PREF_REMOVED

static final int OPERATION_CHILD_PREF_REMOVED
Operation to identify removal of a child preference

See Also:
Constant Field Values

OPERATION_PREF_ATTR_ADDED

static final int OPERATION_PREF_ATTR_ADDED
Operation to identify addition of a child preference

See Also:
Constant Field Values

OPERATION_PREF_ATTR_REMOVED

static final int OPERATION_PREF_ATTR_REMOVED
Operation to identify removal of a child preference

See Also:
Constant Field Values
Method Detail

attributeValueChanged

void attributeValueChanged(java.lang.String preferenceId,
                           java.lang.String attributeId,
                           java.lang.String newValue)
Used by the Preference to notify the manager about a change in an attribute value. Notification is always done with the Complete Idof the Preference.

Parameters:
preferenceId - The Preference in which the value changed
attributeId - The Attribute whose value changed
newValue - The new value of the attribute

childPreferenceChanged

void childPreferenceChanged(java.lang.String preferenceId,
                            java.lang.String childPreferenceId,
                            int operation)
This method is called on the Preference Model Manager by the Preference, whenever a child preference is added or deleted.

Parameters:
preferenceId - The current Preference id (complete id)
childPreferenceId - The preference id of the child preference
operation - Operation type, denoted by OPERATION_CHILD_PREF_ADDED or OPERATION_CHILD_PREF_REMOVED

preferenceAttributeChanged

void preferenceAttributeChanged(java.lang.String preferenceId,
                                java.lang.String preferenceAttributeId,
                                int operation)
This method is called on the Preference Model Manager by the Preference, whenever a child preference is added or deleted.

Parameters:
preferenceId - The current Preference id (complete id)
preferenceAttributeId - The preference id of the child preference
operation - Operation type, denoted by OPERATION_PREF_ATTR_REMOVED or OPERATION_PREF_ATTR_REMOVED


Copyright © 2003-2008 MindTree Consulting Ltd.. All Rights Reserved.