में अधिक मान पास कैसे doInBackground
doInBackground AsyncTask एंड्रॉयड
में अधिक मान पारित करने के लिए मेरे AsyncTask
इस तरह दिखता है। बाद AsyncTask
execute
को protected String doInBackground(String... sUrl, String... otherUrl, Context context)
और कैसे:
private class DownloadFile extends AsyncTask<String, Integer, String> {
@Override
protected String doInBackground(String... sUrl) {
{
}
}
यह मेरी protected String DoInBackground
के बारे में अधिक मान पास करने के किसी भी तरह संभव है? new DownloadFile.execute("","",this)
या कुछ?
आप तर्क-एडी कन्स्ट्रक्टर डाउनलोडफाइल क्लास बना सकते हैं और फिर क्लास बॉडी में कहीं भी उन तर्कों का उपयोग कर सकते हैं। –