0

I have code like:

private class Task1 extends AsyncTask<Object, Void, String> {

    @Override
    protected void onPreExecute() {
        .....
    }

    @SuppressWarnings("unchecked")
    @Override
    protected String doInBackground(Object...params) {
        getList();
    }

    @Override
    protected void onPostExecute(String result) {
        .....
    }
}

private void getList() {
    JSONParser jsonParser = new JSONParser();

    try {
        JSONObject json = jsonParser.getJSONFromUrl(url);
        if(json != null) {
            .....
        }
    } catch (JSONException e) {
        .....
    }
}

How can I convert it to its Volley library equivalent?

P.S: I know about this post, but unfortunately it does not help much.

Community
  • 1
  • 1
Libera Me
  • 63
  • 1
  • 2
  • 9
  • see [Android: Getting Started with Volley](http://blog.chrisblunt.com/android-getting-started-with-volley/) maybe help you in implementing Volley lib – ρяσѕρєя K Sep 20 '14 at 13:35
  • http://stackoverflow.com/questions/25948191/android-send-post-request-using-volley-and-receive-in-php/25948689#25948689 Use the custom request for json that I made – Georgian Benetatos Sep 20 '14 at 14:01

0 Answers0