diff options
Diffstat (limited to 'java/ImageProcessing/framework/GIFHandler.java')
-rw-r--r-- | java/ImageProcessing/framework/GIFHandler.java | 75 |
1 files changed, 0 insertions, 75 deletions
diff --git a/java/ImageProcessing/framework/GIFHandler.java b/java/ImageProcessing/framework/GIFHandler.java deleted file mode 100644 index 3d099ba294c..00000000000 --- a/java/ImageProcessing/framework/GIFHandler.java +++ /dev/null @@ -1,75 +0,0 @@ -package imaging.framework; - -import java.awt.*; -import java.io.*; -import JACE.OS.*; -import JACE.Connection.*; - - -public class GIFHandler extends BlobWriter -{ - public GIFHandler (String filename, Image image, int length) - { - super (null, length, 0, filename); - this.image_ = image; - } - - /****************************** - * Used for HTTP 1.1 PUT authorization - *****************************/ - public GIFHandler (String filename, Image image, int length, String authentication) - { - super (null, length, 0, filename, authentication); - this.image_ = image; - } - - protected int sendRequest () - { - if (this.sendHeader () == -1) - { - ACE.ERROR ("GIFHandler::sendHeader failed."); - return -1; - } - else - if (this.sendData () == -1) - { - ACE.ERROR ("GIFHandler::sendData failed."); - return -1; - } - return 0; - } - - // Send the data - protected int sendData () - { - - - try - { - if (this.length_ > 0) - { - OutputStream ostream = this.peer ().outputStream (); - - this.encoder_ = new GifEncoder (this.image_, ostream); - - this.encoder_.encode (); - - ostream.flush(); - - // this.encoder_ = new GIFEncoder (this.image_); - // this.encoder_.Write (ostream); - } - this.bytesWritten_ = this.length_; - - } - catch (IOException e) - { - ACE.ERROR ("Error writing to server"); - } - return 0; - } - - GifEncoder encoder_ = null; - // GIFEncoder encoder_ = null; - Image image_ = null; -} |