BackendlessCollection is NULL

When running this code I receive a collection that is NULL when my table is populated.

private void retrieveBasicAdvertisementRecord()
{
    Backendless.Persistence.of( Advertisement.class).find(new AsyncCallback<BackendlessCollection<Advertisement>>() {



        @Override
        public void handleResponse(BackendlessCollection<Advertisement> foundAdvertisements_) {
            // all Contact instances have been found

            foundAdvertisements = foundAdvertisements_;
        }

        @Override
        public void handleFault(BackendlessFault fault) {
            // an error has occurred, the error code can be retrieved with fault.getCode()
        }
    });
}

You are using an async call here. If you check the value of “foundAdvertisements” before the value is returned into the handleResponse method, it will be null…