码迷,mamicode.com
首页 > 其他好文 > 详细

[J2ME] 获得MIDlet信息

时间:2014-07-26 17:07:02      阅读:258      评论:0      收藏:0      [点我收藏+]

标签:des   style   blog   http   java   color   os   数据   

 

bubuko.com,布布扣

 1 import javax.microedition.lcdui.Display;
 2 import javax.microedition.lcdui.Form;
 3 import javax.microedition.lcdui.TextField;
 4 import javax.microedition.midlet.MIDlet;
 5 import javax.microedition.midlet.MIDletStateChangeException;
 6 
 7 
 8 public class main extends MIDlet {
 9     
10     private Display ds;
11     private Form fr;
12     private TextField tf;
13     private String proString="";
14     
15     public main() {
16         // TODO Auto-generated constructor stub
17         proString=proString+"厂商: "+getAppProperty("MIDlet-Vendor")+"\n";
18         proString=proString+"描述: "+getAppProperty("MIDlet-Description")+"\n";
19         proString=proString+"自定义版本: "+getAppProperty("jadFile-Version")+"\n";
20         proString=proString+"数据空间: "+getAppProperty("MIDlet-Data-Size");
21         fr=new Form("MIDlet Properties");
22         tf=new TextField("属性:",proString,500,TextField.ANY);
23         fr.append(tf);
24     }
25 
26     protected void destroyApp(boolean arg0) throws MIDletStateChangeException {
27         // TODO Auto-generated method stub
28 
29     }
30 
31     protected void pauseApp() {
32         // TODO Auto-generated method stub
33 
34     }
35 
36     protected void startApp() throws MIDletStateChangeException {
37         // TODO Auto-generated method stub
38         ds=Display.getDisplay(this);
39         ds.setCurrent(fr);
40     }
41 
42 }

 

[J2ME] 获得MIDlet信息,布布扣,bubuko.com

[J2ME] 获得MIDlet信息

标签:des   style   blog   http   java   color   os   数据   

原文地址:http://www.cnblogs.com/zjutlitao/p/3870228.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!