Package ipsk.net.http
Class HttpUploadCache
- java.lang.Object
-
- ipsk.net.UploadCache
-
- ipsk.net.http.HttpUploadCache
-
- All Implemented Interfaces:
java.lang.Runnable
public class HttpUploadCache extends UploadCache
Cache to upload data via HTTP PUT or POST method to an remote server.- Author:
- K.Jaensch, klausj@phonetik.uni-muenchen.de
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class ipsk.net.UploadCache
UploadCache.EventTransformer
-
-
Field Summary
-
Fields inherited from class ipsk.net.UploadCache
buffer, bufSize, byteRate, CONNECT_RETRY_DELAY, connected, connectedTimeInMillis, connection, currentStream, currentStreamIndex, currentUpload, DEBUG, DEBUG_DELAY, DEF_CHECKSUM_ALGORITHM, DEFAULT_BUFSIZE, DEFAULT_CONNECT_RETRIES, eventTransformer, guessedToUploadLength, holdLength, holdSize, idle, idleNotified, inputStream, ON_IDLE_DELAY, outputStream, requestMethod, responseMessage, running, startConnect, synced, totalLength, totalUploadLength, toUploadLength, transferRateLimit, transferRateLimitSupported, UNLIMITED, UPLOAD_RETRIES, UPLOAD_RETRY_DELAY, uploadRetryCount
-
-
Constructor Summary
Constructors Constructor Description HttpUploadCache()
Create new empty cache using PUT as default request method..
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isAcceptCookies()
Get permission to accept cookies.void
run()
void
setAcceptCookies(boolean b)
Set permission to accept cookies.void
setSessionCookies(java.lang.String[] sessionCookies)
Set cookies to send to remote server.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from class ipsk.net.UploadCache
addUploadCacheListener, calculateLength, clear, close, fireConnected, fireDisconnected, fireFinished, fireStateChanged, fireStateChangedWait, fireTryConnect, getByteRate, getCachedInputStream, getCurrentUploadStream, getGuessedToUploadLength, getHoldLength, getHoldSize, getNextUpload, getRequestMethod, getResponseCode, getResponseMessage, getTotalLength, getTotalUploadLength, getToUploadLength, getTransferLimit, isConnected, isIdle, isOverwrite, isRunning, isTransferLimitSupported, removeUploadCacheListener, setHoldSize, setOverwrite, setRequestMethod, setTransferLimit, setTransferLimitSupported, start, stop, upload
-
-
-
-
Method Detail
-
setSessionCookies
public void setSessionCookies(java.lang.String[] sessionCookies)
Set cookies to send to remote server.- Parameters:
sessionCookies
-
-
run
public void run()
- Specified by:
run
in interfacejava.lang.Runnable
- Specified by:
run
in classUploadCache
-
isAcceptCookies
public boolean isAcceptCookies()
Get permission to accept cookies.- Returns:
- true if cookies are accepted
-
setAcceptCookies
public void setAcceptCookies(boolean b)
Set permission to accept cookies.- Parameters:
b
- true to accept cookies
-
-