From 1a445a101268766d56a159a26f18b8fcb345b2fb Mon Sep 17 00:00:00 2001 From: Marco Mariani <marco.mariani@nexedi.com> Date: Fri, 27 Dec 2013 12:19:30 +0100 Subject: [PATCH] minor fixes --- docs/complex_queries.rst | 5 +++-- docs/getting_started.rst | 12 ++++++++++-- docs/index.rst | 4 ---- docs/manage_documents.rst | 9 ++++++--- docs/metadata.rst | 2 +- 5 files changed, 20 insertions(+), 12 deletions(-) diff --git a/docs/complex_queries.rst b/docs/complex_queries.rst index 7050967..7e0cf96 100644 --- a/docs/complex_queries.rst +++ b/docs/complex_queries.rst @@ -1,3 +1,4 @@ + jIO Complex Queries =================== @@ -7,7 +8,7 @@ What are Complex Queries? In jIO, a complex query can ask a storage server to select, filter, sort, or limit a document list before sending it back. If the server is not able to do so, the complex query tool can do the filtering by itself on the client. Only the -``allDocs()`` method can use complex queries. +``.allDocs()`` method can use complex queries. A query can either be a string (using a specific language useful for writing queries), or it can be a tree of objects (useful to browse queries). To handle @@ -33,7 +34,7 @@ to run the query on the index before querying documents itself. How to use Complex Queries with jIO? ------------------------------------ -Complex queries can be triggered by including the option named **query** in the ``allDocs()`` method call. +Complex queries can be triggered by including the option named **query** in the ``.allDocs()`` method call. Example: diff --git a/docs/getting_started.rst b/docs/getting_started.rst index df9e31d..4313e55 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -45,15 +45,23 @@ Getting started You can use both handlers and available storages to build a storage tree across which all documents will be maintained and managed by jIO. - See :ref:`List of Available Storages <list-of-available-storages>`. - .. code-block:: javascript // create your jio instance var my_jio = jIO.createJIO(storage_description); + You have to provide a ``storage_description`` object, providing location + and credentials. + + Its format depends on the type of storage, + see :ref:`List of Available Storages <list-of-available-storages>`. + + #. The jIO API provides ten main methods to manage documents across the storage(s) specified in your jIO storage tree. + For details on the ``document`` and ``attachment`` objects, see :ref:`What is a document? <what-is-a-document>` + + ======================= ====================================================== Method Example ======================= ====================================================== diff --git a/docs/index.rst b/docs/index.rst index e1d77de..6ce1d9a 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,7 +1,3 @@ -.. jIO documentation master file, created by - sphinx-quickstart on Fri Nov 15 11:55:08 2013. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. Welcome to jIO ============== diff --git a/docs/manage_documents.rst b/docs/manage_documents.rst index 4f333cb..320b1da 100644 --- a/docs/manage_documents.rst +++ b/docs/manage_documents.rst @@ -12,6 +12,9 @@ CouchDB provides a RESTful HTTP/JSON API accessible by many programming libraries and tools (like `curl <http://curl.haxx.se/>`_ or `Pouchdb <http://pouchdb.com/>`_) and has its own conflict management system. + +.. _what-is-a-document: + What is a document? ------------------- @@ -63,7 +66,7 @@ see how method calls should be made with either of these storages. .. code-block:: javascript // Create a new jIO instance - var jio_instance = jIO.createJIO(storage tree description); + var jio_instance = jIO.createJIO(storage_description); // create and store new document jio_instance.post({title: 'some title'}). @@ -256,8 +259,8 @@ In case of error, the ``errorCallback`` first parameter will look like: -How to store a video on localStorage ------------------------------------- +How to store binary data +------------------------ The following example creates a new jIO in localStorage and then posts a document with two attachments. diff --git a/docs/metadata.rst b/docs/metadata.rst index edab2ab..6747237 100644 --- a/docs/metadata.rst +++ b/docs/metadata.rst @@ -11,7 +11,7 @@ The word "metadata" means "data about data". Metadata articulates a context for objects of interest -- "resources" such as MP3 files, library books, or satellite images -- in the form of "resource descriptions". As a tradition, resource description dates back to the earliest archives and library catalogs. -During the Web revolution of the mid-1990s, `Dublic Core <http://dublincore.org/metadata-basics/>`_ +During the Web revolution of the mid-1990s, `Dublin Core <http://dublincore.org/metadata-basics/>`_ has emerged as one of the prominent metadata standards. Why use metadata? -- 2.30.9