Commit ef7a7da5 authored by Lucas Carvalho's avatar Lucas Carvalho

Updated the README.txt with a better API.

parent 1c2a25bb
...@@ -20,11 +20,16 @@ API ...@@ -20,11 +20,16 @@ API
====== ======
So, it must provide 2 methods: So, it must provide 2 methods:
post(file) upload(file, directory_key=None, **kw)
''' Upload the file to Networkcache HTTP Server using POST as HTTP method.''' ''' Upload the file to ShaCache Server'''
If directory_key is not None, upload add a new key to the shadir server.
get_file(key)
''' Download the file from SHACACHE server using GET as HTTP method.''' download(sha)
'''Download a file from shacache
get_information(directory, urlmd5=None) Raise FileNotFound if file is not found
''' Retrieve the information from SHADIR server using GET as HTTP method. ''' '''
select(directory_key)
'''Download a file from shacache by selecting the entry in shadir
Raise DirectoryNotFound if multiple files are found
'''
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment