javaʵÏÖ¶ÔÏó³Ø
/*
* @(#)ObjectPoolManager.java 1.00 2005-5-1
*
* Copyright 2005 BeanSoft Studio. All rights reserved.
* PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*/
package beansoft.util;
import java.util.HashMap;
import beansoft.util.logging.Logger;
/**
* ObjectPoolManager, dynamic manage pooled objects' create and release.
*
* @author BeanSoft
* @version 1.00 2005-5-1
*/
public final class ObjectPoolManager {
static Logger logger = beansoft.util.logging.Logger.getLogger(ObjectPoolManager.class);
/**
* Holds instances of ObjectPool, the main key is the type of objects in this pool.
*/
private static HashMap objectPools = new HashMap();
/**
* This class is not instanceable.
*/
private ObjectPoolManager() {
}
/**
* Get a ObjectPool instance from the objectPools, if not found, then lazilly
* create a new one.
* @param clazz the object type
* @return the ObjectPool instance
*/
private stat
Ïà¹ØÎĵµ£º
JavaỊ̈߳ºÐÂÌØÕ÷-Ìõ¼þ±äÁ¿
Ìõ¼þ±äÁ¿ÊÇJava5Ïß³ÌÖкÜÖØÒªµÄÒ»¸ö¸ÅÄ¹ËÃû˼Ò壬Ìõ¼þ±äÁ¿¾ÍÊDZíʾÌõ¼þµÄÒ»ÖÖ±äÁ¿¡£µ«ÊDZØÐë˵Ã÷£¬ÕâÀïµÄÌõ¼þÊÇûÓÐʵ¼Êº¬ÒåµÄ£¬½ö½öÊǸö±ê¼Ç¶øÒÑ£¬²¢ÇÒÌõ¼þµÄº¬ÒåÍùÍùͨ¹ý´úÂëÀ´¸³ÓèÆ京Òå¡£
ÕâÀïµÄÌõ¼þºÍÆÕͨÒâÒåÉϵÄÌõ¼þ±í´ïʽÓÐ×ÅÌìÈÀÖ®±ð¡£
Ìõ¼þ±äÁ¿¶¼ÊµÏÖÁË ......
JavaỊ̈߳ºÐÂÌØÕ÷-Ô×ÓÁ¿
ËùνµÄÔ×ÓÁ¿¼´²Ù×÷±äÁ¿µÄ²Ù×÷ÊÇ“Ô×ӵĔ£¬¸Ã²Ù×÷²»¿ÉÔÙ·Ö£¬Òò´ËÊÇḬ̈߳²È«µÄ¡£
ΪºÎҪʹÓÃÔ×Ó±äÁ¿ÄØ£¬ÔÒòÊǶà¸öÏ̶߳Ե¥¸ö±äÁ¿²Ù×÷Ò²»áÒýÆðһЩÎÊÌâ¡£ÔÚJava5֮ǰ£¬¿ÉÒÔͨ¹ývolatile¡¢synchronized¹Ø¼ü×ÖÀ´½â¾ö²¢·¢·ÃÎʵݲȫÎÊÌ⣬µ«ÕâÑùÌ«Âé·³¡£
Java5Ö®ºó£¬× ......
Java Éú³É EXCEL POIÎĵµËµÃ÷
POI°æ±¾:3.0.2-FINAL
ÏÂÔصØÖ·: http://poi.apache.org/index.html
Ò»°ãÔÚÏîÄ¿ÖÐÕæÕýҪʵÏÖÕâÑùÒ»¸ö±í¸ñµÄʱºò£¬ÀýÈçÏîÄ¿ÐèÒªÖÆ×÷±¨±íµÈµÈ£¬Í¨³£µÄ×ö·¨¶¼ÊÇÊÂÏȰѸñʽһÇеĶ«Î÷¶¼ÊÖ¶¯ÖÆ×÷ºÃ£¨Õâ¸ö×öºÃÁ˵ÄÎļþÔÚʵ¼ÊµÄÏîÄ¿ÀïÎÒÃdzÆ֮Ϊ“Êý¾ÝÄ£°å”£¬¼ò³Æ“Ä£°å&rd ......
¡¡¡¡6.1 »ù±¾Êý¾ÝÀàÐÍ
¡¡¡¡´«ÊÚÐÂÖª
¡¡¡¡ÔÚJavaÓïÑÔÖУ¬Êý¾ÝÀàÐÍ¿ÉÒÔ·ÖΪÁ½´óÀࣺ
¡¡¡¡1£©»ù±¾ÀàÐÍ£»
¡¡¡¡2£©À©Õ¹ÀàÐÍ¡£
¡¡¡¡ÔÚ±¾Ð¡½ÚÖУ¬ÎÒÃǾÍÒ»ÆðÀ´Ñ§Ï°Ò»ÏÂJavaÓïÑԵĻù±¾Êý¾ÝÀàÐÍ¡£Ëü°üÀ¨£ºboolean¡¢char¡¢byte¡¢int¡¢short¡¢long¡¢float¡¢double°ËÖÖ£º
¡¡¡¡ÀàÐÍ ÃèÊö È¡Öµ·¶Î§
¡¡¡¡Boolean ²¼¶ûÐÍ Ö»ÓÐÁ½¸öÖµt ......
synchronized£º ͬ²½µÄ
synchronizedÔÚ²Ù×÷ÉÏÓÐÁ½ÖÖÓ°Ïì¶ÔÏóµÄÇé¿ö£º
1) ÔÚij¸ö¶ÔÏóʵÀýÄÚ£¬synchronized method(){}¿ÉÒÔ·ÀÖ¹¶à¸öÏß³Ìͬʱ·ÃÎÊÕâ¸ö¶ÔÏóµÄsynchronized·½·¨£¨Èç¹ûÒ»¸ö¶ÔÏóÓжà¸ösynchronized·½·¨£¬Ö»ÒªÒ»¸öÏ̷߳ÃÎÊÁËÆäÖеÄÒ»¸ösynchronized·½·¨£¬ÆäËüÏ̲߳»ÄÜͬʱ·ÃÎÊÕâ¸ö¶ÔÏóÖÐÈκÎÒ»¸ösynchronized·½·¨£ ......