04-04-2007, 09:30 AM
|
#2 (permalink)
|
| Knows Where the Search Button Is
Join Date: Feb 2007 Model: 9000 Carrier: SFR
Posts: 48
Post Thanks: 0 Thanked 0 Times in 0 Posts
| Hi,
What you want to do is to code a standard http client in order to avoid handling TCP connection "issues" (data plan or not/direct connection ...).
TCP connection have three use case.
First you have an adequat data plan which allows a direct tcp connection. Problem with that (in us) is that this data plan could be expensive.
conn=(StreamConnection)Connector.open("socket://testserver:600;deviceside=true");
Second solution (whithout the data plan) your server is on the same network than your bes/mds so that goes straight.
Third solution (whithout the data plan) your server is in another network so you need to ask your admins to open connections.
conn=(StreamConnection)Connector.open("socket://testserver:600;deviceside=false");
please notice the particularity of socket connection where you wants to add "deviceside" parameter.
Just code is as a "standard" java connection except some api are a little bit differents. I believe you can find easily such programs on google. |
| Offline
| |