É possível uma aplicação MIDlet detectar quem é o fabricante do celular?
Algumas respostas que achei:
[quote]On Nokia and SonyEricsson telephones, you can use System.getProperty(“j2me.platform”)
Unfortunatley, Motorola, LG, Samsung and other manufacturers return null or “j2me”. This is in particular annoying because the phones returning null usually require most of the quirks workarounds.
If the MIDlet is downloaded via WAP(PUSH) or XHTML, and you have control over the OTA server, you can let the OTA server write the user agent in a JAD file property…[/quote]
[quote]Until recently it’s been hard to obtain this information, but with the birth of the new series of MIDP 2.0 phones, starting with the Sony Ericsson Z1010 and including the K700, K500, Z500 and S700/S710 series, and the Vodafone-specific F500i and V800, this can be done very easily.
On the phones mentioned above, calling the method:
System.getProperty(“microedition.platform”)
will return a string that look like this:
SonyEricssonK700i/R2L001
The text before “/” is the phone model, and the text after “/” is the firmware version. [/quote]
Um método pra ver algumas opções:
public void startApp() throws MIDletStateChangeException
{
System.out.println("microedition.jtwi.version: " +
System.getProperty("microedition.jtwi.version"));
System.out.println("microedition.configuration: " +
System.getProperty("microedition.configuration"));
System.out.println("microedition.profiles: " +
System.getProperty("microedition.profiles"));
System.out.println("microedition.locale: " +
System.getProperty("microedition.locale"));
System.out.println("microedition.platform: " +
System.getProperty("microedition.platform"));
System.out.println("device.model: " +
System.getProperty("device.model"));
System.out.println("software.version: " +
System.getProperty("software.version"));
System.out.println("microedition.encoding: " +
System.getProperty("microedition.encoding"));
System.out.println("microedition.commports: " +
System.getProperty("microedition.commports"));
}
Agora é testar, não sei se funciona com todos os fabricantes, como a citação de cima afirma.