public class FavoritesEditor extends Object implements SettingsSerializable
| Modifier and Type | Class and Description |
|---|---|
static interface |
FavoritesEditor.AddMultipleFavoritesInteraction |
static class |
FavoritesEditor.AddMultipleResult |
static interface |
FavoritesEditor.EditFavoriteInteraction |
class |
FavoritesEditor.EditibleFavoriteTask
This is what you actually edit when you want to edit a favorite.
|
static interface |
FavoritesEditor.FavoriteTasksObserver |
static interface |
FavoritesEditor.ValidationInteraction |
| Constructor and Description |
|---|
FavoritesEditor() |
| Modifier and Type | Method and Description |
|---|---|
FavoriteTask |
addFavorite(FavoritesEditor.EditFavoriteInteraction addFavoriteInteraction)
Call this to add a favorite that isn't in the task list.
|
FavoriteTask |
addFavorite(String fullCommandLine,
boolean alwaysShowOutput) |
FavoriteTask |
addFavorite(String fullCommandLine,
String displayName,
boolean alwaysShowOutput) |
FavoriteTask |
addFavorite(TaskView task,
boolean alwaysShowOutput) |
void |
addFavorites(List<TaskView> tasks,
boolean alwaysShowOutput)
Call this to add the specified tasks as favorite tasks
|
void |
addFavoriteTasksObserver(FavoritesEditor.FavoriteTasksObserver observer,
boolean inEventQueue) |
void |
addMutlipleFavorites(List<TaskView> tasks,
boolean alwaysShowOutput,
FavoritesEditor.AddMultipleFavoritesInteraction interaction)
Call this to add tasks as favorites.
|
static String |
combineFavoriteCommandLines(List<FavoriteTask> favoriteTasks)
This combines all the command lines of the favorites list into a single command line.
|
FavoriteTask |
duplicateFavorite(FavoriteTask taskToCopy,
FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
This makes a copy of the selected task.
|
void |
duplicateFavorites(List<FavoriteTask> tasksToCopy,
FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
This makes a copy of all the selected tasks.
|
boolean |
editFavorite(FavoriteTask favoriteTask,
FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
Edits the specified favorite task.
|
void |
exportToFile(DOM4JSerializer.ExportInteraction exportInteraction)
Call this to save favorites to a file.
|
FavoriteTask |
getFavorite(String fullCommandLine) |
FavoriteTask |
getFavorite(TaskView task) |
FavoriteTask |
getFavoriteByDisplayName(String displayName) |
List<FavoriteTask> |
getFavoriteTasks() |
boolean |
importFromFile(DOM4JSerializer.ImportInteraction importInteraction)
Call this to read favorites from a file.
|
void |
moveFavoritesAfter(List<FavoriteTask> favoritesToMove) |
void |
moveFavoritesBefore(List<FavoriteTask> favoritesToMove)
This moves the specified favorites up.
|
void |
removeFavorites(List<FavoriteTask> favoritesToRemove)
Call this to remove the specified favorites from the favorite tasks.
|
void |
removeFavoriteTasksObserver(FavoritesEditor.FavoriteTasksObserver observer) |
void |
serializeIn(SettingsNode settings)
Call this to read in this object's settings.
|
void |
serializeOut(SettingsNode settings)
Call this to saves the current settings.
|
public List<FavoriteTask> getFavoriteTasks()
public void addFavoriteTasksObserver(FavoritesEditor.FavoriteTasksObserver observer, boolean inEventQueue)
public void removeFavoriteTasksObserver(FavoritesEditor.FavoriteTasksObserver observer)
public FavoriteTask getFavorite(String fullCommandLine)
public FavoriteTask getFavoriteByDisplayName(String displayName)
public FavoriteTask getFavorite(TaskView task)
public void addMutlipleFavorites(List<TaskView> tasks, boolean alwaysShowOutput, FavoritesEditor.AddMultipleFavoritesInteraction interaction)
tasks - the tasks to add. Their order in the list becomes the order in the single task if the user chooses this.interaction - how we interact with the user or other UI.public FavoriteTask addFavorite(TaskView task, boolean alwaysShowOutput)
public FavoriteTask addFavorite(String fullCommandLine, boolean alwaysShowOutput)
public FavoriteTask addFavorite(String fullCommandLine, String displayName, boolean alwaysShowOutput)
public void addFavorites(List<TaskView> tasks, boolean alwaysShowOutput)
tasks - the task to make a favorite.public FavoriteTask addFavorite(FavoritesEditor.EditFavoriteInteraction addFavoriteInteraction)
addFavoriteInteraction - allows us to interact with the userpublic boolean editFavorite(FavoriteTask favoriteTask, FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
favoriteTask - the task to edit.editFavoriteInteraction - how we interact with the userpublic void removeFavorites(List<FavoriteTask> favoritesToRemove)
favoritesToRemove - the favorite tasks to removepublic void moveFavoritesBefore(List<FavoriteTask> favoritesToMove)
favoritesToMove - .public void moveFavoritesAfter(List<FavoriteTask> favoritesToMove)
public void exportToFile(DOM4JSerializer.ExportInteraction exportInteraction)
public boolean importFromFile(DOM4JSerializer.ImportInteraction importInteraction)
public void serializeOut(SettingsNode settings)
serializeOut in interface SettingsSerializablesettings - where you save the settings.public void serializeIn(SettingsNode settings)
serializeIn in interface SettingsSerializablesettings - where you read your settings.public void duplicateFavorites(List<FavoriteTask> tasksToCopy, FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
tasksToCopy - the tasks to copypublic FavoriteTask duplicateFavorite(FavoriteTask taskToCopy, FavoritesEditor.EditFavoriteInteraction editFavoriteInteraction)
taskToCopy - the task to copypublic static String combineFavoriteCommandLines(List<FavoriteTask> favoriteTasks)
favoriteTasks - the favorite tasks to combineCopyright © 2013. All rights reserved