indra::ipc::webdav::WebDAV Class Reference
List of all members.
Detailed Description
Definition at line 74 of file webdav.py.
Member Function Documentation
def indra::ipc::webdav::WebDAV::__init__ |
( |
|
self, |
|
|
|
url, |
|
|
|
proxy = None , |
|
|
|
retries_before_fail = 6 | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::log |
( |
|
self, |
|
|
|
msg, |
|
|
|
depth = 0 | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::connect |
( |
|
self |
) |
|
def indra::ipc::webdav::WebDAV::__err |
( |
|
self, |
|
|
|
response, |
|
|
|
details | |
|
) |
| | [private] |
def indra::ipc::webdav::WebDAV::request |
( |
|
self, |
|
|
|
method, |
|
|
|
path, |
|
|
|
body = None , |
|
|
|
headers = None , |
|
|
|
read_all = True , |
|
|
|
body_hook = None , |
|
|
|
recurse = 0 , |
|
|
|
allow_cache = True | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::retry_request |
( |
|
self, |
|
|
|
method, |
|
|
|
path, |
|
|
|
body, |
|
|
|
headers, |
|
|
|
read_all, |
|
|
|
body_hook, |
|
|
|
recurse | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::propfind |
( |
|
self, |
|
|
|
path, |
|
|
|
body = None , |
|
|
|
depth = 1 | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::purge |
( |
|
self, |
|
|
|
path | |
|
) |
| | |
issue a squid purge command
Definition at line 232 of file webdav.py.
def indra::ipc::webdav::WebDAV::get_file_size |
( |
|
self, |
|
|
|
path | |
|
) |
| | |
Use propfind to ask a webdav server what the size of
a file is. If used on a directory (collection) return 0
Definition at line 242 of file webdav.py.
def indra::ipc::webdav::WebDAV::file_exists |
( |
|
self, |
|
|
|
path | |
|
) |
| | |
do an http head on the given file. return True if it succeeds
Definition at line 274 of file webdav.py.
def indra::ipc::webdav::WebDAV::mkdir |
( |
|
self, |
|
|
|
path | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::delete |
( |
|
self, |
|
|
|
path | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::list_directory |
( |
|
self, |
|
|
|
path, |
|
|
|
dir_filter = None , |
|
|
|
allow_cache = True , |
|
|
|
minimum_cache_time = False | |
|
) |
| | |
Request an http directory listing and parse the filenames out of lines
like: '<LI><A HREF="X"> X</A>'. If a filter function is provided,
only return filenames that the filter returns True for.
This is sort of grody, but it seems faster than other ways of getting
this information from an isilon.
Definition at line 313 of file webdav.py.
def indra::ipc::webdav::WebDAV::__tmp_filename |
( |
|
self, |
|
|
|
path_and_file | |
|
) |
| | [private] |
def indra::ipc::webdav::WebDAV::__put__ |
( |
|
self, |
|
|
|
filesize, |
|
|
|
body_hook, |
|
|
|
remotefile | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::put_string |
( |
|
self, |
|
|
|
strng, |
|
|
|
remotefile | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::put_file |
( |
|
self, |
|
|
|
localfile, |
|
|
|
remotefile | |
|
) |
| | |
Send a local file to a remote webdav store. First, upload to
a temporary filename. Next make sure the file is the size we
expected. Next, move the file to its final location. Next,
check the file size at the final location.
Definition at line 415 of file webdav.py.
def indra::ipc::webdav::WebDAV::create_empty_file |
( |
|
self, |
|
|
|
remotefile | |
|
) |
| | |
def indra::ipc::webdav::WebDAV::__get_file_setup |
( |
|
self, |
|
|
|
remotefile, |
|
|
|
check_size = True | |
|
) |
| | [private] |
__get_file_setup docstring
Definition at line 447 of file webdav.py.
def indra::ipc::webdav::WebDAV::__get_file_read |
( |
|
self, |
|
|
|
writehandle, |
|
|
|
response, |
|
|
|
content_length | |
|
) |
| | [private] |
__get_file_read docstring
Definition at line 464 of file webdav.py.
def indra::ipc::webdav::WebDAV::get_file |
( |
|
self, |
|
|
|
remotefile, |
|
|
|
localfile, |
|
|
|
check_size = True | |
|
) |
| | |
Get a remote file from a webdav server. Download to a local
tmp file, then move into place. Sanity check file sizes as
we go.
Definition at line 484 of file webdav.py.
def indra::ipc::webdav::WebDAV::get_file_as_string |
( |
|
self, |
|
|
|
remotefile, |
|
|
|
check_size = True | |
|
) |
| | |
download a file from a webdav server and return it as a string.
Definition at line 504 of file webdav.py.
def indra::ipc::webdav::WebDAV::get_post_as_string |
( |
|
self, |
|
|
|
remotefile, |
|
|
|
body | |
|
) |
| | |
Do an http POST, send body, get response and return it.
Definition at line 521 of file webdav.py.
def indra::ipc::webdav::WebDAV::__destination_command |
( |
|
self, |
|
|
|
verb, |
|
|
|
remotesrc, |
|
|
|
dstdav, |
|
|
|
remotedst | |
|
) |
| | [private] |
self and dstdav should point to the same http server.
Definition at line 544 of file webdav.py.
def indra::ipc::webdav::WebDAV::rename |
( |
|
self, |
|
|
|
remotesrc, |
|
|
|
remotedst | |
|
) |
| | |
rename a file on a webdav server
Definition at line 562 of file webdav.py.
def indra::ipc::webdav::WebDAV::xrename |
( |
|
self, |
|
|
|
remotesrc, |
|
|
|
dstdav, |
|
|
|
remotedst | |
|
) |
| | |
rename a file on a webdav server
Definition at line 566 of file webdav.py.
def indra::ipc::webdav::WebDAV::copy |
( |
|
self, |
|
|
|
remotesrc, |
|
|
|
remotedst | |
|
) |
| | |
copy a file on a webdav server
Definition at line 572 of file webdav.py.
def indra::ipc::webdav::WebDAV::xcopy |
( |
|
self, |
|
|
|
remotesrc, |
|
|
|
dstdav, |
|
|
|
remotedst | |
|
) |
| | |
copy a file on a webdav server
Definition at line 576 of file webdav.py.
Member Data Documentation
The documentation for this class was generated from the following file: