Unable to use NameValuePair in Android Studio

542 Views Asked by At

I want to upload data to a server from my android application.For this I want to use NameValuePair in my code

ArrayList<NameValuePair> nameValuePairs = new  ArrayList<NameValuePair>();

nameValuePairs.add(new BasicNameValuePair("image",image_str));

But unfortunately NameValuePair is deprecated now.What are the posssible alternatives to this and how can I upload image without using NameValuePair?

0

There are 0 best solutions below