下边资料是关于Android建立gprs连接的代码,希望对码农们也有帮助。
private boolean openDataConnection() {
DataConnection conn = DataConnection.getInstance();
if (connectMode == 0) {
ret = conn.openConnection(mContext, “cmwap”, “cmwap”, “cmwap”);
} else {
ret = conn.openConnection(mContext, “cmnet”, “”, “”);
}
}