public abstract class AbstractTabMenuItem<T extends AbstractExplorerTab> extends Object implements Comparable<AbstractTabMenuItem<T>>
Constructor and Description |
---|
AbstractTabMenuItem() |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(AbstractTabMenuItem<T> o)
Compares this item to another, using group and name.
|
abstract ActionListener |
getActionListener(T owner)
Returns the action lister to use in the menu.
|
abstract String |
getGroup()
Returns the group of the plugin.
|
abstract String |
getIcon()
Returns the name of the icon to use.
|
abstract String |
getName()
Returns the name of the plugin.
|
Object |
getSessionValue(T owner,
String key)
Returns a session value, if present.
|
boolean |
hasSessionValue(T owner,
String key)
Checks whether a session value is present.
|
void |
setSessionValue(T owner,
String key,
Object value)
Sets a session value.
|
abstract void |
update(T owner,
JMenuItem menuitem)
Updates the menu item using the current state of the tab.
|
public boolean hasSessionValue(T owner, String key)
owner
- the tab this menu item belongs tokey
- the key to look forpublic Object getSessionValue(T owner, String key)
owner
- the tab this menu item belongs tokey
- the key to look forpublic void setSessionValue(T owner, String key, Object value)
owner
- the tab this menu item belongs tokey
- the key to look forvalue
- the value to setpublic abstract String getGroup()
public abstract String getName()
public abstract String getIcon()
public abstract ActionListener getActionListener(T owner)
public abstract void update(T owner, JMenuItem menuitem)
owner
- the tab that the menu item belongs tomenuitem
- the menu item to update (was generated by this class)public int compareTo(AbstractTabMenuItem<T> o)
compareTo
in interface Comparable<AbstractTabMenuItem<T extends AbstractExplorerTab>>
o
- the other itemCopyright © 2017. All Rights Reserved.