javaÎļþ±ÈÀýËõС·Å´ó
1Ê×ÏÈÌí¼ÓÐÞ¸ÄͼƬ¿í¶ÈºÍ¸ß¶ÈµÄ·½·¨
public static void reduceImg(String imgsrc, int widthdist, int heightdist) {
try {
File srcfile = new File(imgsrc);
if (!srcfile.exists()) {
return;
}
// ÔØÈëͼƬÎļþ
Image src = javax.imageio.ImageIO.read(srcfile);
int w0 = src.getWidth(null); // µÃµ½Ô´Í¼¿í
int h0 = src.getHeight(null); // µÃµ½Ô´Í¼³¤
BufferedImage tag = new BufferedImage((int) widthdist,
(int) heightdist, BufferedImage.TYPE_INT_RGB);
// ±£´æÎļþ
// »æÖÆËõСºóµÄͼ
tag.getGraphics().drawImage(
src.getScaledInstance(widthdist, heightdist,
java.awt.Image.SCALE_SMOOTH), 0, 0, null);
// tag.getGraphics().drawImage(src.getScaledInstance(widthdist,
// heightdist, Image.SCALE_AREA_AVERAGING), 0, 0, null);
// ±êעˮӡ
// int x = widthdist/10*8; //ˮӡλÖÃ(x,y)
// int y = heightdist/10*8;
// jpg_logo( tag , x , y );
// ÖØÃüÃû²¢Ð½¨Í¼Æ¬
String oleName = imgsrc.substring(imgsrc.lastIndexOf(".") - 1,
imgsrc.lastIndexOf("."));
String newName = oleName + "v";
String imgdist = imgsrc.replace(oleName, newName);
// Êä³öµ½ÎļþÁ÷
FileOutputStream out = new FileOutputStream(imgdist);
JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(out);
// ½üJPEG±àÂë
encoder.encode(tag);
out.close();
} catch (IOException ex) {
ex.printStackTrace();
}
}
2°´±ÈÀýÈ¥ËõСͼƬ
Ïà¹ØÎĵµ£º
ÓÉÓÚFlex Builder compiler shellÓÐmemory leakµÄÎÊÌ⣬ ¶øSDKĬÈÏµÄµÄ JVM heap size Ö»ÓÐ312M£¬µ±compile±È½Ï´óµÄprojectÈÝÒײ»¹»£¬ËùÒÔÖ»ÒªÐÞ¸ÄSDKµÄJVM²ÎÊý¾Í¿ÉÒÔ¡£
±à¼ {Flex SDK}/bin/jvm.config ÎļþÈçÏ¡£
java.args=-Xmx512m ...
Èç¹û»¹ÊÇÓÐError£¬¿ÉÒÔÔö¼Óµ½1024»òÕ߸ü¶à¡£ ......
=====================================
Ç°ÑÔ
ÔÚÌ«Ô¾ÀúÁËÒ»ÄêµÄÍ´¿à¿ª·¢Ö®ºó£¬ÏîÄ¿ÒѾÈÕÇ÷Îȶ¨£¬½ÓÏÂÀ´µÄ¹¤×÷¾ÍÊÇÄÃÏÖÓеĴúÂëµ½ÆäËûµÄÊ¡ÊнøÐÐʵʩ¡¢È»ºó×öһЩ±¾µØ»¯¿ª·¢¡£ÈÕ×ÓÏà¶ÔÇáËÉÁËÐí¶à£¬ÓÚÊÇ¿ÉÒÔ³é³öʱ¼äÀ´ÎÂϰһϻù´¡µÄ¼¼Êõ֪ʶ£¬¸ø×Ô¼ºÁÐÁËÒ»¸ö¸´Ï°Ìá¸Ù£¬ÕâÒ²ÊÇÒ»¸öjava³ÌÐòÔ±ËùÓ¦¸ÃÕÆÎÕµÄ֪ʶÂöÂç¡£
=== ......
ArcGIS Server9.3ÍêÕûÇåÎú°²×°Á÷³Ì
ÒÔϵÄArcGIS Server9.3°²×°Á÷³ÌÊÇÎÒ¸öÈË×ܽá³öÀ´µÄ£¬ÔÚwindowXP2Ñé֤ͨ¹ý£¬ÐèÒªµÄ»°£¬Ï£ÍûÓõÄ×Å¡£
Ò»¡¢ArcGIS Server²úÆ·°üÀ¨Á½¸ö²¿·Ö£º
1¡¢GIS Server£¬ËüÊÇÒ»¸öÌṩGIS·þÎñµÄ·þÎñÆ÷Èí¼þ²úÆ·£¬°üÀ¨Ò»ÏµÁкËÐÄAO¿âºÍÒ»¸ö¹ ......
1.Ê×ÏÈдһ¸öȨÏÞ¹ýÂËfilterÀà,ʵÏÖFilter½Ó¿Ú
/*Ê×ÏÈдһ¸öȨÏÞ¹ýÂËfilter*/
import javax.servlet.Filter;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.FilterChain;
import ......