📅  最后修改于: 2022-03-11 14:52:32.311000             🧑  作者: Mango
FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference myRef = database.getReference();
myRef.addValueEventListener(new ValueEventListener() {
@Override
public void onDataChange(DataSnapshot dataSnapshot) {
for(DataSnapshot item_snapshot:dataSnapshot.getChildren()) {
Log.d("item id ",item_snapshot.child("item_id").getValue().toString());
Log.d("item desc",item_snapshot.child("item_desc").getValue().toString());
}
}
}