public class ImagePusher extends Object implements Runnable
ImageMaster) filelist,
and pushes the fields in that list on a Queue, which is, in turn, handled by a FileCopier
instance.PageMaster might need to use this
scheduling system too (or otherwise this should be build into FileCopier).| Modifier and Type | Field and Description |
|---|---|
(package private) FileCopier |
filecopier
Thread that handles the actual file transfers.
|
(package private) Queue |
files2copy
Queue containing the file-copy tasks that need to be performed by
FileCopier |
(package private) Thread |
kicker
The thread reference.
|
(package private) ImageMaster |
parent
The class that started the pusher (
ImageMaster). |
(package private) int |
sleepTime
Sleeptime for this thread.
|
| Constructor and Description |
|---|
ImagePusher(ImageMaster parent)
Constructor for the ImagePusher
|
| Modifier and Type | Method and Description |
|---|---|
void |
doWork()
Main work loop.
|
void |
init()
Initializes the insatnce by starting a thread.
|
void |
run()
Main loop, exception protected
|
void |
start()
Starts the main Thread.
|
void |
stop()
Stops the main Thread.
|
Thread kicker
int sleepTime
ImageMaster parent
ImageMaster).
Used to retrieve the filelist that needs to be handled.Queue files2copy
FileCopierFileCopier filecopier
public ImagePusher(ImageMaster parent)
parent - The parent that contains and adds the files to handle.public void init()
public void start()
public void stop()
public void doWork()
FileCopier) then takes care
of the actual transfer.MMBase 1.9-SNAPSHOT - ${javadoctimestamp}