Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

sending jar file in a binary SMS

 
Girish Vasmatkar
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,

My question : Is it possible to send jar file from a web application in a binary SMS?I am developing an application which will send a jad and jar file to the mobile phone similar to the one mobile service providers send configuration settings to the mobile phone.My application will accept mobile number from the user and then the web application will communicate to the SMSC and the SMSC will in turn send the jar file to the user's mobile phone so that user dont have to bother about the GPRS connection.
My doubt is whether it is possible or the content have to be sent using MMS which requires GPRS connection.

Thanks and Regards,
Girish Vasmatkar
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18276
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In theory, yes. But there are 2 practical problems.

1. SMS is limited to 160 characters or less. That means a really small JAR file!

2. Notice I said characters. It has to be text. So you'd need to MIME-encode it. Which is going to cut the actual allowable JAR size even more, since MIME requires multiple characters to encode a single byte.

You're better off using the HTTP data channel instead. On my network, web and SMS come as part of the same pricing structure anyway, although I'm cheap and haven't gone for the flat fee for unlimited use (not enough usage to make it pay for me). So they'd bill me by the kilobyte.
 
Rashid Mayes
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Host the jar/jad on your web server and send a SMS with a link to the app or a WAP push.
 
Girish Vasmatkar
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Host the jar/jad on your web server and send a SMS with a link to the app or a WAP push.


Thanks for the reply but what i want to do is to send the application in the message itself rather the link to the application so that user don't have to be dependent on the GPRS. My application will be represented in an XML and that XML will be converted to WBXML format. So here is the question that is it possible to convert the appliocation(jad/jar file) in to the XML form?If it is then how can i accomplish this using a program.?

Thanks and Regards,
Girish Vasmatkar
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18276
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JAR files and the Java compiled classes in them are binary data, not text data. XML isn't really suited for transmission of binary data - the only truly safe way to pack a JAR or other binary file into XML is to MIME-encode it into text. Which makes it bigger. And you'd still have to make the whole thing, XML tags and all be 160 characters or less to be able to fit it in an SMS message packet.
 
Arno den Hond
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how about specifying the MMS:// protocol in stead of SMS:// in the connection construction method?
also, how would a MMS message need to be marked up to properly attach a binary file (such as a jar)??
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18276
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The only MMS I'm familiar with is Microsoft's multimedia server stuff, and that probably won't work on all those non-Windows Nokia phones (among others).

SMS itself has the 160-character limit wired into it - as far as I know, the telephone companies may even have routers that kick out anything longer at the hardware level.

You can embed a URL into an SMS message and thereby turn the upload responsibilities to a protocol and program that don't suffer from that limit. In fact, a number of SMS-based information services do exactly that.
 
bharath bs
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tim Holloway wrote:The only MMS I'm familiar with is Microsoft's multimedia server stuff, and that probably won't work on all those non-Windows Nokia phones (among others).

SMS itself has the 160-character limit wired into it - as far as I know, the telephone companies may even have routers that kick out anything longer at the hardware level.

You can embed a URL into an SMS message and thereby turn the upload responsibilities to a protocol and program that don't suffer from that limit. In fact, a number of SMS-based information services do exactly that.
 
Amit Ghorpade
Bartender
Posts: 2854
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"bharath bs "please check your private messages for an important administrative matter. You can check them by clicking the My Private Messages link above.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic