|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.w3c.jwput.JW | +--org.w3c.jwput.JWPut
Put files on the web
Fields inherited from class org.w3c.jwput.JW |
BANNER,
DEFAULT_MIME,
etagsDB,
in,
jwprops,
manager,
password,
prompt,
quiet,
ui,
user,
USER_AGENT,
verbose,
VERSION,
WINIE_DOC_URL,
WINIE_LATEST_ZIP,
WINIE_URL |
Constructor Summary | |
JWPut(JWUI ui)
Constructor |
|
JWPut(JWUI ui,
java.util.Properties props)
Constructor |
|
JWPut(java.lang.String mime,
JWUI ui,
java.util.Properties userprops)
Constructor. |
|
JWPut(java.lang.String mime,
java.util.Properties userprops)
Constructor. |
Method Summary | |
void |
abort()
|
static void |
badArgs(java.lang.String msg)
Display the message for bad command line error. |
org.w3c.www.protocol.http.Request |
createRequest()
Create a HTTP/1.1 request |
void |
delete(java.lang.String url)
Perform a DELETE |
java.lang.String |
getMimeType(java.lang.String name)
Guess a mime type for the given file. |
java.lang.String |
getMimeType(java.lang.String name,
boolean prompt)
Guess a mime type for the given file. |
protected void |
initialize(java.util.Properties props)
|
static void |
main(java.lang.String[] args)
Main. |
void |
perform(java.lang.String file,
java.lang.String url)
Perform the put(s) |
org.w3c.www.protocol.http.Reply |
put(java.io.File toput,
java.lang.String puturl,
java.lang.String etag)
Perform a HTTP/1.1 PUT |
org.w3c.www.protocol.http.Reply |
put(java.io.File toput,
java.lang.String puturl,
java.lang.String etag,
java.util.Hashtable headers)
Perform a HTTP/1.1 PUT |
protected void |
putAbortableDir(java.io.File dir,
java.lang.String durl,
java.util.Hashtable headers,
boolean rec)
Put (recursively) the files to the location URL. |
void |
putDir(java.io.File dir,
java.lang.String durl)
Put (recursively) the files to the location URL. |
void |
putDir(java.io.File dir,
java.lang.String durl,
java.util.Hashtable headers,
boolean rec)
Put (recursively) the files to the location URL. |
void |
putFile(java.io.File toput,
java.lang.String furl)
Put the givent file at the given location URL |
void |
putFile(java.io.File toput,
java.lang.String desturl,
java.util.Hashtable headers)
Put the givent file at the given location URL |
java.util.Properties |
registerMimeTypeForFile(java.lang.String file,
java.lang.String mime)
|
void |
updateProperties(java.util.Properties props)
Update the user properties |
static void |
usage()
Display the "Usage" message. |
Methods inherited from class org.w3c.jwput.JW |
check,
createRequest,
displayErrorMessage,
displayMessage,
getETag,
getETagsDatabase,
getManager,
getPort,
getPreferencesFile,
getProperties,
getUserProperties,
notifyProgress,
performRequest,
performRequest,
performRequest,
performRequest,
removeEtag,
saveEtag,
savePreferences,
skipBody |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public JWPut(JWUI ui)
ui
- the User Interfacepublic JWPut(JWUI ui, java.util.Properties props)
ui
- the User Interfaceprops
- the User propertiespublic JWPut(java.lang.String mime, java.util.Properties userprops)
file
- The file (or directory) to putmime
- The mime typeurl
- The destination URLui
- The User Interfaceuserprops
- User propertiespublic JWPut(java.lang.String mime, JWUI ui, java.util.Properties userprops)
file
- The file (or directory) to putmime
- The mime typeurl
- The destination URLuserprops
- User propertiesMethod Detail |
public org.w3c.www.protocol.http.Request createRequest()
public java.util.Properties registerMimeTypeForFile(java.lang.String file, java.lang.String mime) throws java.io.IOException
public java.lang.String getMimeType(java.lang.String name) throws PutAbortedException
name
- the file namepublic java.lang.String getMimeType(java.lang.String name, boolean prompt) throws PutAbortedException
name
- the file nameprompt
- should we prompt the user for a mime type if we can't
guess it?public org.w3c.www.protocol.http.Reply put(java.io.File toput, java.lang.String puturl, java.lang.String etag) throws java.io.FileNotFoundException, PutAbortedException
toput
- The file to uploadputurl
- the location urluser
- auth: usernamepassword
- auth: passwordpublic org.w3c.www.protocol.http.Reply put(java.io.File toput, java.lang.String puturl, java.lang.String etag, java.util.Hashtable headers) throws java.io.FileNotFoundException, PutAbortedException
toput
- The file to uploadputurl
- the location urluser
- auth: usernamepassword
- auth: passwordpublic void abort()
public void perform(java.lang.String file, java.lang.String url) throws java.io.FileNotFoundException
public void delete(java.lang.String url)
public void putDir(java.io.File dir, java.lang.String durl) throws java.io.FileNotFoundException
dir
- the directorydurl
- the location URLpublic void putDir(java.io.File dir, java.lang.String durl, java.util.Hashtable headers, boolean rec) throws java.io.FileNotFoundException
dir
- the directorydurl
- the location URLheaders
- User headersprotected void putAbortableDir(java.io.File dir, java.lang.String durl, java.util.Hashtable headers, boolean rec) throws java.io.FileNotFoundException, PutAbortedException
dir
- the directorydurl
- the location URLheaders
- User headerspublic void putFile(java.io.File toput, java.lang.String furl) throws java.io.FileNotFoundException
toput
- the file to uploadfurl
- the urlpublic void putFile(java.io.File toput, java.lang.String desturl, java.util.Hashtable headers) throws java.io.FileNotFoundException
toput
- the file to uploadfurl
- the urlheaders
- User headerspublic void updateProperties(java.util.Properties props)
props
- the new peopertiesprotected void initialize(java.util.Properties props)
public static void usage()
public static void badArgs(java.lang.String msg)
msg
- a message.public static void main(java.lang.String[] args)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |