Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d69a99e3 authored by Hemal Patel's avatar Hemal Patel Committed by android-build-merger
Browse files

Merge "Docs: Fixed an invalid initialization of ExampleProvider member in...

Merge "Docs: Fixed an invalid initialization of ExampleProvider member in Content URI patterns docs sample" into mnc-io-docs am: 709f0df0 am: 71b5005a
am: 747d945b

* commit '747d945b':
  Docs: Fixed an invalid initialization of ExampleProvider member in Content URI patterns docs sample

Change-Id: I7b701650b8ffeb97ddff0df52a2654dd88f5dffb
parents 031def9e 747d945b
Loading
Loading
Loading
Loading
+20 −18
Original line number Diff line number Diff line
@@ -409,13 +409,14 @@ page.title=Creating a Content Provider
public class ExampleProvider extends ContentProvider {
...
    // Creates a UriMatcher object.
    private static final UriMatcher sUriMatcher;
...
    private static final UriMatcher sUriMatcher = new UriMatcher(UriMatcher.NO_MATCH);

    static {
        /*
         * The calls to addURI() go here, for all of the content URI patterns that the provider
         * should recognize. For this snippet, only the calls for table 3 are shown.
         */
...

        /*
         * Sets the integer value for multiple rows in table 3 to 1. Notice that no wildcard is used
         * in the path
@@ -428,6 +429,7 @@ public class ExampleProvider extends ContentProvider {
         * "content://com.example.app.provider/table3 doesn't.
         */
        sUriMatcher.addURI("com.example.app.provider", "table3/#", 2);
    }
...
    // Implements ContentProvider.query()
    public Cursor query(