ParseApplication/ExternalLibs/Parse-SDK-Android/README.md

5.5 KiB

Parse SDK for Android

Maven Central Dependencies References License

Build Status Coverage Status

Join Chat

A library that gives you access to the powerful Parse cloud platform from your Android app. For more information about Parse and its features, see the website, blog and getting started.

Getting Started

Installation

  • Option 1: Gradle

    Add dependency to the application level build.gradle file.

    dependencies {
      implementation 'com.parse:parse-android:1.16.7'
    }
    

    Snapshots of the development version are available in jFrog's snapshots repository.

  • Option 2: Compiling for yourself into AAR file

    If you want to manually compile the SDK, begin by cloning the repository locally or retrieving the source code for a particular release. Open the project in Android Studio and run the following commands in the Terminal of Android Studio:

    ./gradlew clean build
    

    Output file can be found in Parse/build/outputs/ with extension .aar

    You can link to your project to your AAR file as you please.

Setup

  • Option 1: Setup in the Manifest

    You may define com.parse.SERVER_URL and com.parse.APPLICATION_ID meta-data in your AndroidManifest.xml:

    <application ...>
      <meta-data
        android:name="com.parse.SERVER_URL"
        android:value="@string/parse_server_url" />
      <meta-data
        android:name="com.parse.APPLICATION_ID"
        android:value="@string/parse_app_id" />
      ...
    </application>
    
  • Option 2: Setup in the Application

    Initialize Parse in a custom class that extends Application:

    import com.parse.Parse;
    import android.app.Application;
    
    public class App extends Application {
      @Override
      public void onCreate() {
        super.onCreate();
        Parse.initialize(new Parse.Configuration.Builder(this)
          .applicationId("YOUR_APP_ID")
          .server("http://localhost:1337/parse/")
          .build()
        );
      }
    }
    

For either option, the custom Application class must be registered in AndroidManifest.xml:

<application
  android:name=".App"
  ...>
  ...
</application>

Usage

Everything can done through the supplied gradle wrapper:

Run the Tests

./gradlew clean testDebug

Results can be found in Parse/build/reports/

Get Code Coverage Reports

./gradlew clean jacocoTestReport

Results can be found in Parse/build/reports/

How Do I Contribute?

We want to make contributing to this project as easy and transparent as possible. Please refer to the Contribution Guidelines.

Other Parse Projects

License

Copyright (c) 2015-present, Parse, LLC.
All rights reserved.

This source code is licensed under the BSD-style license found in the
LICENSE file in the root directory of this source tree. An additional grant
of patent rights can be found in the PATENTS file in the same directory.

As of April 5, 2017, Parse, LLC has transferred this code to the parse-community organization, and will no longer be contributing to or distributing this code.