黑莓 8330 连接问题
我可以使用各种设备连接到 Web 服务并下载数据,例如操作系统为 4.6 或更高版本的 BlackBerry 9000。
但是,对于 8330 和操作系统 4.5.0.77,它不起作用。我还没有在 4.5.0.77 版本 8330 之前的任何设备上尝试过此代码。 在 8330 上,它挂在 JSR172 Web 服务调用中的 resultObj = op.invoke(inputObject);
行上。这是在成功进行第一个 Web 服务调用之后——它挂在第二个 Web 服务调用上。
实际上有两个 Web 服务:
- 用于身份验证的 Web 服务。
- 用于下载所有信息的网络服务。
到目前为止我已经尝试过的事情:
- 擦除设备 - 没有执行任何操作
- 将设备连接到 Eclipse 以查看发生了什么 - 没有找到任何有用的东西
- 在 4.5 的 8330 模拟器上运行代码(MDS 运行) - 可以完美地工作,无需任何操作问题
有谁知道如何解决这个问题?
以下是我构建连接字符串的方法:
String webserviceURL = developmentUrl;
// if it is simulator then force the network that is available on
// the PC
if (DeviceInfo.isSimulator()) {
webserviceURL += ";deviceside=true";
} else if ((CoverageInfo.getCoverageStatus() & CoverageInfo.COVERAGE_MDS) == CoverageInfo.COVERAGE_MDS) {
// go through MDS
webserviceURL += ";deviceside=false";
}
// else if ((CoverageInfo.getCoverageStatus() &
// CoverageInfo.COVERAGE_CARRIER) == CoverageInfo.COVERAGE_CARRIER)
// {
// webserviceURL += "'deviceside=true";// go direct
// }
// check if the wifi is available and change the url to use the wifi
// signal
if ((RadioInfo.getActiveWAFs() & RadioInfo.WAF_WLAN) != 0)
// check for carrier
{
if (WLANInfo.getWLANState() == WLANInfo.WLAN_STATE_CONNECTED)
// check for wifi
{
// WebService URL when the app is being used in the
// actual device
webserviceURL = webserviceURL + ";interface=wifi";
}
}
// WebService URL when the app is being used in the actual device
_propertyValues = new Object[] { webserviceURL };
I'm able to connect to a webservice and download the data using a variety of devices, such as the BlackBerry 9000 with OS 4.6 or greater.
However, with the 8330 and OS 4.5.0.77 it doesn't work. I have not tried this code on any devices older than the 8330 with 4.5.0.77.
On the 8330 it hangs on the resultObj = op.invoke(inputObject);
line in the JSR172 webservice call. This is after making the first webservice call successfully -- it hangs on the second.
There are actually two webservices:
- The webservice used for authentication.
- The webservice used to download all the information.
Things I've tried thus far:
- Wiping the device - did nothing
- Connecting the device to Eclipse to see what is going on - didn't find anything useful
- Running the code on a 8330 simulator with 4.5 (MDS running)- works flawlessly with no problems
Does anyone know how to fix this issue?
Here is how I build my connection string:
String webserviceURL = developmentUrl;
// if it is simulator then force the network that is available on
// the PC
if (DeviceInfo.isSimulator()) {
webserviceURL += ";deviceside=true";
} else if ((CoverageInfo.getCoverageStatus() & CoverageInfo.COVERAGE_MDS) == CoverageInfo.COVERAGE_MDS) {
// go through MDS
webserviceURL += ";deviceside=false";
}
// else if ((CoverageInfo.getCoverageStatus() &
// CoverageInfo.COVERAGE_CARRIER) == CoverageInfo.COVERAGE_CARRIER)
// {
// webserviceURL += "'deviceside=true";// go direct
// }
// check if the wifi is available and change the url to use the wifi
// signal
if ((RadioInfo.getActiveWAFs() & RadioInfo.WAF_WLAN) != 0)
// check for carrier
{
if (WLANInfo.getWLANState() == WLANInfo.WLAN_STATE_CONNECTED)
// check for wifi
{
// WebService URL when the app is being used in the
// actual device
webserviceURL = webserviceURL + ";interface=wifi";
}
}
// WebService URL when the app is being used in the actual device
_propertyValues = new Object[] { webserviceURL };
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我能够通过大约 50k 数据块来解决这个问题。我很乐意帮助任何有类似问题的人。
I was able to solve this problem by going to ~50k chunks for the data. I'm happy to help anyone who has a similar issue.