Chapter 05 _Objects and Classes(core JavaÕªÒª)
Basic concepts in OOP
Encapsulation:Òþ²ØʵÏÖ¹ý³Ì£¬¶ÔÍâÌṩ¹«¿ªÒ»ÖµĽӿڡ¢Ê¹Èí¼þÒ×ÓÚ¸üÐÂÓëά»¤¡£
Polymorphism£ºÒ»¸öÊÂÎï×Ô¶¯»ñµÃÁíÒ»ÊÂÎïµÄ״̬ÐÐΪµÄ»úÖÆ¡£
Inheritance£ºÒ»¸öÀà×Ô¶¯»ñµÃÁíÒ»¸öÀàµÄÊôÐÔ»òÕß·½·¨µÄ¹ý³Ì¡£
1.ÀàµÄ½á¹¹
ˈ̞
ÊôÐÔÃû
¾²Ì¬ÊôÐÔ
ʵÀýÊôÐÔ£º±ØÐëÒÀÀµÓÚ¶ÔÏó/ʵÀý
·½·¨
¾²Ì¬·½·¨
ʵÀý·½·¨
¹¹ÔìÆ÷
ȱʡ¹¹ÔìÆ÷
´ø²ÎµÄ¹¹ÔìÆ÷
¾²Ì¬´úÂë¿é
ʵÀý´úÂë¿é
2.²ÎÊý´«µÝ
¶ÔÓÚ»ù±¾ÀàÐÍ£¬½«Êµ¼Ê²ÎÊýµÄÖµÔÑùµÄ¸´ÖÆÒ»±é´«Öµ;
¶ÔÓÚÒýÓÃÀàÐÍ£¬½«ÒýÓÃÀàÐͱäÁ¿µÄµØÖ·Öµ¸´ÖƸøʵ²Î¡£
3.Where can we use “this”£¿
A.ʵÀý±äÁ¿ÓÚ¾Ö²¿±äÁ¿Í¬Ãû£¬ÓÃthis¡£ÊµÀý±äÁ¿ÃûÀ´ºÍ¾Ö²¿±äÁ¿¼ÓÒÔÇø·Ö;
B.ÔÚ¹¹ÔìÆ÷µÄÖØÔصÄʱºò£¬ÓÃthisÀ´µ÷ÓÃÆäËûµÄ¹¹ÔìÆ÷;
C.ÔÚʵÀý·½·¨ÖУ¬ÓÃÀ´½«µ±Ç°¶ÔÏóµÄÒýÓô«µÝ¸øÁíÍâµÄ·½·¨¡£
4.·½·¨µÄÖØÔØ
A.·½·¨ÃûÒªÏàͬ;
B.ÔÚÒ»¸öÀàÖУ¬¶à¸ö·½·¨¾ßÓв»Í¬µÄ·½·¨Ç©Ãû(²ÎÊýÀàÐÍ/²ÎÊý¸öÊý/²ÎÊý˳Ðò)£¬·½·¨¿ÉÒÔÖØÔØ
C.·µ»ØÀàÐͲ»×÷ÒªÇó
5.ÀàµÄ³õʼ»¯µÄ¹ý³Ì£º
ÀàµÄ¾²Ì¬³ÉÔ±ÔÚÀà±»¼ÓÔصÄʱºò½øÐгõʼ»¯!
(1) ÔÚ¶ÑÖзÖÅä¿Õ¼ä;
(2) ¸ø¶ÔÏóµÄÊôÐÔ¸³Ä¬ÈÏÖµ
boolean=false;
»ù±¾ÀàÐÍ=0;
ÒýÓÃÀàÐÍ=null;
&nbs
Ïà¹ØÎĵµ£º
2008 Äê 6 ÔÂ 24 ÈÕ
ÔÎĵØÖ·£º http://www.ibm.com/developerworks/cn/data/library/techarticles/dm-0806wangys/
±¾ÎĽéÉÜ IBM FileNet P8 4.0 Platform ÌṩµÄ Content Java API¡£Ê×ÏÈ¶Ô FileNet P8 Content Engine ºÍ API ½øÐиÅÒª½éÉÜ, ²¢ËµÃ÷ÁËһЩ»ù±¾¸ÅÄËæºóÏêϸ½éÉÜÁË FileNet Content EngineÌṩµÄ»ùÓÚ EJB ......
×î½ü¹«Ë¾Åöµ½ÐèÒªÓÃͼ±íµÄÐÎʽÏÔʾһЩÊý¾Ý£¬ÎҾͿªÊ¼µ½ÍøÉϲéѯ£¬²éµ½ÁËjfreechartºÍamcharts,ÕâÁ½ÕßÎÒ¶¼ÊµÏÖ¹ýÁË£¬jfreechart×îºóÉú³ÉͼƬ£¬µ«ÊÇͼƬЧ¹û²»ÊÇÎÒÏëÒªµÄ£¬È»ºóÓÖÑо¿amcharts ËüµÄЧ¹ûȷʵºÜºÃ£¬¶øÇÒ¹Ù·½ÍøÕ¾ÉÏ»¹ÓкÃЩÀý×ӿɹ©ÏÂÔØ£¬ÍøÖ·ÊÇ:www.amcharts.com
£¨ÏëÒªÍê³ÉÒ»¸öamchartsͼÐÎÐèÒªswfobjects. ......
1.1.1 ÐÞÁ¶µÚÒ»²ã¾³½ç£º½£Ö¸ËÄ·½£¬ÊÔÎÊÌìÏÂÓëÕù·æ
ÐÞÁ¶µÚÒ»²ã¾³½çµÄ³ÌÐòÔ±£¬¶ÔJava¿ª·¢¼¼Êõ¾¡ÊýÕÆÎÕ£¬¿ª·¢¹¤¾ßÕÆÎÕµÃÒ²½ÏΪæµÊì¡£¿ÉÒÔ½«µÚ¶þ²ã´Î³ÌÐòÔ±½»¸øµÄÈÎÎñÍê³ÉµÃºÜ³öÉ«£¬¿ÉÒÔ°´ÒªÇó¶ÀÁ¢Íê³ÉÀà¡¢½Ó¿ÚºÍËã·¨µÄ¿ª·¢¡£×¢Öؼ¼ÇÉ£¬¶Ô¾ßÌåµÄ±à³ÌÓïÑԷdz£ÊìϤ¡£
ÄÜÁ¦Ö®Ëù¼°£¬½ÔÎÞ²»ÓÃÆ伫¡£ÈÏΪËùÓпª·¢ÖªÊ¶£¬Ô½ÊÇ¿´Æ ......
ÕâÊÇÒ»¸öûÓÐÑéÖ¤ÐÐÕþÇø´úÂëµÄ£¬ËùÒÔÕâ¸ö²»ËãÍêÈ«£¬µ«ÊÇÎÒÃÇÔÚ×öʵ¼ÊÓ¦ÓÃʱ¿ÉÒÔ¼ÓÉÏ£¬ÕâÀïÎÒû¼Ó¡£
Ô´ÂëÈçϽö¹©²Î¿¼.
package ibees.validator;
import java.util.regex.Pattern;
/**
* ³£ÓõÄÑéÖ¤,source charset utf-8
*
* @author hhzxj2008
* */
public class CommonValidator {
public static boolea ......
import java.io.IOException;
import java.net.InetAddress;
import java.net.InetSocketAddress;
import java.nio.channels.SelectionKey;
import java.nio.channels.Selector;
import java.nio.channels.SocketChannel;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.regex ......