Volley automatically schedule all network requests. It means that Volley will be taking care of all the network requests your app executes for fetching response or image from web.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app
README.md

README.md

VolleyLibrary

Volley automatically schedule all network requests. It means that Volley will be taking care of all the network requests your app executes for fetching response or image from web.

Android volley is a networking library was introduced to make networking calls much easier, faster without writing tons of code. By default all the volley network calls works asynchronously.

screenshot_1504680665

Volley offers the following benefits:

--Automatic scheduling of network requests.

--Multiple concurrent network connections.

--Transparent disk and memory response caching with standard HTTP cache coherence.

--Support for request prioritization.

--Cancellation request API. You can cancel a single request, or you can set blocks or scopes of requests to cancel.

--Ease of customization, for example, for retry and backoff.

--Strong ordering that makes it easy to correctly populate your UI with data fetched asynchronously from the network.

--Debugging and tracing tools.

JsonObjectRequest

    JsonObjectRequest jsonObjReq = new JsonObjectRequest(Request.Method.GET,
                getResources().getString(R.string.url_main), new JSONObject(),
                new Response.Listener<JSONObject>() {

                    @Override
                    public void onResponse(JSONObject response) {

Parameters passed into the constructor:

--RequestMethod (GET, POST, PUT, DELETE, etc.)

--URL: String of the URL of the required object

--JSONObject: An optional object posted with the request, null if there is no object posted

--ResponseListener: Response Listener, whose callback method will contain the response

--ErrorListener: A Response.ErrorListener whose callback method will contain any problem with the request.

AppController

Remember to update your Manifest as well. ie. Add this class in your AndroidManifest.xml using name attribute for tag.

LruBitmapCache

A cache that holds strong references to a limited number of values. Each time a value is accessed, it is moved to the head of a queue. When a value is added to a full cache, the value at the end of that queue is evicted and may become eligible for garbage collection.