I\'m try to retrieve datafrom database
in my fragment
onViewCreated
method I have used FirebaseRecylerAdapter like below
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
FirebaseRecyclerAdapter<AllUsers, AllUsersViewHolder> firebaseRecyclerAdapter;
}
public static class AllUsersViewHolder extends RecyclerView.ViewHolder {
View view;
public AllUsersViewHolder(View itemView) {
super(itemView);
view = itemView;
}
}
when I use firebaseRecyclerAdapter = new FirebaseRecyclerAdapter
it wont give me the populateViewHolder
method just give method like below
FirebaseRecyclerAdapter<AllUsers, AllUsersViewHolder> firebaseRecyclerAdapter = new FirebaseRecyclerAdapter<AllUsers, AllUsersViewHolder>() {
@Override
protected void onBindViewHolder(AllUsersViewHolder holder, int position, AllUsers model) {
}
@Override
public AllUsersViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
return null;
}
};
Can someone please tell me why this is happening