graphlab.main.preferences
Class AbstractPreference
java.lang.Object
graphlab.main.preferences.AbstractPreference
- Direct Known Subclasses:
- GraphPreferences
public abstract class AbstractPreference
- extends java.lang.Object
|
Method Summary |
abstract void |
defineAttributes()
A Suggested implementation for this method will be like this:
public void defineAttributes(){
putAttribute(Desired Objects Assigned name,Objects Value);
} |
abstract void |
defineListeners()
A suggested implementation for this method would be like this:
Class ReactionToChangeAttribute implements AttributeListener{
public void attributeUpdated(String name,Object oldValue,Object newValue){
// Any Desired Reaction, for instance:
if(name.equals(myAttribute)){
System.out.print("Yahoo");
}
}
public vod defineListeneres(){
addAttributeListener(new ReactionToChangeAttribute(),String[] desiredAttributeNames);
}
You can leave this method without implementation if you dont need to listen to change o your properties! |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
preferenceName
public java.lang.String preferenceName
attributeSet
public NotifiableAttributeSetImplX attributeSet
AbstractPreference
public AbstractPreference(java.lang.String name,
Preferences pref)
defineAttributes
public abstract void defineAttributes()
- A Suggested implementation for this method will be like this:
public void defineAttributes(){
putAttribute(Desired Objects Assigned name,Objects Value);
}
defineListeners
public abstract void defineListeners()
- A suggested implementation for this method would be like this:
Class ReactionToChangeAttribute implements AttributeListener{
public void attributeUpdated(String name,Object oldValue,Object newValue){
// Any Desired Reaction, for instance:
if(name.equals(myAttribute)){
System.out.print("Yahoo");
}
}
public vod defineListeneres(){
addAttributeListener(new ReactionToChangeAttribute(),String[] desiredAttributeNames);
}
You can leave this method without implementation if you dont need to listen to change o your properties!