Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Google Maps API in Java ME

Here is a simple library to query Google Maps with the following features:
geocode addresses to their geographic coordinates
retrieve static images with given custom size, format and zoom
To see a live sample of this API, you can check here: Java ME Google Maps API sample MIDlet
Contents
[hide]
1 Get your own Google Maps API Key
2 Use a Proxy server to access Google Map services
3 Source code: GoogleMaps class
4 Utility method for map scrolling
5 Source code: sample usage
Get your own Google Maps API Key
NOTE: Usage of this code with the free Google Maps API Key breaks Google's Terms and Conditions (section 10.8). You should purchase an Enterprise License if you wish to use the Google Maps API as shown in this example.
To use the following code, you should get your own Google Maps API Key. If you have not an API key, you can follow the instructions here: How to use Google Maps data in mobile applications
Use a Proxy server to access Google Map services
Note: this subject (proxy usage) is probably non necessary, still investigating it..
When you sign up to obtain a Google Maps API key, you enter the address that will be able to access Maps services with that key. For this reason, you should setup a Proxy server on that address that will receive HTTP requests from your mobile clients, forwarding them to Google Maps services, giving back Google responses.
In the code below, you should forward the following requests:
http://www.yourserver.com/geo requests to http://maps.google.com/maps/geo
http://www.yourserver.com/staticmap requests to http://maps.google.com/staticmap
Source code: GoogleMaps class
import java.io.ByteArrayOutputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Vector;
import javax.microedition.io.Connector;
import javax.microedition.io.HttpConnection;
import javax.microedition.lcdui.Image;
 
public class GoogleMaps {
private st


Ïà¹ØÎĵµ£º

javaÏ̳߳ØThreadPoolExecut

JDK1.5ÖеÄÏ̳߳Ø(java.util.concurrent.ThreadPoolExecut
6
ÍƼö
ÔÚ¶àÏ̴߳óʦDoug LeaµÄ¹±Ï×Ï£¬ÔÚJDK1.5ÖмÓÈëÁËÐí¶à¶Ô²¢·¢ÌØÐÔµÄÖ§³Ö£¬ÀýÈ磺Ï̳߳ء£
Ò»¡¢¼ò½é
Ï̳߳ØÀàΪ java.util.concurrent.ThreadPoolExecutor£¬³£Óù¹Ôì·½·¨Îª£º
ThreadPoolExecutor(int corePoolSize, int maximumPoolSize,
long keepA ......

»ùÓÚ JVMTI ʵÏÖ Java Ï̵߳ļà¿Ø

Ëæ×ŶàºË CPU µÄÈÕÒæÆÕ¼°£¬Ô½À´Ô½¶àµÄ Java Ó¦ÓóÌÐòʹÓöàÏ̲߳¢ÐмÆËãÀ´³ä·Ö·¢»ÓÕû¸öϵͳµÄÐÔÄÜ¡£¶àÏ̵߳ÄʹÓÃÒ²¸øÓ¦ÓóÌÐò¿ª·¢ÈËÔ±´øÀ´Á˾޴óµÄÌôÕ½£¬²»ÕýÈ·µØʹÓöàÏ߳̿ÉÄÜÔì³ÉÏß³ÌËÀËø»ò×ÊÔ´¾ºÕù£¬µ¼ÖÂϵͳ̱»¾¡£Òò´Ë£¬ÐèÒªÒ»ÖÖÔËÐÐʱÏ̼߳à¿Ø¹¤¾ßÀ´°ïÖú¿ª·¢ÈËÔ±Õï¶ÏºÍ¸ú×Ù Java Ïß³Ì״̬µÄÇл»¡£JDK 1.5 ¼°ÆäºóÐø°æ± ......

Java Spring ÈëÃÅ±Ê¼Ç ÕýÔÚд

1£©¹Ù·½ÍøÕ¾
ÔÚѧϰһ¸ö¼¼ÊõÇ°Ö±µ½¹Ù·½ÍøÕ¾ÊǼ«Îª±ØÒªµÄ£¬¹Ù·½ÍøÕ¾²»µ«Ìṩ°²×°½éÖÊ£¬¶øÇÒÓÐÒ»Êֵļ¼Êõ²Î¿¼×ÊÁÏ¡£Ïл°¼ò˵ http://www.springsource.com/¡£ ÒÔÇ°ÔøÓùýspringframework.org£¬²»ÖªµÀΪʲôҪ¸ÄÁËÃû×Ö¡£
2£©¾­µä²Î¿¼Êé
ÓÐÈËÍƼö¹ýSpring In Action£¬ ÎÒ×Ô¼ºÊÇ´ÓSpring Reference¿ªÊ¼¶ÁµÄ¡£
3£©Á÷Ðеİ汾 ......

¹ØÓÚ¡¶Thinking In Java 4th Edition¡·µÄÒ»¸öÎÊÌâ

     ¹À¼ÆѧϰjavaµÄÂòÁËBruce Eckle¡¶Thinking In Java 4th Edition¡·µÄÐÂÊÖÃÇ£¨ÎÒÒ²ÊÇ£©£¬¹À¼Æ¶à»áÓöµ½Ò»¸öÎÊÌ⣺
±àÒëʱimport static net.mindview.util.Print.*;ÕÒ²»µ½ÏàÓ¦µÄ°ü£¬print·½·¨¾ÍÓò»ÁË¡£ÏÂÃæ°ÑÎҵIJÙ×÷·½·¨Ìù³öÀ´£¬Ï£ÍûÄÜ°ïµ½Äã¡£
     1¡¢°ÑÊé±¾µÄÔ´´úÂë ......

javaÈÕÆÚ¼¼ÇÉ×ܽá

¼ÆËãijһÔ·ݵÄ×î´óÌìÊý
Calendar time=Calendar.getInstance();
time.clear();
time.set(Calendar.YEAR,year); //year Ϊ int
time.set(Calendar.MONTH,i-1);//×¢Òâ,Calendar¶ÔÏóĬÈÏÒ»ÔÂΪ0          
int day=time.getActualMaximum(Calendar.DAY_OF_MONTH);/ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ