Updated Android developer documentation to reflect the actual state with the initial release 1.0.0

This commit is contained in:
Andy Scherzinger
2016-06-15 12:13:28 +02:00
parent fb13a5fcb4
commit 2e824bdab2
4 changed files with 44 additions and 37 deletions

View File

@@ -24,7 +24,7 @@ Code example
...
// Parse URI to the base URL of the ownCloud server
// Parse URI to the base URL of the Nextcloud server
Uri serverUri = Uri.parse(getString(R.string.server_base_url));
// Create client object to perform remote operations
@@ -255,7 +255,7 @@ Code example
Move a file or folder
---------------------
Move an exisintg file or folder to a different location in the ownCloud server. Parameters needed are the path
Move an exisintg file or folder to a different location in the Nextcloud server. Parameters needed are the path
to the file or folder to move, and the new path desired for it. The parent folder of the new path must exist in
the server.
@@ -318,7 +318,7 @@ 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.
not in use within the Nextcloud Android library.
Code example
~~~~~~~~~~~~
@@ -357,7 +357,7 @@ 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.
within the Nextcloud Android library.
Code example
@@ -423,8 +423,8 @@ Tips
* Credentials must be set before calling any method
* Paths must not be on URL Encoding
* Correct path: ``https://example.com/owncloud/remote.php/dav/PopMusic``
* Wrong path: ``https://example.com/owncloud/remote.php/dav/Pop%20Music/``
* There are some forbidden characters to be used in folder and files names on the server, same on the ownCloud Android Library "\","/","<",">",":",""","|","?","*"
* Correct path: ``https://example.com/nextcloud/remote.php/dav/PopMusic``
* Wrong path: ``https://example.com/nextcloud/remote.php/dav/Pop%20Music/``
* There are some forbidden characters to be used in folder and files names on the server, same on the Nextcloud 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

Binary file not shown.

Before

Width:  |  Height:  |  Size: 131 KiB

View File

@@ -3,39 +3,36 @@
===============================
Android Application Development
===============================
ownCloud provides an official ownCloud Android client, which gives its users
access to their files on their ownCloud. It also includes functionality like
automatically uploading pictures and videos to ownCloud.
Nextcloud provides an official Nextcloud Android client, which gives its users
access to their files on their Nextcloud. It also includes functionality like
automatically uploading pictures and videos to Nextcloud.
For third party application developers, ownCloud offers the ownCloud Android
For third party application developers, Nextcloud offers the Nextcloud Android
library under the MIT license.
Android ownCloud Client development
Android Nextcloud Client development
-----------------------------------
If you are interested in working on the ownCloud android client, you can find
the source code `in github <https://github.com/owncloud/android/>`_. The
If you are interested in working on the Nextcloud android client, you can find
the source code `in github <https://github.com/nextcloud/android/>`_. The
setup and process of contribution is
`documented here <https://github.com/owncloud/android/blob/master/SETUP.md>`_.
`documented here <https://github.com/nextcloud/android/blob/master/SETUP.md>`_.
You might want to start with doing one or two `junior jobs <https://github.com/owncloud/android/issues?q=is%3Aopen+is%3Aissue+label%3A%22Junior+Job%22>`_
You might want to start with doing one or two `starter issue <https://github.com/nextcloud/android/issues?q=is%3Aopen+is%3Aissue+label%3A%22starter+issue%22>`_
to get into the code and note our :doc:`../general/index`
Note that contribution to the Android client require signing the `ownCloud Contributor Agreement <https://owncloud.org/contribute/agreement/>`_.
ownCloud Android Library
Nextcloud Android Library
------------------------
This document will describe how to the use ownCloud Android Library. The
ownCloud Android Library allows a developer to communicate with any ownCloud
This document will describe how to the use Nextcloud Android Library. The
Nextcloud Android Library allows a developer to communicate with any Nextcloud
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.
application with Nextcloud.
The tool needed is any IDE for Android. This guide includes some screenshots
showing examples in Eclipse.
The tool needed is any IDE for Android prefered IDE at the moment is Android Studio.
.. toctree::
:maxdepth: 2

View File

@@ -7,7 +7,7 @@ Obtaining the library
The ownCloud Android library may be obtained from the following Github repository:
`https://github.com/owncloud/android-library <https://github.com/owncloud/android-library>`_
`https://github.com/nextcloud/android-library <https://github.com/nextcloud/android-library>`_
Once obtained, this code should be compiled. The Github repository not only contains the library, but also a sample project, sample_client
sample_client properties/android/librerias
@@ -17,25 +17,35 @@ sample_client properties/android/librerias
Add the library to a project
----------------------------
There are different methods to add an external library to a project, then we will describe one of them.
There are different methods to add an external library to a project, we will describe two.
#. Compile the ownCloud Android Library
#. Add the library as a gradle dependency via jitpack
#. Define a dependency within your project.
#. Add the library repo to your Android project as a git submodule
Add the library as a gradle dependency
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
For that, access to
Properties > Android > Library
** **
and click on add and select the ownCloud Android library
Simply open your::
|1000000000000270000003A317117674_png|
build.gradle
Then all the public classes and methods of the library will be available for your own app.
and add the dependency::
.. |1000000000000270000003A317117674_png| image:: images/1000000000000270000003A317117674.png
:width: 10.795cm
:height: 16.106cm
compile 'com.github.nextcloud:android-library:<version>'
<version> refers to the exact version you would like to include in your application. This could be -SNAPSHOT for always using the latest code revision of the master branch. Alternatively you can also specifiy a version number which refers to a fixed release, e.g. 1.0.0. (compile 'com.github.nextcloud:android-library:1.0.0')
Add the library project to your project as a git submodule
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Basically get the code and compile it having it integrated via a git submodule
Go into your own apps directory on the command line and add the Nextcloud Android library as a submodule::
git submodule add https://github.com/nextcloud/android-library nextcloud-android-library
Import/Open your app in Android Studio and you are done. All the public classes and methods of the library will be available for your own app.