Skip to content

Commit 262d7f2

Browse files
Grimthorrsamtstern
authored andcommitted
Remove FirebaseIndexRecyclerAdapter reference from documentation (#987)
1 parent 728e62b commit 262d7f2

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

database/README.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,26 +41,26 @@ public class Chat {
4141
}
4242
```
4343

44-
A few things to note abot this model class:
44+
A few things to note about this model class:
4545

4646
* The getters and setters follow the JavaBean naming pattern which allows Firebase to map
4747
the data to field names (ex: `getName()` provides the `name` field).
4848
* The class has an empty constructor, which is required for Firebase's automatic data mapping.
4949

5050
For a properly constructed model class like the `Chat` class above, Firebase can perform automatic
5151
serialization in `DatabaseReference#setValue()` and automatic deserialization in
52-
`DataSnapshot.getValue()`.
52+
`DataSnapshot#getValue()`.
5353

5454
### Querying
5555

56-
On the main screenof your app, you may want to show the 50 most recent chat messages. With Firebase
56+
On the main screen of your app, you may want to show the 50 most recent chat messages. With Firebase
5757
you would use the following query:
5858

5959
```java
6060
Query query = FirebaseDatabase.getInstance()
6161
.getReference()
6262
.child("chats")
63-
.limitToLast(50)
63+
.limitToLast(50);
6464
```
6565

6666
To retrieve this data without FirebaseUI, you might use `addChildEventListener` to listen for
@@ -140,7 +140,7 @@ FirebaseRecyclerAdapter adapter = new FirebaseRecyclerAdapter<Chat, ChatHolder>(
140140
};
141141
```
142142

143-
Finally attach the adapter to your `RecyclerView` with the `RecyclerView#setAdapter()`.
143+
Finally attach the adapter to your `RecyclerView` with the `RecyclerView#setAdapter()` method.
144144
Don't forget to also set a `LayoutManager`!
145145

146146

@@ -226,9 +226,7 @@ FirebaseListAdapter<Chat> adapter = new FirebaseListAdapter<Chat>(options) {
226226
## Using FirebaseUI with indexed data
227227

228228
If your data is [properly indexed][indexed-data], change your adapter initialization
229-
to use `setIndexedQuery`:
230-
231-
For a `RecyclerView`, use `FirebaseIndexRecyclerAdapter` instead of `FirebaseRecyclerAdapter`:
229+
to use `setIndexedQuery()`:
232230

233231
```java
234232
// keyQuery - the Firebase location containing the list of keys to be found in dataRef
@@ -239,11 +237,11 @@ FirebaseRecyclerOptions<Chat> options = new FirebaseRecyclerOptions.Builder<Chat
239237
.build();
240238
```
241239

242-
`keyQuery` is the location of your keys, and `dataRef` is the location of your data.
240+
Where `keyQuery` is the location of your keys, and `dataRef` is the location of your data.
243241

244242
### A note on ordering
245243

246-
The order in which your receive your data depends on the order from `keyRef`, not `dataRef`:
244+
The order in which you receive your data depends on the order from `keyRef`, not `dataRef`:
247245

248246
```javascript
249247
{

0 commit comments

Comments
 (0)