java.security.PrivilegedExceptionAction<java.lang.Object>, Serviceablefinal class RemoveFile extends java.lang.Object implements Serviceable, java.security.PrivilegedExceptionAction<java.lang.Object>
| Modifier and Type | Field | Description |
|---|---|---|
private StorageFile |
fileToGo |
DONE, REQUEUE| Constructor | Description |
|---|---|
RemoveFile(StorageFile fileToGo) |
| Modifier and Type | Method | Description |
|---|---|---|
int |
performWork(ContextManager context) |
Do whatever it is that you want the daemon to do for you.
|
java.lang.Object |
run() |
|
boolean |
serviceASAP() |
If this work should be done as soon as possible, then return true.
|
boolean |
serviceImmediately() |
File deletion is a quick operation and typically releases substantial
amount of space very quickly, this work should be done on the
user thread.
|
private final StorageFile fileToGo
RemoveFile(StorageFile fileToGo)
public int performWork(ContextManager context) throws StandardException
ServiceableperformWork in interface Serviceablecontext - the contextManager set up by the DaemonService. There
may or may not be the necessary context on it, depending on which other
Serviceable object it has done work for.StandardException - Standard Derby exception policy
MT - depends on the work. Be wary of multiple DaemonService thread calling at the same time if you subscribe or enqueue multiple times.
public boolean serviceASAP()
ServiceableMT - MT safe
serviceASAP in interface Serviceablepublic boolean serviceImmediately()
serviceImmediately in interface Serviceablepublic java.lang.Object run()
throws StandardException
run in interface java.security.PrivilegedExceptionAction<java.lang.Object>StandardExceptionApache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.