Package org.apache.jmeter.gui.action
Class LoadRecentProject
-
- All Implemented Interfaces:
-
org.apache.jmeter.gui.action.Command
@AutoService(value = Command.class) public class LoadRecentProject extends Load
Handles the loading of recent files, and also the content and visibility of menu items for loading the recent files
-
-
Constructor Summary
Constructors Constructor Description LoadRecentProject()
-
Method Summary
Modifier and Type Method Description Set<String>
getActionNames()
void
doActionAfterCheck(ActionEvent e)
Called to handle ActionEvent only if no test is running static List<JComponent>
getRecentFileMenuItems()
Get the menu items to add to the menu bar, to get recent file functionality static void
updateRecentFileMenuItems(List<JComponent> menuItems, String loadedFileName)
Update the content and visibility of the menu items for recent files static String
getRecentFile(int index)
Get the full path to the recent file where index 0 is the most recent static boolean
hasVisibleMenuItem(List<out JComponent> fileLoadRecentFiles)
-
Methods inherited from class org.apache.jmeter.gui.action.Load
insertLoadedTree, insertLoadedTree
-
Methods inherited from class org.apache.jmeter.gui.action.AbstractActionWithNoRunningTest
doAction
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getActionNames
Set<String> getActionNames()
-
doActionAfterCheck
void doActionAfterCheck(ActionEvent e)
Called to handle ActionEvent only if no test is running
- Parameters:
e
- ActionEvent
-
getRecentFileMenuItems
static List<JComponent> getRecentFileMenuItems()
Get the menu items to add to the menu bar, to get recent file functionality
- Returns:
a List of JMenuItem, representing recent files. JMenuItem may not be visible
-
updateRecentFileMenuItems
static void updateRecentFileMenuItems(List<JComponent> menuItems, String loadedFileName)
Update the content and visibility of the menu items for recent files
- Parameters:
menuItems
- the JMenuItem to updateloadedFileName
- the file name of the project file that has just been loaded
-
getRecentFile
static String getRecentFile(int index)
Get the full path to the recent file where index 0 is the most recent
- Parameters:
index
- the index of the recent file- Returns:
full path to the recent file at
index
-
hasVisibleMenuItem
static boolean hasVisibleMenuItem(List<out JComponent> fileLoadRecentFiles)
- Parameters:
fileLoadRecentFiles
- List of JMenuItem- Returns:
true if at least on JMenuItem is visible
-
-
-
-