Package com.tagtraum.beatunes.analysis
Class UpdateRemoteData
- java.lang.Object
-
- com.tagtraum.beatunes.analysis.Task
-
- com.tagtraum.beatunes.analysis.SongAnalysisTask
-
- com.tagtraum.beatunes.analysis.UpdateRemoteData
-
- All Implemented Interfaces:
TaskFactory
,TaskProcessListener
,TaskRunListener
,Matchable<PlayList.SubstringFilterProperty>
,Cloneable
@Entity public class UpdateRemoteData extends SongAnalysisTask
Updates several remote properties with fresh data from the central database.- Author:
- Hendrik Schreiber
- See Also:
AudioSong.getRemoteUpdateDate()
-
-
Field Summary
-
Fields inherited from class com.tagtraum.beatunes.analysis.Task
useOnlineResources
-
-
Constructor Summary
Constructors Constructor Description UpdateRemoteData()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getDescription()
HTML or plain text description of this task.String
getName()
HTML or plaintext name of this task.void
processBefore(Task task)
Process online results with this task before other tasks are invoked.boolean
skip()
Indicates, whether this task can be skipped.-
Methods inherited from class com.tagtraum.beatunes.analysis.Task
add, addTaskProcessListener, addTaskRunListener, cancel, clearProperties, createDeepCopy, createEditor, createTask, deepRemove, equals, fetchCollections, getAnalysisProgress, getApplication, getAudioFileFormat, getCurrentOperation, getDeepLeafs, getDeepTaskCount, getDeepTasks, getEditor, getId, getMessagePanel, getParent, getPriority, getProperties, getProperty, getPropertyNames, getReferenceSong, getSong, getSongId, getTask, getTaskCount, getTasks, hashCode, hasSucceeded, isAvailable, isCancelled, isDeepUseOnlineResources, isFileExistedBeforeStart, isLeaf, isPaused, isProgressRelevant, isUseOnlineResources, matches, maybePause, process, processAfter, processFinally, remove, removeDeadLeaves, run, runAfter, runBefore, runFinally, setAnalysisProgress, setApplication, setAudioFileFormat, setAvailable, setCurrentOperation, setId, setParent, setPaused, setPriority, setProgressRelevant, setProperties, setProperty, setReferenceSong, setSkipped, setSong, setSongId, setSucceeded, setUseOnlineResources, toString, wasSkipped
-
-
-
-
Method Detail
-
getName
public String getName()
Description copied from class:Task
HTML or plaintext name of this task. Defaults to the task's classname.
-
getDescription
public String getDescription()
Description copied from class:Task
HTML or plain text description of this task.- Overrides:
getDescription
in classTask
- Returns:
- description
-
processBefore
public void processBefore(Task task)
Description copied from class:Task
Process online results with this task before other tasks are invoked. Override this method, if you want to take online resources into account. Note that you will also need to setTask.setUseOnlineResources(boolean)
totrue
, if you want this method to be called at all.To avoid having this task processed again by
Task.runBefore(Task)
, you must callTask.setSucceeded(boolean)
with the argumenttrue
. If, for some reason, you could not take care of this task with just the available online resources, you must callTask.setSucceeded(boolean)
with the argumentfalse
This method is executed before sub tasks are run. When this method is called, the methods
Task.getSong()
andTask.getReferenceSong()
will return meaningful results.- Specified by:
processBefore
in interfaceTaskProcessListener
- Overrides:
processBefore
in classTask
- Parameters:
task
- task
-
skip
public boolean skip()
Description copied from class:Task
Indicates, whether this task can be skipped. Defaults to false.Since this task is not necessarily called by beaTunes, but by your own implementation of
Task.runBefore(Task)
, you should callTask.setSkipped(boolean)
with whatever value you are returning.
-
-