ArrayList not updating after using .clear() <p>I'm new to Android development, so please bear with me.</p> <p>I have a custom ArrayAdapter which I want to update by swiping down to refresh.</p> <p>I understand that in order to do this I need to:</p> <ul> <li>clear the ArrayList that holds my data (with .clear())</li> <li>Update the ArrayList with the new data (using the getAbsentTeachers() method)</li> <li>use notifyDataSetChanged() on the ArrayAdapter</li> </ul> <p>After I clear the ArrayList, call getAbsentTeachers() and notifyDataSetChanged() the ArrayList appears to remain empty even though getAbsentTeachers() is beeing called. I know this because nothing is displayed in my ListView. </p> <p>getAbsentTeachers() populates the ArrayList fine when my app is first launched however it doesn't seem to work when I call it again to update the ArrayList.</p> <p>Any ideas as to why the array is not beeing updated?</p> <p><strong>MainActivity.java:</strong> package uk.co.bobsmith.drawview.drawviewtest;</p> <pre><code>public class MainActivity extends AppCompatActivity implements NavigationView.OnNavigationItemSelectedListener { private ArrayList&lt;Absent&gt; absences = new ArrayList&lt;&gt;(); private SwipeRefreshLayout swipeContainer; @Override protected void onCreate(Bundle savedInstanceState) { //---------------------INITIALISING PARSE------------------------------- Parse.enableLocalDatastore(this); // Add your initialization code here Parse.initialize(new Parse.Configuration.Builder(getApplicationContext()) //Information obscured for privacy - tested and working though. .applicationId("") .clientKey(null) .server("") .build() ); ParseUser.enableAutomaticUser(); ParseACL defaultACL = new ParseACL(); // Optionally enable public read access. // defaultACL.setPublicReadAccess(true); ParseACL.setDefaultACL(defaultACL, true); ParseInstallation.getCurrentInstallation().saveInBackground(); ParsePush.subscribeInBackground("Absent"); //-----------------------CREATE ADAPTER OBJECT-------------------------------- getAbsentTeachers(); final ListView lv = (ListView)findViewById(R.id.listView); final ArrayAdapter&lt;Absent&gt; adapter = new absenceArrayAdapter(this, 0, absences); lv.setAdapter(adapter); swipeContainer = (SwipeRefreshLayout) findViewById(R.id.swipeContainer); // Setup refresh listener which triggers new data loading swipeContainer.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() { @Override public void onRefresh() { // Code to refresh the list. absences.clear(); getAbsentTeachers(); adapter.notifyDataSetChanged(); swipeContainer.setRefreshing(false); // Call swipeContainer.setRefreshing(false) when finished. } }); } // Populates absences ArrayList with absence data public void getAbsentTeachers() { ParseQuery&lt;ParseObject&gt; query = ParseQuery.getQuery("Absences"); query.findInBackground(new FindCallback&lt;ParseObject&gt;() { @Override public void done(List&lt;ParseObject&gt; objects, ParseException e) { if(e == null){ for(ParseObject object : objects){ String name = String.valueOf(object.get("name")); Log.i("Name", name); String desc = String.valueOf(object.get("description")); Log.i("Description", desc); absences.add(new Absent(name, desc, "employees")); } } else { Log.i("Get data from parse", "There was an error getting data!"); e.printStackTrace(); } } }); } //custom ArrayAdapter class absenceArrayAdapter extends ArrayAdapter&lt;Absent&gt; { private Context context; private List&lt;Absent&gt; absencesList; public absenceArrayAdapter(Context context, int resource, ArrayList&lt;Absent&gt; objects) { super(context, resource, objects); this.context = context; this.absencesList = objects; } public View getView(int position, View convertView, ViewGroup parent) { //get the property we are displaying Absent teacher = absencesList.get(position); //get the inflater and inflate the XML layout for each item LayoutInflater inflater = (LayoutInflater) context.getSystemService(Activity.LAYOUT_INFLATER_SERVICE); View view = inflater.inflate(R.layout.custom_listview, null); TextView name = (TextView) view.findViewById(R.id.name); TextView description = (TextView) view.findViewById(R.id.description); ImageView teacherImage = (ImageView) view.findViewById(R.id.imageView); String teacherName = teacher.getTeacherName(); name.setText(teacherName); int descriptionLength = teacher.getDescription().length(); if(descriptionLength &gt;= 75){ String descriptionTrim = teacher.getDescription().substring(0, 75) + "..."; description.setText(descriptionTrim); }else{ description.setText(teacher.getDescription()); } return view; } } } </code></pre>