BasicNameValuePair is an object, in particular a container for storing data and keys.
For example, if you have this data:
Name: Bob
Family name: Smith
Date of birth: 10/03/1977
then you save this data as:
ArrayList<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();
nameValuePairs.add(new BasicNameValuePair("name","bob"));
nameValuePairs.add(new BasicNameValuePair("family name","Smith"));
....
As you can see, you select the key ("name") and the data that should be stored as key-bound ("bob"). This is a type of data structure used to speed up and simplify the storage of this kind of information.
:
httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));
4 :
httppost.setEntity
, URL- (HTML , ) URL-, HTTP Post.
new UrlEncodedFormEntity
, -, HTTP-.
&key=input
, , .
nameValuePair
- , . html, "input name=". , .
is = entity.getContent();
HttpEntity - , . - , HttpEntity . getContent() - , Http, ..: html, - . , .
BasicNameValuePair , arraylist.
, (, ) .
, .