相信做手机开发的都知道,write once debug anywhere。你向从中体验乐趣吗,那先来了解下手机对JSR规范的支持吧。
下面是我从网络上获取一些的信息。
其中一个源代码出自http://www.javaeye.com/topic/75387
大家可以到上面下载源代码,然后稍微修改下,就可以提供对jsr的更多测试了。
关于测试的方面看下面
For instance, the property microedition.commports is present in the MIDP 2.0 specification. Its value is a comma-separated list of ports you can use to build a URL, which the Generic Connection Framework can in turn use to create a javax.microedition.io.CommConnection object.
To query system properties use java.lang.System.getProperty(), as in:
import java.lang.*;
String value;
String key = "microedition.pim.version";
value = System.getProperty( key );
...
This table lists the defined system properties, drawing them from JSRs that are in the public review, final ballot, or final state, as defined in the Java Community Process (JCP):
J2ME Defined System Properties
JSR Property Name
Default Value¹
30 microedition.platform null
microedition.encoding ISO8859_1
microedition.configuration CLDC-1.0
microedition.profiles null
37 microedition.locale null
microedition.profiles MIDP-1.0
75 microedition.io.file.FileConnection.version 1.0
file.separator (impl-dep)
microedition.pim.version 1.0
118 microedition.locale null
microedition.profiles MIDP-2.0
microedition.commports (impl-dep)
microedition.hostname (impl-dep)
120 wireless.messaging.sms.smsc (impl-dep)
139 microedition.platform (impl-dep)
microedition.encoding ISO8859-1
microedition.configuration CLDC-1.1
microedition.profiles (impl-dep)
177 microedition.smartcardslots (impl-dep)
179 microedition.location.version 1.0
180 microedition.sip.version 1.0
184 microedition.m3g.version 1.0
185 microedition.jtwi.version 1.0
195 microedition.locale (impl-dep)
microedition.profiles IMP-1.0
205 wireless.messaging.sms.smsc (impl-dep)
205 wireless.messaging.mms.mmsc (impl-dep)
211 CHAPI-Version 1.0
这个是e文的
看看中文的吧
JSR
|
属性名称
|
默 认 值
|
30
|
microedition.platform
|
null
|
microedition.encoding
|
ISO8859_1
| |
microedition.configuration
|
CLDC-1.0
| |
microedition.profiles
|
null
| |
37
|
microedition.locale
|
null
|
microedition.profiles
|
MIDP-1.0
| |
75
|
microedition.io.file.FileConnection.version
|
1.0
|
file.separator
|
依赖于底层实现
| |
microedition.pim.version
|
1.0
| |
118
|
microedition.locale
|
null
|
microedition.profiles
|
MIDP-2.0
| |
microedition.commports
|
依赖于底层实现
| |
microedition.hostname
|
依赖于底层实现
| |
120
|
wireless.messaging.sms.smsc
|
依赖于底层实现
|
139
|
microedition.platform
|
依赖于底层实现
|
microedition.encoding
|
ISO8859-1
| |
microedition.configuration
|
CLDC-1.1
| |
microedition.profiles
|
依赖于底层实现
| |
177
|
microedition.smartcardslots
|
依赖于底层实现
|
179
|
microedition.location.version
|
1.0
|
180
|
microedition.sip.version
|
1.0
|
184
|
microedition.m3g.version
|
1.0
|
185
|
microedition.jtwi.version
|
1.0
|
195
|
microedition.locale
|
依赖于底层实现
|
microedition.profiles
|
IMP-1.0
| |
205
|
wireless.messaging.sms.smsc
|
依赖于底层实现
|
205
|
wireless.messaging.mms.mmsc
|
依赖于底层实现
|
