|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
de.unikassel.android.sdcframework.util.AbstractWorkerThread
org.android.activityminer.app.util.ObservableWorkerThreadWithProgressNotification
org.android.activityminer.logic.features.selection.FeatureSelectionThread
public class FeatureSelectionThread
The feature selection thread.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
Thread.State, Thread.UncaughtExceptionHandler |
Field Summary | |
---|---|
private Context |
context
The context. |
private double |
elapsedTime
The time needed for the evaluation run. |
private int |
FEATURE_SELECTION_NOTIFICATION
the notification identifier |
private FeatureSelectionHelper |
helper
The evaluation helper to delegate to |
private long |
startTime
The start time of the actual evaluation run. |
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
FeatureSelectionThread(Context context,
DBManager dbManager,
Set<FeatureTypes> featureSet,
Configuration config,
int size,
Class<? extends Activity> intentReceiver)
Constructor |
Method Summary | |
---|---|
static FeatureSelectionThread |
createAndRun(Context context,
DBManager dbManager,
Set<FeatureTypes> featureSet,
Configuration config,
int size,
EventObserver<TaskFinishedEvent> finishedObserver,
Class<? extends Activity> intentReceiver)
Does create and execute an evaluation thread for the given configuration and feature sets. |
protected void |
doWork()
|
String |
getErrorNotificationMsg()
Getter for the error notification message |
protected String |
getEvaluationStorageLocation()
Getter for the save file name and path |
int |
getNotificationId()
Getter for the notification identifier |
String |
getResultNotificationMsg()
Getter for the result notification message |
boolean |
hasSucceeded()
Test method for success in case of termination |
void |
onEvent(ObservableEventSource<? extends ObservableProgressData> eventSource,
ObservableProgressData observedEvent)
|
Methods inherited from class org.android.activityminer.app.util.ObservableWorkerThreadWithProgressNotification |
---|
broadcastProgress, doCleanUp, getApplicationContext, getFinalResult, getMaxProgress, getNotification, getTaskTitle, hasObservers, incrementAndNotifyProgress, incrementAndNotifyProgress, notify, notifyProgress, notifyProgress, registerEventObserver, removeAllObservers, setMaxProgress, unregisterEventObserver |
Methods inherited from class de.unikassel.android.sdcframework.util.AbstractWorkerThread |
---|
doTerminate, hasTerminated, isLogging, isWorking, logMessage, run, setLogging, start, startWork, stopWork |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private int FEATURE_SELECTION_NOTIFICATION
private final FeatureSelectionHelper helper
private long startTime
private double elapsedTime
private final Context context
Constructor Detail |
---|
public FeatureSelectionThread(Context context, DBManager dbManager, Set<FeatureTypes> featureSet, Configuration config, int size, Class<? extends Activity> intentReceiver)
context
- the application contextdbManager
- a reference to the database managerconfig
- the current configurationfeatureSet
- the set with the features to search insize
- the subset sizeintentReceiver
- the intent receiver classMethod Detail |
---|
protected void doWork()
doWork
in class AbstractWorkerThread
public String getResultNotificationMsg()
ObservableWorkerThreadWithProgressNotification
getResultNotificationMsg
in class ObservableWorkerThreadWithProgressNotification
public String getErrorNotificationMsg()
ObservableWorkerThreadWithProgressNotification
getErrorNotificationMsg
in class ObservableWorkerThreadWithProgressNotification
public boolean hasSucceeded()
ObservableWorkerThreadWithProgressNotification
hasSucceeded
in class ObservableWorkerThreadWithProgressNotification
public int getNotificationId()
ObservableWorkerThreadWithProgressNotification
getNotificationId
in class ObservableWorkerThreadWithProgressNotification
protected final String getEvaluationStorageLocation()
public static final FeatureSelectionThread createAndRun(Context context, DBManager dbManager, Set<FeatureTypes> featureSet, Configuration config, int size, EventObserver<TaskFinishedEvent> finishedObserver, Class<? extends Activity> intentReceiver)
context
- the context of the callerdbManager
- the database manager to useconfig
- the configuration to usefeatureSet
- the set with the features to search insize
- the subset sizefinishedObserver
- the finished event observerintentReceiver
- the intent receiver class
public void onEvent(ObservableEventSource<? extends ObservableProgressData> eventSource, ObservableProgressData observedEvent)
onEvent
in interface EventObserver<ObservableProgressData>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |