Back to project page markj.
The source code is released under:
GNU Lesser General Public License
If you think the Android project markj listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.markjmind.mobile.api.hub; /* w w w .j a v a2 s . co m*/ import java.io.IOException; import java.net.MalformedURLException; import java.net.ProtocolException; import android.util.Log; import com.markjmind.mobile.api.android.util.WebConnection; public class Loader { ArrayJDhub ajd = new ArrayJDhub(); String defaultUrl; public Loader(String defaultUrl){ this.defaultUrl = defaultUrl; } public Store dataSend(){ String url = defaultUrl; String mdParameters = ajd.getUriString(); url = url+mdParameters; Log.d("????:dataSend",url); WebConnection wc = new WebConnection(); Store wc_list=null; try { wc_list = wc.getArrayJDList(url); } catch (MalformedURLException e) { e.printStackTrace(); } catch (ProtocolException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } return wc_list; } public Store dataSend(boolean isCookie){ String url = defaultUrl; String mdParameters = ajd.getUriString(); Log.d("????:dataSend",url); WebConnection wc = new WebConnection(); if(isCookie==true){ // wc.cookie = Global.cookie; wc.setCookie = true; } Store wc_list=null; try { wc_list = wc.getArrayJDList(url,"POST",mdParameters); } catch (MalformedURLException e) { e.printStackTrace(); } catch (ProtocolException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } return wc_list; } public void add(String mdType,Store param){ ajd.addUri(mdType, param); } }