DatabaseReference myRef = database.getReference(address[0]+"/"+address[1]);
myRef.addValueEventListener(new ValueEventListener() {
@Override
public void onDataChange(DataSnapshot dataSnapshot) {
// This method is called once with the initial value and again
// whenever data at this location is updated.
String value = dataSnapshot.getValue(String.class);
publishProgress(getping(value));
}
publishProgress всегда пропускается.