Package com.axelor.ui
Class QuickMenuItem
- java.lang.Object
-
- com.axelor.ui.QuickMenuItem
-
public class QuickMenuItem extends Object
An item in the quick menu dropdown
-
-
Constructor Summary
Constructors Constructor Description QuickMenuItem()
Create a new instance of theQuickMenuItem
QuickMenuItem(String title, String action)
Create a new instance of theQuickMenuItem
QuickMenuItem(String title, String action, Context context)
Create a new instance of theQuickMenuItem
QuickMenuItem(String title, String action, Context context, boolean selected)
Create a new instance of theQuickMenuItem
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getAction()
Name of action triggered when item is selectedContext
getContext()
Context to pass to the actionClass<?>
getModel()
Model of the contextString
getTitle()
Title of the itemboolean
isSelected()
Selected state of the itemvoid
setAction(String action)
Set the action triggered when item is selectedvoid
setContext(Context context)
Set the context to pass to the actionvoid
setSelected(boolean selected)
Set the selected state of the itemvoid
setTitle(String title)
Set the title of the itemString
toString()
-
-
-
Constructor Detail
-
QuickMenuItem
public QuickMenuItem()
Create a new instance of theQuickMenuItem
-
QuickMenuItem
public QuickMenuItem(String title, String action, Context context, boolean selected)
Create a new instance of theQuickMenuItem
- Parameters:
title
- titleaction
- actioncontext
- contextselected
- selected state
-
QuickMenuItem
public QuickMenuItem(String title, String action, Context context)
Create a new instance of theQuickMenuItem
- Parameters:
title
- titleaction
- actioncontext
- context
-
QuickMenuItem
public QuickMenuItem(String title, String action)
Create a new instance of theQuickMenuItem
- Parameters:
title
- titleaction
- action
-
-
Method Detail
-
getTitle
public String getTitle()
Title of the item- Returns:
- item title
-
setTitle
public void setTitle(String title)
Set the title of the item- Parameters:
title
- title
-
getAction
public String getAction()
Name of action triggered when item is selected- Returns:
- action
-
setAction
public void setAction(String action)
Set the action triggered when item is selected- Parameters:
action
- action
-
getContext
public Context getContext()
Context to pass to the action- Returns:
- action context
-
setContext
public void setContext(Context context)
Set the context to pass to the action- Parameters:
context
- context
-
getModel
public Class<?> getModel()
Model of the context- Returns:
- context model
-
isSelected
public boolean isSelected()
Selected state of the item- Returns:
- selected state
-
setSelected
public void setSelected(boolean selected)
Set the selected state of the item- Parameters:
selected
- true or false
-
-