[Pkg-owncloud-commits] [owncloud-doc] 33/60: Integrate ios/android lib docs, fix formatting

David Prévot taffit at moszumanska.debian.org
Tue Feb 25 19:06:55 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository owncloud-doc.

commit c5dade647696912178dc08c804a19145f10f1b3f
Author: Daniel Molkentin <daniel at molkentin.de>
Date:   Wed Feb 19 12:10:17 2014 +0100

    Integrate ios/android lib docs, fix formatting
---
 developer_manual/android_library/Introduction.rst  |   10 -
 .../android_library/{EXAMPLES.rst => examples.rst} |  247 +---
 developer_manual/android_library/index.rst         |   29 +-
 ...y_Installation.rst => library_installation.rst} |    1 -
 developer_manual/contents.rst                      |    2 +
 developer_manual/index.rst                         |   34 +-
 developer_manual/ios_library/EXAMPLES.rst          | 1537 --------------------
 developer_manual/ios_library/Introduction.rst      |   10 -
 .../ios_library/Library_Installation.rst           |  203 ---
 developer_manual/ios_library/examples.rst          |  544 +++++++
 developer_manual/ios_library/index.rst             |   25 +-
 .../ios_library/library_installation.rst           |  133 ++
 12 files changed, 806 insertions(+), 1969 deletions(-)

diff --git a/developer_manual/android_library/Introduction.rst b/developer_manual/android_library/Introduction.rst
deleted file mode 100644
index d50cb98..0000000
--- a/developer_manual/android_library/Introduction.rst
+++ /dev/null
@@ -1,10 +0,0 @@
-Introduction
-============
-
-
-This document will describe how to the use ownCloud Android Library.
-The ownCloud Android Library allows a developer to communicate with any ownCloud server; among the features included are file synchronization, upload and download of files, delete rename files and folders, etc.
-
-This library may be added to a project and seamlessly integrates any application with ownCloud.
-
-The tool needed is any IDE for Android. This guide includes some screenshots showing examples in Eclipse.
diff --git a/developer_manual/android_library/EXAMPLES.rst b/developer_manual/android_library/examples.rst
similarity index 87%
rename from developer_manual/android_library/EXAMPLES.rst
rename to developer_manual/android_library/examples.rst
index 5be589a..82199c3 100644
--- a/developer_manual/android_library/EXAMPLES.rst
+++ b/developer_manual/android_library/examples.rst
@@ -1,152 +1,73 @@
-EXAMPLES
+Examples
 ========
 
 Init the library
 ----------------
 
-Start using the library; it is needed to init the object mClient that will be in charge of keeping the communication with the server.
+Start using the library; it is needed to init the object mClient that will be
+in charge of keeping the communication with the server.
 
 Code example
 ~~~~~~~~~~~~
 
+.. code-block:: java
 
-+-------------------------------------------------------------+
-| **public**                                                  |
-|                                                             |
-| **class**                                                   |
-|                                                             |
-| MainActivity                                                |
-| **extends**                                                 |
-|                                                             |
-| Activity                                                    |
-|                                                             |
-| **implements**                                              |
-|                                                             |
-| OnRemoteOperationListener, OnDatatransferProgressListener { |
-|                                                             |
-|                                                             |
-| **private**                                                 |
-|                                                             |
-| OwnCloudClient                                              |
-| mClient                                                     |
-| ;                                                           |
-|                                                             |
-|                                                             |
-| **private**                                                 |
-|                                                             |
-| Handler                                                     |
-| mHandler =                                                  |
-| **new**                                                     |
-|                                                             |
-| Handler();                                                  |
-|                                                             |
-|                                                             |
-| …                                                           |
-|                                                             |
-| **public**                                                  |
-|                                                             |
-| **void**                                                    |
-|                                                             |
-| onCreate(Bundle                                             |
-| *savedInstanceState*                                        |
-| ) {                                                         |
-|                                                             |
-| …                                                           |
-|                                                             |
-| // Build full URI to WebDAV entry point                     |
-|                                                             |
-| Uri serverUri = Uri.                                        |
-| *parse*                                                     |
-| (getString(R.string.                                        |
-| *server_base_url*                                           |
-| ) +                                                         |
-|                                                             |
-| AccountUtils.                                               |
-| *WEBDAV_PATH_4_0*                                           |
-| );                                                          |
-|                                                             |
-|                                                             |
-| // Create client object to perform remote operations        |
-|                                                             |
-| mClient                                                     |
-|                                                             |
-| = OwnCloudClientFactory.                                    |
-| *createOwnCloudClient*                                      |
-| (                                                           |
-|                                                             |
-| serverUri,                                                  |
-|                                                             |
-| **this**                                                    |
-| ,                                                           |
-| // Activity or Service context                              |
-|                                                             |
-| **true**                                                    |
-| );                                                          |
-|                                                             |
-+-------------------------------------------------------------+
+  public class MainActivity extends Activity
+                            implements  OnRemoteOperationListener,
+                                        OnDatatransferProgressListener {
+  private OwnCloudClient mClient;
+  private Handler mHandler = new Handler();
 
+  ...
 
-Set credentials
----------------
-
-Authentication on the app is possible by 3 different methods:
+  public void onCreate(Bundle savedInstanceState) {
 
-*   Basic authentication, user name and password
+  ...
 
+  // Build full URI to WebDAV entry point
+  Uri serverUri = Uri.parse(getString(R.string.server_base_url)
+                  + AccountUtils(WEBDAV_PATH_4_0);
 
+  // Create client object to perform remote operations
+  mClient = OwnCloudClientFactory.createOwnCloudClient(
+              serverUri,
+              this,
+              // Activity or Service context
+              true);
 
-*   Bearer access token (oAuth2)
+Set credentials
+---------------
 
+Authentication on the app is possible by 3 different methods:
 
+* Basic authentication, user name and password
+* Bearer access token (oAuth2)
+* Cookie (SAML-based single-sign-on)
 
-*   Cookie (SAML-based single-sign-on)
+Code example
+~~~~~~~~~~~~
 
+.. code-block:: java
 
+  package com.owncloud.android.lib.common;
 
+  public class OwnCloudClient extends HttpClient {
 
-Code example
-~~~~~~~~~~~~
+  ...
 
-+-------------------------------------------------+
-| **package**                                     |
-|                                                 |
-| com.owncloud.android.lib.common;                |
-|                                                 |
-| …                                               |
-|                                                 |
-| **public**                                      |
-|                                                 |
-| **class**                                       |
-|                                                 |
-| OwnCloudClient                                  |
-| **extends**                                     |
-|                                                 |
-| HttpClient {                                    |
-|                                                 |
-| …                                               |
-|                                                 |
-| // Set basic credentials                        |
-|                                                 |
-| client.setBasicCredentials(username, password); |
-|                                                 |
-|                                                 |
-| // Set bearer access token                      |
-|                                                 |
-| client.set                                      |
-| BearerCredentials(accessToken);                 |
-|                                                 |
-|                                                 |
-| // Set session cookie                           |
-|                                                 |
-| client.setSsoSessionCookie(cookie);             |
-|                                                 |
-+-------------------------------------------------+
+  // Set basic credentials
+  client.setBasicCredentials(username, password);
+  // Set bearer access token
+  client.setBearerCredentials(accessToken);
+  // Set session cookie
+  client.setSsoSessionCookie(cookie);
 
 
 Create a folder
 ---------------
 
-Create a new folder on the cloud server, the info needed to be sent is the path of the new folder.
+Create a new folder on the cloud server, the info needed to be sent is the path
+of the new folder.
 
 Code example
 ~~~~~~~~~~~~
@@ -215,8 +136,10 @@ Code example
 Read folder
 -----------
 
-Get the content of an existing folder on the cloud server, the info needed to be sent is the path of the folder, in the example shown it has been asked the content of the root folder.
-As answer of this method, it will be received an array with all the files and folders stored in the selected folder.
+Get the content of an existing folder on the cloud server, the info needed to
+be sent is the path of the folder, in the example shown it has been asked the
+content of the root folder.  As answer of this method, it will be received an
+array with all the files and folders stored in the selected folder.
 
 Code example
 ~~~~~~~~~~~~
@@ -292,7 +215,8 @@ Code example
 Read file
 ---------
 
-Get information related to a certain file or folder, information obtained is: : filePath, filename, isDirectory, size and date
+Get information related to a certain file or folder, information obtained is: :
+filePath, filename, isDirectory, size and date
 
 Code example
 ~~~~~~~~~~~~
@@ -362,7 +286,8 @@ Code example
 Delete file or folder
 ---------------------
 
-Delete a file or folder on the cloud server. The info needed is the path of folder/file to be deleted.
+Delete a file or folder on the cloud server. The info needed is the path of
+folder/file to be deleted.
 
 Code example
 ~~~~~~~~~~~~
@@ -428,7 +353,9 @@ Code example
 Download a file
 ---------------
 
-Download an existing file on the cloud server. The info needed is path of the file on the server and targetDirectory, path where the file will be stored on the device.
+Download an existing file on the cloud server. The info needed is path of the
+file on the server and targetDirectory, path where the file will be stored on
+the device.
 
 Code example
 ~~~~~~~~~~~~
@@ -541,14 +468,12 @@ Code example
 |                                                                           |
 +---------------------------------------------------------------------------+
 
-
-
-
-
 Upload a file
 -------------
 
-Upload a new file to the cloud server. The info needed is fileToUpload, path where the file is stored on the device, remotePath, path where the file will be stored on the server and mimeType.
+Upload a new file to the cloud server. The info needed is fileToUpload, path
+where the file is stored on the device, remotePath, path where the file will be
+stored on the server and mimeType.
 
 Code example
 ~~~~~~~~~~~~
@@ -760,7 +685,10 @@ Get the share resources for a given file or folder
 --------------------------------------------------
 
 
-Get information about what files and folder are shared by link on a certain folder. The info needed is filePath, path of the file/folder on the server, the Boolean variable, getReshares, come from the Sharing api, from the moment it is not in use within the ownCloud Android library.
+Get information about what files and folder are shared by link on a certain
+folder. The info needed is filePath, path of the file/folder on the server, the
+Boolean variable, getReshares, come from the Sharing api, from the moment it is
+not in use within the ownCloud Android library.
 
 Code example
 ~~~~~~~~~~~~
@@ -880,8 +808,10 @@ Share link of file or folder
 
 
 Share a file or a folder from your cloud server by link.
-** **
-The info needed is filePath, the path of the item that you want to share and Password, this comes from the Sharing api, from the moment it is not in use within the ownCloud Android library.
+
+The info needed is filePath, the path of the item that you want to share and
+Password, this comes from the Sharing api, from the moment it is not in use
+within the ownCloud Android library.
 
 
 Code example
@@ -1048,7 +978,7 @@ Delete a share resource
 
 
 Stop sharing by link a file or a folder from your cloud server.
-** **
+
 The info needed is the object OCShare that you want to stop sharing by link.
 
 Code example
@@ -1116,49 +1046,10 @@ Code example
 Tips
 ----
 
-
-*   Credentials must be set before calling any method
-
-
-
-
-*   Paths must not be on URL Encoding
-
-
-
-
-* Correct path:
-`http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop>`_
-Music/
-
-* Wrong path:
-`http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/ <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/>`_
-
-
-*   There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud Android Library
-
-
-
-
-"\", "/","<",">",":",""","|","?","*"
-
-
+* Credentials must be set before calling any method
+* Paths must not be on URL Encoding
+* Correct path: `http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop>`_ Music/
+* Wrong path: `http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/ <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/>`_
+* There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud Android Library "\","/","<",">",":",""","|","?","*"
 *   Upload and download actions may be cancelled thanks to the objects uploadOperation.cancel(), downloadOperation.cancel()
-
-
-
-
 *   Unit tests, before launching unit tests you have to enter your account information (server url, user and password) on TestActivity.java
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/developer_manual/android_library/index.rst b/developer_manual/android_library/index.rst
index 08cf79c..8c9a40e 100644
--- a/developer_manual/android_library/index.rst
+++ b/developer_manual/android_library/index.rst
@@ -1,17 +1,24 @@
-|1000000000000270000003A317117674_png|
-**ownCloud Android library**
+.. _androidindex:
 
-Index
+===============================
+Android Application Development
+===============================
 
-.. toctree::
-    :maxdepth: 2
+This document will describe how to the use ownCloud Android Library.  The
+ownCloud Android Library allows a developer to communicate with any ownCloud
+server; among the features included are file synchronization, upload and
+download of files, delete rename files and folders, etc.
+
+This library may be added to a project and seamlessly integrates any
+application with ownCloud.
 
+The tool needed is any IDE for Android. This guide includes some screenshots
+showing examples in Eclipse.
 
-    Introduction
-    Library_Installation
-    EXAMPLES
+.. toctree::
+   :maxdepth: 1
+   :hidden:
 
-.. |1000000000000270000003A317117674_png| image:: images/1000000000000270000003A317117674.png
-    :width: 10.794cm
-    :height: 16.107cm
+   library_installation
+   examples
 
diff --git a/developer_manual/android_library/Library_Installation.rst b/developer_manual/android_library/library_installation.rst
similarity index 99%
rename from developer_manual/android_library/Library_Installation.rst
rename to developer_manual/android_library/library_installation.rst
index 8d38a9c..d22c2ef 100644
--- a/developer_manual/android_library/Library_Installation.rst
+++ b/developer_manual/android_library/library_installation.rst
@@ -39,4 +39,3 @@ Then all the public classes and methods of the library will be available for you
 .. |1000000000000270000003A317117674_png| image:: images/1000000000000270000003A317117674.png
     :width: 10.795cm
     :height: 16.106cm
-
diff --git a/developer_manual/contents.rst b/developer_manual/contents.rst
index 8089411..388fb9f 100644
--- a/developer_manual/contents.rst
+++ b/developer_manual/contents.rst
@@ -18,6 +18,8 @@ ownCloud documentation contents
     testing/index
     bugtracker/index
     commun/index
+    android_library/index
+    ios_library/index
 
 Indices and tables
 ==================
diff --git a/developer_manual/index.rst b/developer_manual/index.rst
index 917b0ad..8c29833 100644
--- a/developer_manual/index.rst
+++ b/developer_manual/index.rst
@@ -6,23 +6,23 @@ Developer Documentation
 
 If you want to contribute please read the `Contributor agreement <http://owncloud.org/about/contributor-agreement/>`_
 
-+-------------------------+-------------------------+--------------------------+
-|:doc:`app/index`         |:doc:`core/index`        |`Documentation`_          |
-| Develop apps for        | Develop on the ownCloud | Create and enhance       |
-| ownCloud and publish on | internals               | documentation            |
-| the `ownCloud appstore`_|                         |                          |
-+-------------------------+-------------------------+--------------------------+
-|:doc:`testing/index`     |:doc:`bugtracker/index`  |`Translation`_            |
-| Help us to test         | Report, triage or fix   | Translate ownCloud into  |
-| ownCloud by joining the | bugs to improve quality | your language            |
-| testing team            |                         |                          |
-|                         |                         |                          |
-|                         |                         |                          |
-+-------------------------+-------------------------+--------------------------+
-|:doc:`commun/index`      |                         |                          |
-| Help on IRC, the        |                         |                          |
-| mailinglist and forum   |                         |                          |
-+-------------------------+-------------------------+--------------------------+
++-------------------------+-------------------------+-----------------------------+
+|:doc:`app/index`         |:doc:`core/index`        |`Documentation`_             |
+| Develop apps for        | Develop on the ownCloud | Create and enhance          |
+| ownCloud and publish on | internals               | documentation               |
+| the `ownCloud appstore`_|                         |                             |
++-------------------------+-------------------------+-----------------------------+
+|:doc:`testing/index`     |:doc:`bugtracker/index`  |`Translation`_               |
+| Help us to test         | Report, triage or fix   | Translate ownCloud into     |
+| ownCloud by joining the | bugs to improve quality | your language               |
+| testing team            |                         |                             |
+|                         |                         |                             |
+|                         |                         |                             |
++-------------------------+-------------------------+-----------------------------+
+|:doc:`commun/index`      |:doc:`ios_library/index` |:doc:`android_library/index` |
+| Help on IRC, the        | Use ownCloud in iOS apps| Use ownCloud in Android     |
+| mailinglist and forum   |                         | apps                        |
++-------------------------+-------------------------+-----------------------------+
 
 .. _ownCloud appstore: http://apps.owncloud.com/
 .. _Translation: https://www.transifex.com/projects/p/owncloud/
diff --git a/developer_manual/ios_library/EXAMPLES.rst b/developer_manual/ios_library/EXAMPLES.rst
deleted file mode 100644
index ddc3c4d..0000000
--- a/developer_manual/ios_library/EXAMPLES.rst
+++ /dev/null
@@ -1,1537 +0,0 @@
-EXAMPLES
-========
-
-Init the library
-----------------
-
-Start using the library, it is needed to init the object OCCommunication.
-
-We recommend using the
-singleton method in the AppDelegate class in order to use the
-ownCloud iOS library
-.
-
-Code example
-~~~~~~~~~~~~
-
-
-+----------------------------+
-| #import                    |
-| "OCCommunication.h"        |
-|                            |
-| + (                        |
-| OCCommunication            |
-| *)sharedOCCommunication    |
-|                            |
-| {                          |
-|                            |
-| static                     |
-|                            |
-| OCCommunication            |
-| * sharedOCCommunication =  |
-| nil                        |
-| ;                          |
-|                            |
-| if                         |
-| (sharedOCCommunication ==  |
-| nil                        |
-| )                          |
-|                            |
-| {                          |
-|                            |
-| sharedOCCommunication = [[ |
-| OCCommunication            |
-|                            |
-| alloc                      |
-| ]                          |
-| init                       |
-| ];                         |
-|                            |
-| }                          |
-|                            |
-| return                     |
-| sharedOCCommunication;     |
-|                            |
-| }                          |
-|                            |
-+----------------------------+
-
-
-Set credentials
----------------
-
-Authentication on the app is possible by 3 different methods:
-
-*   Basic authentication, user name and password
-
-
-
-*   Cookie
-
-
-
-*   Token (oAuth)
-
-
-
-Code example
-~~~~~~~~~~~~
-
-
-+-----------------------------------------------+
-| #Basic authentication, user name and password |
-|                                               |
-| [[                                            |
-| AppDelegate                                   |
-|                                               |
-| sharedOCCommunication                         |
-| ]                                             |
-| setCredentialsWithUser                        |
-| :                                             |
-| userName                                      |
-|                                               |
-| andPassword                                   |
-| :                                             |
-| password                                      |
-| ];                                            |
-|                                               |
-|                                               |
-|                                               |
-| #Authentication with cookie                   |
-|                                               |
-| [[                                            |
-| AppDelegate                                   |
-|                                               |
-| sharedOCCommunication                         |
-| ]                                             |
-| setCredentialsWithCookie                      |
-| :                                             |
-| cookie                                        |
-| ];                                            |
-|                                               |
-|                                               |
-|                                               |
-| #Authentication with token                    |
-|                                               |
-| [[                                            |
-| AppDelegate                                   |
-|                                               |
-| sharedOCCommunication                         |
-| ]                                             |
-| setCredentialsOauthWithToken                  |
-| :                                             |
-| token                                         |
-| ];                                            |
-|                                               |
-+-----------------------------------------------+
-
-
-
-Create a folder
----------------
-
-Create a new folder on the cloud server, the info needed to be sent is the path of the new folder.
-
-Code example
-~~~~~~~~~~~~
-
-+----------------------------+
-| [[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| createFolder               |
-| :path                      |
-| onCommunication            |
-| :[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| successRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSString                   |
-|                            |
-| *redirectedServer) {       |
-|                            |
-| //Folder Created           |
-|                            |
-| }                          |
-| failureRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSError                    |
-|                            |
-| *error) {                  |
-|                            |
-| //Failure                  |
-|                            |
-| switch                     |
-|                            |
-| (response.                 |
-| statusCode                 |
-| ) {                        |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerUnauthorized |
-| :                          |
-|                            |
-| //Bad credentials          |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerForbidden    |
-| :                          |
-|                            |
-| //Forbidden                |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerPathNotFound |
-| :                          |
-|                            |
-| //Not Found                |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerTimeout      |
-| :                          |
-|                            |
-| //timeout                  |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| default:                   |
-|                            |
-| //default                  |
-|                            |
-| break;                     |
-|                            |
-| }                          |
-|                            |
-| }                          |
-| errorBeforeRequest         |
-| :^(                        |
-| NSError                    |
-|                            |
-| *error) {                  |
-|                            |
-| //Error before request     |
-|                            |
-| if (error.                 |
-| code                       |
-|                            |
-| ==                         |
-| OCErrorForbidenCharacters  |
-| ) {                        |
-|                            |
-| //Forbidden characters     |
-|                            |
-| }                          |
-| else                       |
-|                            |
-| {                          |
-|                            |
-| //Other error              |
-|                            |
-| }                          |
-|                            |
-| }];                        |
-|                            |
-|                            |
-+----------------------------+
-
-
-Read folder
------------
-
-Get the content of an existing folder on the cloud server, the info needed to be sent is the path of the folder.
-As answer of this method, it will be received an array with all the files and folders stored in the selected folder.
-
-Code example
-~~~~~~~~~~~~
-
-
-+----------------------------------------------------------+
-| [[                                                       |
-| AppDelegate                                              |
-|                                                          |
-| sharedOCCommunication] readFolder:path onCommunication:[ |
-| AppDelegate                                              |
-|                                                          |
-| sharedOCCommunication] successRequest:^(                 |
-| NSHTTPURLResponse                                        |
-|                                                          |
-| *response,                                               |
-| NSArray                                                  |
-|                                                          |
-| *items,                                                  |
-| NSString                                                 |
-|                                                          |
-| *redirectedServer) {                                     |
-|                                                          |
-| //Success                                                |
-|                                                          |
-| for                                                      |
-|                                                          |
-| (                                                        |
-| OCFileDto                                                |
-|                                                          |
-| * ocFileDto                                              |
-| in                                                       |
-|                                                          |
-| items) {                                                 |
-|                                                          |
-| NSLog(                                                   |
-| @"item path: %@%@"                                       |
-| , ocFileDto.filePath, ocFileDto.fileName);               |
-|                                                          |
-| }                                                        |
-|                                                          |
-| } failureRequest:^(                                      |
-| NSHTTPURLResponse                                        |
-|                                                          |
-| *response,                                               |
-| NSError                                                  |
-|                                                          |
-| *error) {                                                |
-|                                                          |
-| //Failure                                                |
-|                                                          |
-| switch                                                   |
-|                                                          |
-| (response.                                               |
-| statusCode                                               |
-| ) {                                                      |
-|                                                          |
-| case                                                     |
-|                                                          |
-| kOCErrorServerPathNotFound                               |
-| :                                                        |
-|                                                          |
-| //Path not found                                         |
-|                                                          |
-| break                                                    |
-| ;                                                        |
-|                                                          |
-| case                                                     |
-|                                                          |
-| kOCErrorServerUnauthorized                               |
-| :                                                        |
-|                                                          |
-| //Bad credentials                                        |
-|                                                          |
-| break                                                    |
-| ;                                                        |
-|                                                          |
-| case                                                     |
-|                                                          |
-| kOCErrorServerForbidden                                  |
-| :                                                        |
-|                                                          |
-| //Forbidden                                              |
-|                                                          |
-| break                                                    |
-| ;                                                        |
-|                                                          |
-| case                                                     |
-|                                                          |
-| kOCErrorServerTimeout                                    |
-| :                                                        |
-|                                                          |
-| //Timeout                                                |
-|                                                          |
-| break                                                    |
-| ;                                                        |
-|                                                          |
-| default                                                  |
-| :                                                        |
-|                                                          |
-| break;                                                   |
-|                                                          |
-| }                                                        |
-|                                                          |
-| }];                                                      |
-|                                                          |
-+----------------------------------------------------------+
-
-
-
-
-Read file
----------
-
-Get information related to a certain file or folder. Although, more information can be obtained, the library only gets the eTag.
-
-Other properties of the file or folder may be obtained: filePath, filename, isDirectory, size and date
-
-Code example
-~~~~~~~~~~~~
-
-
-+----------------------------+
-| [[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| readFile                   |
-| :path                      |
-| onCommunication            |
-| :[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| successRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSArray                    |
-|                            |
-| *items,                    |
-| NSString                   |
-|                            |
-| *redirectedServer) {       |
-|                            |
-| OCFileDto                  |
-|                            |
-| *ocFileDto = [items        |
-| objectAtIndex              |
-| :                          |
-| 0                          |
-| ];                         |
-|                            |
-| NSLog                      |
-| (                          |
-| @"item etag: %lld"         |
-| , ocFileDto.               |
-| etag                       |
-| );                         |
-|                            |
-| }                          |
-| failureRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSError                    |
-|                            |
-| *error) {                  |
-|                            |
-| switch                     |
-|                            |
-| (response.statusCode) {    |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerPathNotFound |
-| :                          |
-|                            |
-| //Path not found           |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerUnauthorized |
-| :                          |
-|                            |
-| //Bad credentials          |
-|                            |
-| break;                     |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerForbidden    |
-| :                          |
-|                            |
-| //Forbidden                |
-|                            |
-| break;                     |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerTimeout      |
-| :                          |
-|                            |
-| //Timeout                  |
-|                            |
-| break;                     |
-|                            |
-| default:                   |
-|                            |
-| break;                     |
-|                            |
-| }                          |
-|                            |
-| }];                        |
-|                            |
-+----------------------------+
-
-
-Move file or folder
--------------------
-
-
-Move a file or folder from their current path to a new one on the cloud server. The info needed is the origin path and the destiny path.
-
-
-Code example
-~~~~~~~~~~~~
-
-
-+-------------------------------------------------+
-|                                                 |
-| [[                                              |
-| AppDelegate                                     |
-|                                                 |
-| sharedOCCommunication                           |
-| ]                                               |
-| moveFileOrFolder                                |
-| :sourcePath                                     |
-| toDestiny                                       |
-| :destinyPath                                    |
-| onCommunication                                 |
-| :[                                              |
-| AppDelegate                                     |
-|                                                 |
-| sharedOCCommunication                           |
-| ]                                               |
-| successRequest                                  |
-| :^(                                             |
-| NSHTTPURLResponse                               |
-|                                                 |
-| *response,                                      |
-| NSString                                        |
-|                                                 |
-| *redirectedServer) {                            |
-|                                                 |
-| //File/Folder moved or renamed                  |
-|                                                 |
-| }                                               |
-| failureRequest                                  |
-| :^(                                             |
-| NSHTTPURLResponse                               |
-|                                                 |
-| *response,                                      |
-| NSError                                         |
-|                                                 |
-| *error) {                                       |
-|                                                 |
-| //Failure                                       |
-|                                                 |
-| switch                                          |
-|                                                 |
-| (response.                                      |
-| statusCode                                      |
-| ) {                                             |
-|                                                 |
-| case                                            |
-|                                                 |
-| kOCErrorServerPathNotFound                      |
-| :                                               |
-|                                                 |
-| //Path not found                                |
-|                                                 |
-| break                                           |
-| ;                                               |
-|                                                 |
-| case                                            |
-|                                                 |
-| kOCErrorServerUnauthorized                      |
-| :                                               |
-|                                                 |
-| //Bad credentials                               |
-|                                                 |
-| break                                           |
-| ;                                               |
-|                                                 |
-| case                                            |
-|                                                 |
-| kOCErrorServerForbidden                         |
-| :                                               |
-|                                                 |
-| //Forbidden                                     |
-|                                                 |
-| break;                                          |
-|                                                 |
-| case                                            |
-|                                                 |
-| kOCErrorServerTimeout                           |
-| :                                               |
-|                                                 |
-| //Timeout                                       |
-|                                                 |
-| break;                                          |
-|                                                 |
-| default:                                        |
-|                                                 |
-| break;                                          |
-|                                                 |
-| }                                               |
-|                                                 |
-| }                                               |
-| errorBeforeRequest                              |
-| :^(                                             |
-| NSError                                         |
-|                                                 |
-| *error) {                                       |
-|                                                 |
-| if                                              |
-|                                                 |
-| (error.                                         |
-| code                                            |
-|                                                 |
-| ==                                              |
-| OCErrorMovingTheDestinyAndOriginAreTheSame      |
-| ) {                                             |
-|                                                 |
-| //The destiny and the origin are the same       |
-|                                                 |
-| }                                               |
-| else                                            |
-|                                                 |
-| if                                              |
-|                                                 |
-| (error.                                         |
-| code                                            |
-|                                                 |
-| ==                                              |
-| OCErrorMovingFolderInsideHimself                |
-| ) {                                             |
-|                                                 |
-| //Moving folder inside himself                  |
-|                                                 |
-| }                                               |
-| else                                            |
-|                                                 |
-| if                                              |
-|                                                 |
-| (error.                                         |
-| code                                            |
-|                                                 |
-| ==                                              |
-| OCErrorMovingDestinyNameHaveForbiddenCharacters |
-| )                                               |
-|                                                 |
-| {                                               |
-|                                                 |
-| //Forbidden Characters                          |
-|                                                 |
-| }                                               |
-| else                                            |
-|                                                 |
-| {                                               |
-|                                                 |
-| *//Default*                                     |
-|                                                 |
-| }                                               |
-|                                                 |
-| }];                                             |
-|                                                 |
-+-------------------------------------------------+
-
-
-Delete file or folder
----------------------
-
-Delete a file or folder on the cloud server. The info needed is the path to delete.
-
-Code example
-~~~~~~~~~~~~
-
-+----------------------------+
-|                            |
-| [[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| deleteFileOrFolder         |
-| :path                      |
-| onCommunication            |
-| :[                         |
-| AppDelegate                |
-|                            |
-| sharedOCCommunication      |
-| ]                          |
-| successRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSString                   |
-|                            |
-| *redirectedServer) {       |
-|                            |
-| //File or Folder deleted   |
-|                            |
-| }                          |
-| failureRequest             |
-| :^(                        |
-| NSHTTPURLResponse          |
-|                            |
-| *response,                 |
-| NSError                    |
-|                            |
-| *error) {                  |
-|                            |
-| switch                     |
-|                            |
-| (response.statusCode) {    |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerPathNotFound |
-| :                          |
-|                            |
-| //Path not found           |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerUnauthorized |
-| :                          |
-|                            |
-| //Bad credentials          |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerForbidden    |
-| :                          |
-|                            |
-| //Forbidden                |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| case                       |
-|                            |
-| kOCErrorServerTimeout      |
-| :                          |
-|                            |
-| //Timeout                  |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| default                    |
-| :                          |
-|                            |
-| break                      |
-| ;                          |
-|                            |
-| }                          |
-|                            |
-| }];                        |
-|                            |
-+----------------------------+
-
-
-Download a file
----------------
-
-Download an existing file on the cloud server. The info needed is the server URL, path of the file on the server and localPath, path where the file will be stored on the device.
-
-Code example
-~~~~~~~~~~~~
-
-
-+---------------------------------------------------------------+
-|                                                               |
-| __block                                                       |
-|                                                               |
-| NSOperation                                                   |
-|                                                               |
-| *op =                                                         |
-| nil                                                           |
-| ;                                                             |
-|                                                               |
-| op = [[                                                       |
-| AppDelegate                                                   |
-|                                                               |
-| sharedOCCommunication                                         |
-| ]                                                             |
-| downloadFile                                                  |
-| :remotePath                                                   |
-| toDestiny                                                     |
-| :localPath                                                    |
-| onCommunication                                               |
-| :[                                                            |
-| AppDelegate                                                   |
-|                                                               |
-| sharedOCCommunication                                         |
-| ]                                                             |
-|                                                               |
-| progressDownload                                              |
-| :^(                                                           |
-| NSUInteger                                                    |
-|                                                               |
-| bytesRead,                                                    |
-| long                                                          |
-|                                                               |
-| long                                                          |
-|                                                               |
-| totalBytesRead,                                               |
-| long                                                          |
-|                                                               |
-| long                                                          |
-|                                                               |
-| totalBytesExpectedToRead) {                                   |
-|                                                               |
-| //Calculate percent                                           |
-|                                                               |
-| float                                                         |
-|                                                               |
-| percent = (                                                   |
-| float                                                         |
-| )totalBytesRead / totalBytesExpectedToRead;                   |
-|                                                               |
-| NSLog                                                         |
-| (                                                             |
-| @"Percent of download: %f"                                    |
-| , percent);                                                   |
-|                                                               |
-| }                                                             |
-| successRequest                                                |
-| :^(NSHTTPURLResponse *response, NSString *redirectedServer) { |
-|                                                               |
-| //Donwload complete                                           |
-|                                                               |
-| }                                                             |
-| failureRequest                                                |
-| :^(NSHTTPURLResponse *response, NSError *error) {             |
-|                                                               |
-| switch                                                        |
-|                                                               |
-| (response.                                                    |
-| statusCode                                                    |
-| ) {                                                           |
-|                                                               |
-| case                                                          |
-|                                                               |
-| kOCErrorServerUnauthorized                                    |
-| :                                                             |
-|                                                               |
-| //Bad credentials                                             |
-|                                                               |
-| break                                                         |
-| ;                                                             |
-|                                                               |
-| case                                                          |
-|                                                               |
-| kOCErrorServerForbidden                                       |
-| :                                                             |
-|                                                               |
-| //Forbidden                                                   |
-|                                                               |
-| break                                                         |
-| ;                                                             |
-|                                                               |
-| case                                                          |
-|                                                               |
-| kOCErrorProxyAuth                                             |
-| :                                                             |
-|                                                               |
-| //Proxy access required                                       |
-|                                                               |
-| break                                                         |
-| ;                                                             |
-|                                                               |
-| case                                                          |
-|                                                               |
-| kOCErrorServerPathNotFound                                    |
-| :                                                             |
-|                                                               |
-| //Path not found                                              |
-|                                                               |
-| break;                                                        |
-|                                                               |
-| default:                                                      |
-|                                                               |
-| //Default                                                     |
-|                                                               |
-| break;                                                        |
-|                                                               |
-| }                                                             |
-|                                                               |
-| }                                                             |
-| shouldExecuteAsBackgroundTaskWithExpirationHandler            |
-| :^{                                                           |
-|                                                               |
-| [op                                                           |
-| cancel                                                        |
-| ];                                                            |
-|                                                               |
-| }];                                                           |
-|                                                               |
-|                                                               |
-+---------------------------------------------------------------+
-
-
-
-
-Upload a file
--------------
-
-Upload a new file to the cloud server. The info needed is localPath, path where the file is stored on the device and server URL, path where the file will be stored on the server.
-
-Code example
-~~~~~~~~~~~~
-
-+----------------------------------------------------+
-| __block                                            |
-|                                                    |
-| NSOperation                                        |
-|                                                    |
-| *op =                                              |
-| nil                                                |
-| ;                                                  |
-|                                                    |
-| op = [[                                            |
-| AppDelegate                                        |
-|                                                    |
-| sharedOCCommunication                              |
-| ]                                                  |
-| uploadFile                                         |
-| :localPath                                         |
-| toDestiny                                          |
-| : remotePath                                       |
-| onCommunication                                    |
-| :[                                                 |
-| AppDelegate                                        |
-|                                                    |
-| sharedOCCommunication                              |
-| ]                                                  |
-|                                                    |
-| progressUpload                                     |
-| :^(                                                |
-| NSUInteger                                         |
-|                                                    |
-| bytesWrote,                                        |
-| long                                               |
-|                                                    |
-| long                                               |
-|                                                    |
-| totalBytesWrote,                                   |
-| long                                               |
-|                                                    |
-| long                                               |
-|                                                    |
-| totalBytesExpectedToWrite) {                       |
-|                                                    |
-| //Calculate upload percent                         |
-|                                                    |
-| if                                                 |
-|                                                    |
-| ( totalBytesExpectedToRead/                        |
-| 1024                                               |
-|                                                    |
-| !=                                                 |
-| 0                                                  |
-| ) {                                                |
-|                                                    |
-| if                                                 |
-|                                                    |
-| ( bytesWrote >                                     |
-| 0                                                  |
-| ) {                                                |
-|                                                    |
-| float                                              |
-|                                                    |
-| percent = totalBytesWrote*                         |
-| 100                                                |
-| / totalBytesExpectedToRead;                        |
-|                                                    |
-| NSLog                                              |
-| (                                                  |
-| @"Percent: %f"                                     |
-| , percent);                                        |
-|                                                    |
-| }                                                  |
-|                                                    |
-| }                                                  |
-|                                                    |
-| }                                                  |
-| successRequest                                     |
-| :^(                                                |
-| NSHTTPURLResponse                                  |
-|                                                    |
-| *response) {                                       |
-|                                                    |
-| //Upload complete                                  |
-|                                                    |
-| }                                                  |
-| failureRequest                                     |
-| :^(                                                |
-| NSHTTPURLResponse                                  |
-|                                                    |
-| *response,                                         |
-| NSString                                           |
-|                                                    |
-| *redirectedServer,                                 |
-| NSError                                            |
-|                                                    |
-| *error) {                                          |
-|                                                    |
-| switch                                             |
-|                                                    |
-| (response.                                         |
-| statusCode                                         |
-| ) {                                                |
-|                                                    |
-| case                                               |
-|                                                    |
-| kOCErrorServerUnauthorized                         |
-| :                                                  |
-|                                                    |
-| //Bad credentials                                  |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| case                                               |
-|                                                    |
-| kOCErrorServerForbidden                            |
-| :                                                  |
-|                                                    |
-| //Forbidden                                        |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| case                                               |
-|                                                    |
-| kOCErrorProxyAuth                                  |
-| :                                                  |
-|                                                    |
-| //Proxy access required                            |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| case                                               |
-|                                                    |
-| kOCErrorServerPathNotFound                         |
-| :                                                  |
-|                                                    |
-| //Path not found                                   |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| default                                            |
-| :                                                  |
-|                                                    |
-| //Default                                          |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| }                                                  |
-|                                                    |
-| }                                                  |
-| failureBeforeRequest                               |
-| :^(                                                |
-| NSError                                            |
-|                                                    |
-| *error) {                                          |
-|                                                    |
-| switch                                             |
-|                                                    |
-| (error.c                                           |
-| ode                                                |
-| ) {                                                |
-|                                                    |
-| case                                               |
-|                                                    |
-| OCErrorFileToUploadDoesNotExist                    |
-| :                                                  |
-|                                                    |
-| //File does not exist                              |
-|                                                    |
-| break                                              |
-| ;                                                  |
-|                                                    |
-| default                                            |
-| :                                                  |
-|                                                    |
-| //Default                                          |
-|                                                    |
-| break                                              |
-| ;}                                                 |
-|                                                    |
-| }                                                  |
-| shouldExecuteAsBackgroundTaskWithExpirationHandler |
-| :^{                                                |
-|                                                    |
-| [op                                                |
-| cancel                                             |
-| ];                                                 |
-|                                                    |
-| }];                                                |
-|                                                    |
-+----------------------------------------------------+
-
-
-Check if the server supports Sharing api
-----------------------------------------
-
-
-The S
-haring API is included in ownCloud 5.0.13 and greater versions. The info needed is activeUser.url, the server URL that you want to check.
-
-Code Example
-~~~~~~~~~~~~
-
-+-----------------------+
-| [[                    |
-| AppDelegate           |
-|                       |
-| sharedOCCommunication |
-| ]                     |
-| hasServerShareSupport |
-| :_activeUser.url      |
-| onCommunication       |
-| :[                    |
-|                       |
-| AppDelegate           |
-|                       |
-| sharedOCCommunication |
-| ]                     |
-| successRequest        |
-| :^(                   |
-|                       |
-| NSHTTPURLResponse     |
-|                       |
-| *response,            |
-|                       |
-| BOOL                  |
-| hasSupport,           |
-| NSString              |
-|                       |
-| *redirectedServer) {  |
-|                       |
-|                       |
-| }                     |
-| failureRequest        |
-| :^(                   |
-| NSHTTPURLResponse     |
-|                       |
-| *response,            |
-| NSError               |
-|                       |
-| *error){              |
-|                       |
-|                       |
-| }];                   |
-|                       |
-| }                     |
-|                       |
-+-----------------------+
-
-
-Read shared items by link
--------------------------
-
-Get information about what files and folder are shared by link.
-
-The info needed is Path, the server URL that you want to check.
-
-Code example
-~~~~~~~~~~~~
-
-+-------------------------+
-| [[                      |
-| AppDelegate             |
-|                         |
-| sharedOCCommunication   |
-| ]                       |
-| readSharedByServer      |
-| :path                   |
-| onCommunication         |
-| :[                      |
-| AppDelegate             |
-|                         |
-| sharedOCCommunication   |
-| ]                       |
-| successRequest          |
-| :^(                     |
-| NSHTTPURLResponse       |
-|                         |
-| *response,              |
-| NSArray                 |
-|                         |
-| *items,                 |
-| NSString                |
-|                         |
-| *redirectedServer) {    |
-|                         |
-| NSLog                   |
-| (                       |
-| @"Item: %d"             |
-| , items);               |
-|                         |
-| }                       |
-| failureRequest          |
-| :^(                     |
-| NSHTTPURLResponse       |
-|                         |
-| *response,              |
-| NSError                 |
-|                         |
-| *error){                |
-|                         |
-|                         |
-| NSLog                   |
-| (                       |
-| @"error: %@"            |
-| , error);               |
-|                         |
-| NSLog                   |
-| (                       |
-| @"Operation error: %d"  |
-| , response.statusCode); |
-|                         |
-| }];                     |
-|                         |
-+-------------------------+
-
-
-Share link of file or folder
-----------------------------
-
-
-Share a file or a folder from your cloud server by link.
-** **
-The info needed is Path, your server URL and the path of the item that you want to share (for example, “/folder/file.pdf)
-
-
-Code example
-~~~~~~~~~~~~
-
-
-+-------------------------------------------------------------------------------------+
-| [[                                                                                  |
-| AppDelegate                                                                         |
-|                                                                                     |
-| sharedOCCommunication                                                               |
-| ]                                                                                   |
-| shareFileOrFolderByServer                                                           |
-| :path                                                                               |
-|                                                                                     |
-| andFileOrFolderPath                                                                 |
-| :itemPath                                                                           |
-|                                                                                     |
-| onCommunication                                                                     |
-| :[                                                                                  |
-| AppDelegate                                                                         |
-|                                                                                     |
-| sharedOCCommunication                                                               |
-| ]                                                                                   |
-| successRequest                                                                      |
-| :^(                                                                                 |
-| NSHTTPURLResponse                                                                   |
-|                                                                                     |
-| *response,                                                                          |
-| NSString                                                                            |
-|                                                                                     |
-| *token,                                                                             |
-| NSString                                                                            |
-|                                                                                     |
-| *redirectedServer) {                                                                |
-|                                                                                     |
-| NSString                                                                            |
-|                                                                                     |
-| *sharedLink = [                                                                     |
-| NSString                                                                            |
-|                                                                                     |
-| stringWithFormat:@                                                                  |
-| `path/public.php?service=files&t=%@ <mailto:path/public.php?service=files&t=%25@>`_ |
-| , token];                                                                           |
-|                                                                                     |
-|                                                                                     |
-| }                                                                                   |
-| failureRequest                                                                      |
-| :^(                                                                                 |
-| NSHTTPURLResponse                                                                   |
-|                                                                                     |
-| *response,                                                                          |
-| NSError                                                                             |
-|                                                                                     |
-| *error){                                                                            |
-|                                                                                     |
-| [                                                                                   |
-| _delegate                                                                           |
-|                                                                                     |
-| endLoading                                                                          |
-| ];                                                                                  |
-|                                                                                     |
-|                                                                                     |
-| DLog                                                                                |
-| (                                                                                   |
-| @”error.code: %d”                                                                   |
-| ,                                                                                   |
-|                                                                                     |
-| error.                                                                              |
-| code                                                                                |
-| );                                                                                  |
-|                                                                                     |
-| DLog                                                                                |
-|                                                                                     |
-| (@”server.error: %d”,                                                               |
-| response.                                                                           |
-| statusCode                                                                          |
-| );                                                                                  |
-|                                                                                     |
-| int                                                                                 |
-|                                                                                     |
-| code = response.                                                                    |
-| statusCode                                                                          |
-| ;                                                                                   |
-|                                                                                     |
-| if (error.                                                                          |
-| code                                                                                |
-|                                                                                     |
-| ==                                                                                  |
-| kOCErrorServerPathNotFound                                                          |
-| ) {                                                                                 |
-|                                                                                     |
-|                                                                                     |
-| }                                                                                   |
-|                                                                                     |
-| switch                                                                              |
-|                                                                                     |
-| (code) {                                                                            |
-|                                                                                     |
-| case                                                                                |
-|                                                                                     |
-| kOCErrorServerPathNotFound                                                          |
-| :                                                                                   |
-|                                                                                     |
-| //File to share not exists                                                          |
-|                                                                                     |
-| break                                                                               |
-| ;                                                                                   |
-|                                                                                     |
-| case                                                                                |
-|                                                                                     |
-| kOCErrorServerUnauthorized                                                          |
-| :                                                                                   |
-|                                                                                     |
-| //Error login                                                                       |
-|                                                                                     |
-| break                                                                               |
-| ;                                                                                   |
-|                                                                                     |
-| case                                                                                |
-|                                                                                     |
-| kOCErrorServerForbidden                                                             |
-| :                                                                                   |
-|                                                                                     |
-| //Permission error                                                                  |
-|                                                                                     |
-| break                                                                               |
-| ;                                                                                   |
-|                                                                                     |
-| case                                                                                |
-|                                                                                     |
-| kOCErrorServerTimeout                                                               |
-| :                                                                                   |
-|                                                                                     |
-| //Not possible to connect to server                                                 |
-|                                                                                     |
-| break                                                                               |
-| ;                                                                                   |
-|                                                                                     |
-| default                                                                             |
-| :                                                                                   |
-|                                                                                     |
-| if (error.                                                                          |
-| code                                                                                |
-|                                                                                     |
-| ==                                                                                  |
-| kOCErrorServerPathNotFound                                                          |
-| ) {                                                                                 |
-|                                                                                     |
-| //File to share not exists                                                          |
-|                                                                                     |
-| } else {                                                                            |
-|                                                                                     |
-| //Not possible to connect to the server                                             |
-|                                                                                     |
-| }                                                                                   |
-|                                                                                     |
-| break                                                                               |
-| ;                                                                                   |
-|                                                                                     |
-| }                                                                                   |
-|                                                                                     |
-| }];                                                                                 |
-|                                                                                     |
-| }                                                                                   |
-|                                                                                     |
-| NSLog                                                                               |
-| (                                                                                   |
-| @"error: %@"                                                                        |
-| , error);                                                                           |
-|                                                                                     |
-| NSLog                                                                               |
-| (                                                                                   |
-| @"Operation error: %d"                                                              |
-| , response.statusCode);                                                             |
-|                                                                                     |
-| }];                                                                                 |
-|                                                                                     |
-|                                                                                     |
-+-------------------------------------------------------------------------------------+
-
-
-Unshare a folder or file by link
---------------------------------
-
-
-Stop sharing by link a file or a folder from your cloud server.
-** **
-
-The info needed is Path, your server URL and the Id of the item that you want to Unshare.
-
-Before unsharing an item, you have to read the shared items on the selected server, using the method “
-readSharedByServer
-” so that you get the array “items” with all the shared elements.
-These are objects OCShareDto, one of their properties is idRemoteShared, parameter needed to unshared an element.
-
-Code example
-~~~~~~~~~~~~
-
-
-+-----------------------------+
-| [[                          |
-| AppDelegate                 |
-|                             |
-| sharedOCCommunication       |
-| ]                           |
-| unShareFileOrFolderByServer |
-| :path                       |
-|                             |
-| andIdRemoteSharedShared     |
-| :sharedByLink.              |
-| idRemoteShared              |
-|                             |
-| onCommunication             |
-| :[                          |
-| AppDelegate                 |
-|                             |
-| sharedOCCommunication       |
-| ]                           |
-| successRequest              |
-| :^(                         |
-| NSHTTPURLResponse           |
-|                             |
-| *response,                  |
-| NSString                    |
-|                             |
-| *redirectedServer) {        |
-|                             |
-| //File unshared             |
-|                             |
-| }                           |
-| failureRequest              |
-| :^(                         |
-| NSHTTPURLResponse           |
-|                             |
-| *response,                  |
-| NSError                     |
-|                             |
-| *error){                    |
-|                             |
-| //Error                     |
-|                             |
-| }];                         |
-|                             |
-+-----------------------------+
-
-
-
-
-
-Tips
-----
-
-
-*   Credentials must be set before calling any method
-
-
-
-
-*   Paths must not be on URL Encoding
-
-
-
-
-* Correct path:
-`http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop>`_
-Music/
-
-* Wrong path:
-`http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/ <http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/>`_
-
-
-*   There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud iOS library
-
-
-
-
-"\", "/","<",">",":",""","|","?","*"
-
-
-*   To move a folder the origin path and the destination path must end with “/”
-
-
-
-
-*   To move a file the origin path and the destination path must not end with “/”
-
-
-
-
-*   Upload and download actions may be cancelled thanks to the object “NSOperation”
-
-
-
-
-*   Unit tests, before launching unit tests you have to enter your account information (server url, user and password) on OCCommunicationLibTests.m
-
-
-
-
-
-
-
-
-
diff --git a/developer_manual/ios_library/Introduction.rst b/developer_manual/ios_library/Introduction.rst
deleted file mode 100644
index 5a592c5..0000000
--- a/developer_manual/ios_library/Introduction.rst
+++ /dev/null
@@ -1,10 +0,0 @@
-Introduction
-============
-
-
-This document will describe how to the use ownCloud iOS library.
-The ownCloud iOS library for iOS allows a developer to communicate with any ownCloud server; among the features included are file synchronization, upload and download of files, delete rename and move of files and folders and share files or folders by link among others.
-
-This library may be added to a project and seamlessly integrates any application with ownCloud.
-
-The tool needed is xCode5, this guide includes some screenshots showing examples in xCode5.
diff --git a/developer_manual/ios_library/Library_Installation.rst b/developer_manual/ios_library/Library_Installation.rst
deleted file mode 100644
index 49e9058..0000000
--- a/developer_manual/ios_library/Library_Installation.rst
+++ /dev/null
@@ -1,203 +0,0 @@
-Library Installation
-====================
-
-Obtaining the library
----------------------
-
-The ownCloud iOS library may be obtained from the following Github repository:
-
-`git at github.com:owncloud/ios-library.git <mailto:git at github.com:owncloud/ios-library.git>`_
-
-Once obtained, this code should be compiled with Xcode 5.
-The Github repository not only contains the library, ownCloud iOS library, but also contains a sample project, OCLibraryExample, which will assist in learning how to use the library.
-
-Add the library to a project
-----------------------------
-
-There are two methods to add this library to a project.
-
-*   
-    *   
-        *   Reference the headers and library binary file (.a) directly.
-
-
-
-        *   Include the library as a subproject.
-
-
-
-
-
-
-
-Which method to choose depends on user preference as well as whether the source code and project file of the static library are available.
-
-Reference headers and library binary files
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Follow these steps if this is the desired method.
-
-#.  Compile the ownCloud iOS library and run the project.
-    A libownCloudiOS.a file will be generated.
-
-
-
-The following files are required:
-
-**Library file**
-
-*   libownCloudiOS.a (Library)
-
-
-
-
-
-**Library Classes**
-
-*   OCCommunication.h (Accessors) Import in the communication class
-
-
-
-*   OCErrorMsg.h (Error Messages) Import in the communication class
-
-
-
-*   OCFileDto.h and OCFileDto.m (File/Folder object) Import when using readFolder and readFile methods
-
-
-
-*   OCFrameworkConstants.h (Customize constants)
-
-
-
-
-#.  Add the library file to the project.
-    From the “Build Phases” tab, scroll to “Link binary files” and select the ‘+’ to add a library.
-    Select the library file.
-
-
-
-
-|10000201000003480000020EC688993D_png|
-
-
-
-#.  Add the path of the library header files.
-    Under the “Build Settings” tab, select the target library and add the path in the “Header Search Paths” field.
-
-
-
-|10000201000003430000020C65A3C5A7_png|
-
-#.  Remaining in the “Build Setting” tab, add the flag “-Obj-C” under the “Other Linker Flags” option.
-
-
-
-|100002010000034700000211B6BE4A2B_png|
-
-
-
-At this stage, the library is included on your project and you can start communicating with the ownCloud server.
-
-
-
-
-Include the library as a subproject
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Follow these steps if this is the desired method.
-
-#.  Add the file “ownCloud iOS library.xcodeproj” to the project via drag and drop.
-
-
-
-|100000000000030C000001E61DFDBF76_png|
-
-
-#.  Within the project, navigate to the “Build Phases” tab.
-    Under the “Target Dependencies” section, select the ‘+’ and choose the library target.
-
-
-
-
-|100000000000030C000001E7A7A01884_png|
-
-
-
-#.  Link the library file to the project target.
-    Under the “Build Phases” tab, select the ‘+’ under the “Link Binary with Libraries” section and select the library file.
-
-
-
-
-|100000000000030C000001E8AB4C3306_png|
-
-
-
-#.  Add the flag “-Obj-C” to “Other Linker Flags” under the project target on the “Build Settings” tab.
-
-
-
-
-|100000000000030C000001ECB85120C2_png|
-
-
-
-#.  Finally add the path of the library headers.
-    Under the “Build Settings” tab, add the path under the “Header Search Paths” option.
-
-
-
-
-|100000000000030C000001E637605044_png|
-
-
-Source
-:
-
-raywenderlich.com
-` http://www.raywenderlich.com/41377/creating-a-static-library-in-ios-tutorial <http://www.raywenderlich.com/41377/creating-a-static-library-in-ios-tutorial>`_
-
-Apple.com
-`​https://developer.apple.com/library/ios/technotes/iOSStaticLibraries/Articles/configuration.html#/apple_ref/doc/uid/TP40012554-CH3-SW2 <#/apple_ref/doc/uid/TP40012554-CH3-SW2>`_
-
-
-.. |100000000000030C000001E61DFDBF76_png| image:: images/100000000000030C000001E61DFDBF76.png
-    :width: 16.51cm
-    :height: 10.285cm
-
-
-.. |100002010000034700000211B6BE4A2B_png| image:: images/100002010000034700000211B6BE4A2B.png
-    :width: 16.261cm
-    :height: 10.246cm
-
-
-.. |100000000000030C000001E7A7A01884_png| image:: images/100000000000030C000001E7A7A01884.png
-    :width: 16.51cm
-    :height: 12.023cm
-
-
-.. |10000201000003480000020EC688993D_png| image:: images/10000201000003480000020EC688993D.png
-    :width: 16.51cm
-    :height: 10.329cm
-
-
-.. |100000000000030C000001E8AB4C3306_png| image:: images/100000000000030C000001E8AB4C3306.png
-    :width: 14.605cm
-    :height: 9.137cm
-
-
-.. |10000201000003430000020C65A3C5A7_png| image:: images/10000201000003430000020C65A3C5A7.png
-    :width: 16.51cm
-    :height: 10.358cm
-
-
-.. |100000000000030C000001E637605044_png| image:: images/100000000000030C000001E637605044.png
-    :width: 14.605cm
-    :height: 9.098cm
-
-
-.. |100000000000030C000001ECB85120C2_png| image:: images/100000000000030C000001ECB85120C2.png
-    :width: 14.605cm
-    :height: 9.211cm
-
diff --git a/developer_manual/ios_library/examples.rst b/developer_manual/ios_library/examples.rst
new file mode 100644
index 0000000..b5a474c
--- /dev/null
+++ b/developer_manual/ios_library/examples.rst
@@ -0,0 +1,544 @@
+Examples
+========
+
+Init the library
+----------------
+
+Start using the library, it is needed to init the object OCCommunication.
+
+We recommend using the singleton method in the AppDelegate class in order to
+use the ownCloud iOS library.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  #import "OCCommunication.h"
+
+  + (OCCommunication *)sharedOCCommunication
+  {
+    static OCCommunication* sharedOCCommunication = nil;
+
+    if (sharedOCCommunication == nil)
+    {
+      sharedOCCommunication = [ [ OCCommunicationalloc] init ];
+    }
+
+    return sharedOCCommunication;
+  }
+
+Set credentials
+---------------
+
+Authentication on the app is possible by 3 different methods:
+
+* Basic authentication, user name and password
+* Cookie
+* Token (oAuth)
+
+
+Code example
+~~~~~~~~~~~~
+
+
+.. code-block:: objective-c
+
+ #Basic authentication, user name and password
+ [[ AppDelegate sharedOCCommunication ] setCredentialsWithUser : userName andPassword : password ];
+
+ #Authentication with cookie
+ [[ AppDelegate sharedOCCommunication ] setCredentialsWithCookie : cookie ];
+
+ #Authentication with token
+ [[ AppDelegate sharedOCCommunication ] setCredentialsOauthWithToken : token ];
+
+
+Create a folder
+---------------
+
+Create a new folder on the cloud server, the info needed to be sent is the path
+of the new folder.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+ [[ AppDelegate sharedOCCommunication ] createFolder :path onCommunication : [ AppDelegate sharedOCCommunication ]
+
+ successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) {
+ //Folder Created
+ }
+
+ failureRequest :^( NSHTTPURLResponse *response, NSError *error) {
+
+ //Failure
+
+ switch (response.statusCode) {
+
+ case kOCErrorServerUnauthorized :
+   //Bad credentials
+   break;
+ case kOCErrorServerForbidden :
+   //Forbidden
+   break;
+ case kOCErrorServerPathNotFound :
+   //Not Found
+   break;
+ case kOCErrorServerTimeout :
+   //timeout
+   break;
+ default:
+   //default
+   break;
+ }
+
+ }
+ errorBeforeRequest :^( NSError *error) {
+ //Error before request
+
+ if (error.code == OCErrorForbidenCharacters) {
+   //Forbidden characters
+ }
+ else
+ {
+   //Other error
+ }
+
+ }];
+  
+Read folder
+-----------
+
+Get the content of an existing folder on the cloud server, the info needed to
+be sent is the path of the folder.  As answer of this method, it will be
+received an array with all the files and folders stored in the selected folder.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication] readFolder:path onCommunication:[ AppDelegate sharedOCCommunication]
+
+  successRequest:^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) {
+    //Success
+    for ( OCFileDto * ocFileDto in items) {
+      NSLog( @"item path: %@%@" , ocFileDto.filePath, ocFileDto.fileName);
+    }
+  }
+
+  failureRequest:^( NSHTTPURLResponse *response, NSError *error) {
+
+  //Failure
+  switch (response.statusCode) {
+  case kOCErrorServerPathNotFound :
+    //Path not found
+    break;
+  case kOCErrorServerUnauthorized :
+    //Bad credentials
+    break;
+  case kOCErrorServerForbidden :
+    //Forbidden
+    break;
+  case kOCErrorServerTimeout :
+    //Timeout
+    break ;
+  default :
+    break;
+  }
+
+  }];
+
+Read file
+---------
+
+Get information related to a certain file or folder. Although, more information
+can be obtained, the library only gets the eTag.
+
+Other properties of the file or folder may be obtained: filePath, filename,
+isDirectory, size and date
+
+Code example
+~~~~~~~~~~~~
+
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication ] readFile :path onCommunication :[ AppDelegate sharedOCCommunication ]
+
+  successRequest :^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) {
+
+  OCFileDto *ocFileDto = [items objectAtIndex : 0 ];
+  NSLog ( @"item etag: %lld" , ocFileDto.  etag); }
+  failureRequest :^( NSHTTPURLResponse *response, NSError *error) {
+  switch (response.statusCode) {
+  case kOCErrorServerPathNotFound:
+    //Path not found
+    break;
+  case kOCErrorServerUnauthorized:
+    //Bad credentials
+    break;
+  case kOCErrorServerForbidden:
+    //Forbidden
+    break;
+  case kOCErrorServerTimeout:
+    //Timeout
+    break;
+  default:
+    break;
+  }
+  }];
+
+Move file or folder
+-------------------
+
+
+Move a file or folder from their current path to a new one on the cloud server.
+The info needed is the origin path and the destiny path.
+
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication ] moveFileOrFolder :sourcePath toDestiny :destinyPath onCommunication :[ AppDelegate sharedOCCommunication ]
+
+  successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) {
+    //File/Folder moved or renamed
+  }
+  failureRequest :^( NSHTTPURLResponse *response, NSError *error) {
+    //Failure
+    switch (response.statusCode) {
+    case kOCErrorServerPathNotFound:
+      //Path not found
+      break;
+    case kOCErrorServerUnauthorized:
+      //Bad credentials
+      break;
+    case kOCErrorServerForbidden:
+      //Forbidden
+      break;
+    case kOCErrorServerTimeout:
+      //Timeout
+      break;
+    default:
+      break;
+  }
+
+  }
+  errorBeforeRequest :^( NSError *error) {
+    if (error.code == OCErrorMovingTheDestinyAndOriginAreTheSame) {
+      //The destiny and the origin are the same
+    }
+    else if (error.code == OCErrorMovingFolderInsideHimself) {
+      //Moving folder inside himself
+    }
+    else if (error.code == OCErrorMovingDestinyNameHaveForbiddenCharacters) {
+      //Forbidden Characters
+    }
+    else
+    {
+      //Default
+    }
+
+  }];
+
+
+Delete file or folder
+---------------------
+
+Delete a file or folder on the cloud server. The info needed is the path to
+delete.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+  
+  [[ AppDelegate sharedOCCommunication ] deleteFileOrFolder :path onCommunication :[ AppDelegate
+
+  sharedOCCommunication ] successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) {
+    //File or Folder deleted
+  }
+  failureRequest :^( NSHTTPURLResponse *response, NSError *error) {
+
+  switch (response.statusCode) {
+  case kOCErrorServerPathNotFound:
+  //Path not found
+  break;
+  case kOCErrorServerUnauthorized:
+  //Bad credentials
+  break;
+  case kOCErrorServerForbidden:
+  //Forbidden
+  break;
+  case kOCErrorServerTimeout:
+  //Timeout
+  break;
+  default:
+  break;
+  }
+
+  }];
+
+
+Download a file
+---------------
+
+Download an existing file on the cloud server. The info needed is the server
+URL, path of the file on the server and localPath, path where the file will be
+stored on the device.
+
+Code example
+~~~~~~~~~~~~
+
+
+.. code-block:: objective-c
+
+  NSOperation *op = nil;
+  op = [[ AppDelegate sharedOCCommunication ] downloadFile :remotePath toDestiny :localPath onCommunication :[ AppDelegate sharedOCCommunication ]
+
+  progressDownload :^( NSUInteger bytesRead, long long totalBytesRead, long long totalBytesExpectedToRead) {
+
+  //Calculate percent
+  float percent = ( float)totalBytesRead / totalBytesExpectedToRead;
+   NSLog ( @"Percent of download: %f" , percent); }
+  successRequest :^(NSHTTPURLResponse *response, NSString *redirectedServer) {
+    //Download complete
+  }
+  failureRequest :^(NSHTTPURLResponse *response, NSError *error) {
+    switch (response.  statusCode) {
+    case kOCErrorServerUnauthorized:
+      //Bad credentials
+      break;
+    case kOCErrorServerForbidden:
+      //Forbidden
+      break;
+    case kOCErrorProxyAuth:
+      //Proxy access required
+      break;
+    case kOCErrorServerPathNotFound:
+      //Path not found
+      break;
+    default:
+      //Default
+      break;
+    }
+  }
+  shouldExecuteAsBackgroundTaskWithExpirationHandler :^{
+    [op cancel ];
+  }];
+
+
+Upload a file
+-------------
+
+Upload a new file to the cloud server. The info needed is localPath, path where
+the file is stored on the device and server URL, path where the file will be
+stored on the server.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  NSOperation *op = nil;
+  op = [[ AppDelegate sharedOCCommunication ] uploadFile :localPath toDestiny : remotePath onCommunication :[ AppDelegate sharedOCCommunication ]
+
+  progressUpload :^( NSUInteger bytesWrote, long long totalBytesWrote, long long totalBytesExpectedToWrite) {
+    //Calculate upload percent
+    if ( totalBytesExpectedToRead/1024 != 0) {
+      if ( bytesWrote > 0) {
+       float percent = totalBytesWrote* 100 / totalBytesExpectedToRead;
+        NSLog ( @"Percent: %f" , percent);
+      }
+    }
+  }
+  successRequest :^( NSHTTPURLResponse *response) {
+    //Upload complete
+  }
+  failureRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer, NSError *error) {
+    switch (response.  statusCode) {
+    case kOCErrorServerUnauthorized :
+      //Bad credentials
+      break;
+    case kOCErrorServerForbidden:
+      //Forbidden
+      break;
+    case kOCErrorProxyAuth:
+      //Proxy access required
+      break;
+    case kOCErrorServerPathNotFound:
+      //Path not found
+      break;
+    default:
+      //Default
+      break;
+    }
+  }
+  failureBeforeRequest :^( NSError *error) {
+    switch (error.code) {
+      case OCErrorFileToUploadDoesNotExist:
+        //File does not exist
+        break;
+      default:
+        //Default
+        break;
+    }
+  }
+  shouldExecuteAsBackgroundTaskWithExpirationHandler :^{
+    [op cancel];
+  }];
+
+
+Check if the server supports Sharing api
+----------------------------------------
+
+
+The Sharing API is included in ownCloud 5.0.13 and greater versions. The info
+needed is activeUser.url, the server URL that you want to check.
+
+Code Example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication ] hasServerShareSupport :_activeUser.url onCommunication :[ AppDelegate sharedOCCommunication ]
+
+    successRequest :^( NSHTTPURLResponse *response, BOOL hasSupport, NSString *redirectedServer) {
+    }
+    failureRequest :^( NSHTTPURLResponse *response, NSError *error){
+    }
+  }];
+
+
+Read shared items by link
+-------------------------
+
+Get information about what files and folder are shared by link.
+
+The info needed is Path, the server URL that you want to check.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication ] readSharedByServer :path onCommunication :[ AppDelegate sharedOCCommunication ]
+
+  successRequest :^( NSHTTPURLResponse *response, NSArray *items, NSString *redirectedServer) {
+    NSLog ( @"Item: %d" , items);
+  }
+
+  failureRequest :^( NSHTTPURLResponse *response, NSError *error){
+    NSLog ( @"error: %@" , error);
+    NSLog ( @"Operation error: %d" , response.statusCode);
+  }];
+
+
+Share link of file or folder
+----------------------------
+
+
+Share a file or a folder from your cloud server by link.
+The info needed is Path, your server URL and the path of the item that you want
+to share (for example ``/folder/file.pdf``)
+
+
+Code example
+~~~~~~~~~~~~
+
+
+.. code-block:: objective-c
+
+ [[ AppDelegate sharedOCCommunication ] shareFileOrFolderByServer :path andFileOrFolderPath :itemPath onCommunication :[ AppDelegate sharedOCCommunication ]
+ successRequest :^( NSHTTPURLResponse *response, NSString *token, NSString *redirectedServer) {
+
+ NSString *sharedLink = [ NSString stringWithFormat:@ `path/public.php?service=files&t=%@ <mailto:path/public.php?service=files&t=%25@>`_
+ , token];
+
+ }
+ failureRequest :^( NSHTTPURLResponse *response, NSError *error){
+   [ _delegate endLoading ];
+
+ DLog ( @”error.code: %d” , error.  code);
+ DLog (@”server.error: %d”, response.  statusCode);
+ int code = response.  statusCode ;
+ if (error.code == kOCErrorServerPathNotFound) {
+ }
+
+ switch (code) {
+ case kOCErrorServerPathNotFound:
+   //File to share not exists
+   break;
+ case kOCErrorServerUnauthorized:
+   //Error login
+   break;
+ case kOCErrorServerForbidden:
+   //Permission error
+   break;
+ case kOCErrorServerTimeout:
+   //Not possible to connect to server
+   break;
+ default:
+ if (error.code == kOCErrorServerPathNotFound) {
+   //File to share not exists
+ } else {
+   //Not possible to connect to the server
+ }
+ break;
+
+ }
+
+ }];
+
+ }
+
+ NSLog ( @"error: %@" , error);
+ NSLog ( @"Operation error: %d" , response.statusCode);
+ }];
+
+Unshare a folder or file by link
+--------------------------------
+
+
+Stop sharing by link a file or a folder from your cloud server.
+
+The info needed is Path, your server URL and the Id of the item that you want
+to Unshare.
+
+Before unsharing an item, you have to read the shared items on the selected
+server, using the method “ readSharedByServer ” so that you get the array
+“items” with all the shared elements.  These are objects OCShareDto, one of
+their properties is idRemoteShared, parameter needed to unshared an element.
+
+Code example
+~~~~~~~~~~~~
+
+.. code-block:: objective-c
+
+  [[ AppDelegate sharedOCCommunication ] unShareFileOrFolderByServer :path andIdRemoteSharedShared :sharedByLink.  idRemoteShared onCommunication :[ AppDelegate sharedOCCommunication ]
+
+    successRequest :^( NSHTTPURLResponse *response, NSString *redirectedServer) {
+      //File unshared
+    }
+    failureRequest :^( NSHTTPURLResponse *response, NSError *error){
+      //Error
+    }
+  ];
+
+Tips
+----
+
+* Credentials must be set before calling any method
+* Paths must not be on URL Encoding
+* Correct path: ``http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop_Music/``
+* Wrong path: ``http://www.myowncloudserver.com/owncloud/remote.php/webdav/Pop%20Music/``
+* There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud iOS library "\", "/","<",">",":",""","","?","*"
+* To move a folder the origin path and the destination path must end with “/”
+* To move a file the origin path and the destination path must not end with “/”
+* Upload and download actions may be cancelled thanks to the object “NSOperation”
+* Unit tests, before launching unit tests you have to enter your account information (server url, user and password) on OCCommunicationLibTests.m
diff --git a/developer_manual/ios_library/index.rst b/developer_manual/ios_library/index.rst
index eecb651..849bfee 100644
--- a/developer_manual/ios_library/index.rst
+++ b/developer_manual/ios_library/index.rst
@@ -1,4 +1,25 @@
-Index
-=====
+===========================
+iOS Application Development
+===========================
 
+This document will describe how to the use ownCloud iOS library.  The ownCloud
+iOS library for iOS allows a developer to communicate with any ownCloud server;
+among the features included are file synchronization, upload and download of
+files, delete rename and move of files and folders and share files or folders
+by link among others.
+
+This library may be added to a project and seamlessly integrates any
+application with ownCloud.
+
+The tool needed is Xcode 5, this guide includes some screenshots showing
+examples in Xcode 5.
+
+.. _iosindex:
+
+.. toctree::
+   :maxdepth: 1
+   :hidden:
+
+   library_installation
+   examples
 
diff --git a/developer_manual/ios_library/library_installation.rst b/developer_manual/ios_library/library_installation.rst
new file mode 100644
index 0000000..6f5a6a2
--- /dev/null
+++ b/developer_manual/ios_library/library_installation.rst
@@ -0,0 +1,133 @@
+Library Installation
+====================
+
+Obtaining the library
+---------------------
+
+The ownCloud iOS library may be obtained from the following Github repository:
+
+`git at github.com:owncloud/ios-library.git
+<mailto:git at github.com:owncloud/ios-library.git>`_
+
+Once obtained, this code should be compiled with Xcode 5.  The Github
+repository not only contains the library, ownCloud iOS library, but also
+contains a sample project, OCLibraryExample, which will assist in learning how
+to use the library.
+
+Add the library to a project
+----------------------------
+
+There are two methods to add this library to a project.
+
+* Reference the headers and library binary file (.a) directly.
+* Include the library as a subproject.
+
+
+Which method to choose depends on user preference as well as whether the source
+code and project file of the static library are available.
+
+Reference headers and library binary files
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Follow these steps if this is the desired method.
+
+#.  Compile the ownCloud iOS library and run the project.  A libownCloudiOS.a
+file will be generated.
+
+The following files are required:
+
+**Library file**
+
+* `libownCloudiOS.a` (Library)
+
+**Library Classes**
+
+*   ``OCCommunication.h`` (Accessors) Import in the communication class
+*   ``OCErrorMsg.h`` (Error Messages) Import in the communication class
+*   ``OCFileDto.h`` and ``OCFileDto.m`` (File/Folder object) Import when using
+*   ``readFolder`` and ``readFile`` methods
+*   ``OCFrameworkConstants.h`` (Customize constants)
+
+#.  Add the library file to the project.  From the “Build Phases” tab, scroll
+to “Link binary files” and select the ‘+’ to add a library.  Select the library
+file.
+
+|10000201000003480000020EC688993D_png|
+
+#.  Add the path of the library header files.  Under the “Build Settings” tab,
+select the target library and add the path in the “Header Search Paths” field.
+
+|10000201000003430000020C65A3C5A7_png|
+
+#.  Remaining in the “Build Setting” tab, add the flag “-Obj-C” under the
+“Other Linker Flags” option.
+
+|100002010000034700000211B6BE4A2B_png|
+
+At this stage, the library is included on your project and you can start
+communicating with the ownCloud server.
+
+Include the library as a subproject
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Follow these steps if this is the desired method.
+
+#. Add the file “ownCloud iOS library.xcodeproj” to the project via drag and
+drop.
+
+|100000000000030C000001E61DFDBF76_png|
+
+#. Within the project, navigate to the “Build Phases” tab.  Under the “Target
+Dependencies” section, select the ‘+’ and choose the library target.
+
+|100000000000030C000001E7A7A01884_png|
+
+#.  Link the library file to the project target.  Under the “Build Phases” tab,
+select the ‘+’ under the “Link Binary with Libraries” section and select the
+library file.
+
+|100000000000030C000001E8AB4C3306_png|
+
+#.  Add the flag “-Obj-C” to “Other Linker Flags” under the project target on
+the “Build Settings” tab.
+
+|100000000000030C000001ECB85120C2_png|
+
+#.  Finally add the path of the library headers.  Under the “Build Settings”
+tab, add the path under the “Header Search Paths” option.
+
+|100000000000030C000001E637605044_png|
+
+Sources
+-------
+
+* `Creating a static library in iOS tutorial (raywenderlich.com)`_
+* `Apple iOS static library documentation`_
+
+.. |100000000000030C000001E61DFDBF76_png| image:: images/100000000000030C000001E61DFDBF76.png
+ :width: 16.51cm
+ :height: 10.285cm
+.. |100002010000034700000211B6BE4A2B_png| image:: images/100002010000034700000211B6BE4A2B.png
+ :width: 16.261cm
+ :height: 10.246cm
+.. |100000000000030C000001E7A7A01884_png| image:: images/100000000000030C000001E7A7A01884.png
+ :width: 16.51cm
+ :height: 12.023cm
+.. |10000201000003480000020EC688993D_png| image:: images/10000201000003480000020EC688993D.png
+ :width: 16.51cm
+ :height: 10.329cm
+.. |100000000000030C000001E8AB4C3306_png| image:: images/100000000000030C000001E8AB4C3306.png
+ :width: 14.605cm
+ :height: 9.137cm
+.. |10000201000003430000020C65A3C5A7_png| image:: images/10000201000003430000020C65A3C5A7.png
+ :width: 16.51cm
+ :height: 10.358cm
+.. |100000000000030C000001E637605044_png| image:: images/100000000000030C000001E637605044.png
+ :width: 14.605cm
+ :height: 9.098cm
+.. |100000000000030C000001ECB85120C2_png| image:: images/100000000000030C000001ECB85120C2.png
+ :width: 14.605cm
+ :height: 9.211cm
+
+.. _`Creating a static library in iOS tutorial (raywenderlich.com)`: http://www.raywenderlich.com/41377/creating-a-static-library-in-ios-tutorial
+.. _`Apple iOS static library documentation`: https://developer.apple.com/library/ios/technotes/iOSStaticLibraries/Articles/configuration.html#/apple_ref/doc/uid/TP40012554-CH3-SW2

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-doc.git



More information about the Pkg-owncloud-commits mailing list