Allove Team 致力于移动应用的开发和服务(Android,J2ME,iphone,ophone)
标签类目:J2ME

手机课程表

手机课程表 官方网站
你是不是经常忘记今天什么课呢?又是不是时常记不得哪里做实验呢?你是不是有时惊诧的想起忘了今天还有选修课呢?这些情况是不是时常困扰着你呢!怎么办?总不能随身带张课程表吧!三分钟,只需不到三分钟,烦恼去无综。allove手机课程表,让你不再有烦恼。
Allove手机课程表是专业开发人员为学生朋友量身打造的一款实用手机软件。它集成了通常课程管理记录的常用功能,其方便性和实用性的设计初衷决定了最完美的用户体验。从界面的设计以及实用的功能来说都是一款不可多得的手机软件。
功能包括查看课表,新建课表,及在线升级功能等。

运行平台 :j2me

支持机型: 支持MIDP 2.0 CLDC 1.1 的所有机型

下载 :jad jar

秦涛:IT男民工

本人 目前本科学历 学习J2ME JEE symbian 和LINUX 爱好广泛 喜欢旅游 交朋友

秦涛 男 未婚 武汉大学

未就业….

邮箱:qintao1987@126.com

QQ:348435912

秦涛的文章:http://blog.allove.org/archives/author/qintao

NOTICE :本文是为了测试SEO理论而编写!

秦涛 2009-1-23

j2me 实现GPS定位指南针

用J2ME 访问GPS数据 实现自己的指南针
效果图compass

支持A-GPS 的手机都可以使用!

源码贴了出来分享给大家!

源码:
compass-location

j2ME中 lwuit实现按钮缩放功能代码解析

LWUIT UI

当用户按下按钮的时候 实现缩放功能

final Button b = new Button(NameList[i], unselectedImages[i]) {

public Image getPressedIcon() {
Image i = getIcon();
return i.scaled((int) (i.getWidth() * 0.8), (int) (i.getHeight() * 0.8));
}
};

LWUIT Image 实现代码

public Image scaled(int width, int height) {
if(width == getWidth() && height == getHeight()) {
return this;
}
Dimension d = new Dimension(width, height);
Image i = getCachedImage(d);
if(i != null) {
return i;
}
i = new Image(this.image);
i.scale(width, height);
i.transform = this.transform;
cacheImage(d, i);
return i;
}

获得图片缓冲

Image getCachedImage(Dimension size) {
if(scaleCache != null) {
WeakReference w = (WeakReference)scaleCache.get(size);
if(w != null) {
return (Image)w.get();
}
}
return null;
}

使用Allove短信助手发元旦祝福

元旦在即  欢迎大家试用ALLOVE 短信助手给好友发送祝福短信!

ALLOVE 短信助手经过一段时间的开发 也基本上成型了。现在开始内部测试了哦 。

ALLOVE 短信助手 通过GPRS 从服务器上面获得及时的各式各样的短信  完全免费使用

使用ALLOVE 瞬间可以获得互联网上的无限的短信,让你的手机短信从此带有个性 并能轻松将其分享给您的朋友!

13

测试下载地址 :ALLOVE 短信助手

手机OTA 安装地址 :http://m.allove.org/ver/sms.jad

支持手机型号:

·K300c  ·K500c  ·K500i  ·K506  ·K508  ·K510  ·K550c  ·K600  ·K700  ·K750

·K758c  ·K790c  ·K800c  ·K810c  ·K858c  ·S500c  ·T650i  ·T923i  ·W300c  ·W550c

·W580c  ·W610c  ·W660i  ·W710  ·W800  ·W810  ·W830c  ·W850  ·W880  ·W888c

·W910c  ·Z550c  ·Z558  ·Z710  ·Z800  ·J300C  ·K1  ·K310C  ·K530

·K818c  ·L72  ·L7i  ·M608c  ·P1c  ·P800  ·P908  ·P910c  ·S700C  ·T618

·T628  ·T658  ·W200c  ·W600c  ·W700c  ·W958c  ·Z3  ·Z520C  ·Z530C  ·Z608C

诺基亚:

·3109  ·3110  ·3230  ·3250  ·3500  ·5200  ·5300  ·5320  ·5500  ·5700  ·6085

·6086  ·6110  ·6120  ·6121  ·6124  ·6210  ·6220  ·6260  ·6300  ·6620  ·6650

·6680  ·6681  ·6682  ·6630  ·6670  ·7373  ·7390  ·7610  ·E50   ·E51   ·E60

·E61   ·E61i  ·E62   ·E65   ·E66   ·E70   ·E71   ·E90   ·N70   ·N71   ·N72

·N73   ·N75   ·N76   ·N77   ·N78   ·N80   ·N81   ·N82   ·N90   ·N91   ·N92

·N93   ·N93i  ·N95   ·N96   ·2610  ·2626  ·2630  ·2650  ·2660  ·2760  ·3100

·3108  ·3120  ·3200  ·3220  ·3300  ·5070  ·5310  ·5610  ·6020  ·6021  ·6030

·6060  ·6070  ·6080  ·6100  ·6101  ·6102  ·6108  ·6111  ·6125  ·6131  ·6170

·6230  ·6270  ·6288  ·6500  ·6600  ·6610  ·6820  ·7200  ·7210  ·7250  ·7260

·7270  ·7360  ·7370  ·7500  ·7610  ·7650  ·8600  ·8800  ·2600c  ·6060V

·N-GageQD

摩托罗拉:

·A1200  ·A780  ·E2  ·E6  ·E680i  ·A668  ·A728  ·A732  ·A760  ·A760i

·A768  ·A768i  ·C168  ·C381  ·C650  ·E375  ·E398  ·E770  ·L2  ·L6

·L6g  ·L6i  ·L7  ·U6  ·V180  ·V191  ·V220  ·V3  ·V300  ·V303

·V360  ·V3i  ·V3r  ·V3re  ·V500  ·V501  ·V600  ·V600I  ·V635

·V690  ·V8  ·V80  ·V872  ·V878  ·W510  ·Z6

三星:

·B508  ·C158  ·C208  ·C218  ·C238  ·C308  ·C458  ·D418  ·D428  ·D488

·D508  ·D528  ·D608  ·D618  ·D808  ·D820  ·D828  ·D838  ·D848  ·D888

·D908  ·D908i  ·E108  ·E118  ·E208  ·E218  ·E250  ·E258  ·E338  ·E348

·E358  ·E368  ·E378  ·E388  ·E398  ·E418  ·E428  ·E488  ·E498  ·E538

·E578  ·E608  ·E618  ·E628  ·E638  ·E648  ·E708  ·E728  ·E738  ·E758

·E768  ·E778  ·E788  ·E788e  ·E808  ·E818  ·E838  ·E848  ·E898  ·E908

·E958  ·F118  ·G608  ·G808E  ·J218  ·J608  ·J618  ·L608  ·M608  ·M618

·P318  ·P518  ·P738  ·P858   ·S208  ·U308  ·U608  ·X108  ·X138  ·X168

·X208  ·X218  ·X308  ·X458  ·X468  ·X478  ·X488  ·X518  ·X608  ·X628

·X638  ·X648  ·X658  ·X668  ·X678  ·X818

请注意:以上信息是为了方便有相应手机的朋友,其实只要你的手机支持JAVA就可以使用了 ^_^ !

测试下载地址 :ALLOVE 短信助手

通过手机OTA安装:http://m.allove.org/ver/sms.jad

先祝福大家元旦快乐!

建议反馈 :qintao1987@126.com

短信分类调查表:review.doc

The ABC to JAVA

寒假来了。回家准备写些ABC about java (java 入门的一些东西)也算是对自己学习的一个总结吧!

toolsandresourcesforspellch

这些都是我以前学习的时候学习的内容  不知道能不能写出来  ,写不出来转载去 。。

俺学过的东西

java IDE

JAVA ECLIPSE 常用插件

JAVA 常用代码结构

JAVA 命名规则

JAVA 网络通信   (Socket 可以用来来实现 SYMBIAN C++和J2ME 的通信  ,这个是很不错的应用  一下子 把J2ME 无法访问的东西都搞定了 。SYMBIAN C++写个守护进程 负责和J2ME 的代码通信 就可以访问以前受操作系统保护的内容了! )

JAVA 线程

JAVA 异常的处理 异常捕获和异常灵活应用

JAVA 与模式

JAVA 性能与多线程

SWT 用户界面设计

JAVA 数据库操作

JAVA 程序和操作系统底层通信

利用J2SE 开发快速开发网络数据分析工具

J2ME MIDLET

J2ME Canvas

JEE

常用开源工具包  KXML ,QRCODE,

JAVA 好网站

我读过的关于JAVA 的书

分享:SQL数据格式转换为XML数据

有很强大的数据库同步的软件和中间件支持SQL 数据到XML的转换 ,但是对于自己的项目不需要那么的功能 安装这么多东西 感觉有点得不偿失,还不如自己手写数据转换代码省事!
这个是个很激简单的数据转换的方法 供大家参考!

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileReader;
import java.io.FileWriter;
import java.util.regex.Pattern;

public class SqlParser implements Runnable{

private String result;
private File f;

public static void main(String[] args) {
Thread t=new Thread(new SqlParser());
t.start();

}

public String getTemplate(String fileName) {

result = "< ?xml version="1.0" encoding="gb2312"?><xml>";
try {

f = new File(fileName);
BufferedReader br = new BufferedReader(new FileReader(f));
String temp = br.readLine();
while (temp != null) {
temp = parser(temp);

result += temp + "n";
temp = br.readLine();
}
br.close();

} catch (Exception e) {
e.printStackTrace();
}

return result;
}

public String parser(String str) {
String r = "";
String temp = str;
String[] t = temp.split(",");
for (int i = 0; i < t.length; i++) {
if (i == 0) {
r += "<node><a>" + t[i] + "</a>";
} else if (i == 1) {
r += "<b>" + t[i] + "</b>";
} else if (i == 2) {
r += "<c>" + t[i] + "</c>";
} else if (i == 3) {
r += "<d>" + t[i] + "</d>";
}
}
return r;

}

public void write(String str, String filename) {
try {
File f = new File(filename);
BufferedWriter output = new BufferedWriter(new FileWriter(f));

output.write(str);
output.flush();
output.close();
} catch (Exception e) {
e.printStackTrace();
}
}

@Override
public void run() {
System.out.println("Start parsering........Please wait!");
System.out.println("This may take few min depend on the files length");

this.write(this.getTemplate("data.txt"), "data.xml");
System.out.println("Parser Success!");

}

}
</xml>

JAVA对象序列化实现移动终端与服务器高效通信

移动终端—接触过的开发者首先要明白的一点就是这是一个受限设备,也就是说它没有足够的CPU时间,没有足够的RAM来供你奢侈,不像在PC上面那么为所欲为。就这点而言,就限制了你很多的活动,所以在移动设备上面一定要将UI或者逻辑模块化,功能化,用最少的资源消耗作出效果。

废话完了,进入正题:使用JAVA对象序列化机制来实现J2ME移动终端与J2EE服务器的高效通信。所谓序列化就是将对象状态转化为可以持久存储或传输的格式的过程。与序列化相对的自然就是反序列化了,就是将流转化为对象。这两个过程结合起来就可以轻松的实现数据的本地存储和传输,在J2ME终端上的最大好处就是减少了对象的内存消耗以及冗余的对象。

通常我们在J2ME终端需要处理的数据格式或者类型跟服务器上面是不一样的但是通过序列化就可以做到很好的统一。实现服务器与终端的高速通信。下面是一个简单的对象序列化与反序列化例子:

  1. public class SerializeDemo {
  2.  
  3. private String userName ;
  4.  
  5. privare String passewd;
  6.  
  7. private int age ;
  8.  
  9. // here shoud be some getters and setters
  10.  
  11. //##############
  12.  
  13. //序列化对象
  14.  
  15. public byte[] serialize() throws IOException(){
  16.  
  17. ByteArrayOutputStream bout = new ByteArrayOutputStream();
  18.  
  19. DataOutputStream dataStream = new DataOutputStream();
  20.  
  21. dataStream.writeUTF(userName);
  22.  
  23. dataStream.writeUTF(passwd);
  24.  
  25. dataStream.writeInt(age);
  26.  
  27. return bout.toByteArray();
  28.  
  29. }
  30.  
  31. //反序列化对象
  32.  
  33. public void deserialize(byte[] data) throws IOException(){
  34.  
  35. ByteArrayInputStream bin = new ByteArrayInputStream(data);
  36.  
  37. DataOutputStream dataStream = new DataOutputStream(bin);
  38.  
  39. userName = dataStream.readUTF(userName);
  40.  
  41. passwd = dataStream.readUTF(passwd);
  42.  
  43. age = dataStream.readInt(age);
  44.  
  45. }
  46. }

上的的代码创建了一个输出流对象,按照一定的顺序把对象的各种属性转化为二进制的数据,然后用一个输入流取出数据以作他用。这样的话我们就可以将一些服务器和终端都要用到并交互的对象进行序列化然后以流动形式在客户端和服务端进行通信。流通信一定会比属性的单独操作来得高效。

Running an application in an emulator in s60

手机开发模拟器的使用  这里NOKIA S60 FP1 的模拟器 即可以用做   SYMBIAN C++  开发模拟器

又可以用作J2ME 开发的模拟器  测试结果几乎和真机一样 除了网络通信方面!

注意:  对于初学者 内存卡的存放路径为

Symbian9.2S60_3rd_FP1Epoc32winscwcData

将开发的JAR 包或者 SIS文件拷贝进去就可以了

下面是模拟器的官方教程 !

To view an S60 application in an S60 emulator:

  1. In the
    group

    folder of your application, enter the following command:

    epoc

    The emulator opens.

    Note: The emulator may take some time to open.

  2. Click the Menu key.

    Figure 7: Clicking the menu key in the emulator

  3. To open the Installations folder, navigate to it by clicking on the
    selection

    key with your mouse and click the center of the

    selection

    key.

    Figure 8: Selecting the installation folder in the emulator

  4. To open the HelloWorldBasic application, select it and click the
    selection

    key.

    Figure 9: Selecting the HelloWorldBasic example

    The initial view of the HelloWorldBasic application opens.

Figure 10: Initial view of the HelloWorldBasic example

(如何利用J2ME获得IMEI编码)How to get IMEI in Java ME

IMEi

what is IMEI

The IMEI (International Mobile Equipment Identity) is a unique 17 or 15 digit code used to identify an individual mobile station to a GSM or UMTS network. The IMEI number provides an important function; it uniquely identifies a specific mobile phone being used on a mobile network. The IMEI is a useful tool to prevent a stolen handset from accessing a network and being used to place calls. Mobile phone owners who have their phones stolen can contact their mobile network provider and ask them disable a phone using its IMEI number. With an IMEI number, the phone can be blocked from the network quickly and easily.

IMEI (国际移动身份识别码)是一个唯一的17位或者15位的数字编码用来标识一部唯一的移动终端。IMEI 提供了一个重要的运用就是在网络中用来比标识唯一的识别方式。 继续阅读 »

返回顶部