JAVA ÄÚ²¿ÀàµÄ¼òµ¥×ܽá
¶¨ÒåÔÚÒ»¸öÀàÄÚ²¿µÄÀà½ÐÄÚ²¿À࣬°üº¬ÄÚ²¿ÀàµÄÀà³ÆÎªÍⲿÀà¡£ÄÚ²¿Àà¿ÉÒÔÉùÃ÷public¡¢protected¡¢privateµÈ·ÃÎÊÏÞÖÆ£¬¿ÉÒÔÉùÃ÷ΪabstractµÄ¹©ÆäËûÄÚ²¿Àà»òÍⲿÀà¼Ì³ÐÓëÀ©Õ¹£¬»òÕßÉùÃ÷Ϊstatic¡¢finalµÄ£¬Ò²¿ÉÒÔʵÏÖÌØ¶¨µÄ½Ó¿Ú¡£staticµÄÄÚ²¿ÀàÐÐΪÉÏÏóÒ»¸ö¶ÀÁ¢µÄÀ࣬·ÇstaticÔÚÐÐΪÉÏÀàËÆÀàµÄÊôÐÔ»ò·½·¨ÇÒ½ûÖ¹ÉùÃ÷staticµÄ·½·¨¡£ÄÚ²¿Àà¿ÉÒÔ·ÃÎÊÍⲿÀàµÄËùÓз½·¨ÓëÊôÐÔ£¬µ«staticµÄÄÚ²¿ÀàÖ»ÄÜ·ÃÎÊÍⲿÀàµÄ¾²Ì¬ÊôÐÔÓë·½·¨¡£
ÍⲿÀà°´³£¹æµÄÀà·ÃÎÊ·½Ê½Ê¹ÓÃÄÚ²¿À࣬ΨһµÄ²î±ðÊÇÍⲿÀà¿ÉÒÔ·ÃÎÊÄÚ²¿ÀàµÄËùÓз½·¨ÓëÊôÐÔ£¬°üÀ¨Ë½Óз½·¨ÓëÊôÐÔ¡£È磺
pinner p = new pinner();
p.index = 20;
p.Print();
---- ÕâÖÖ·½Ê½ÊʺÏÍⲿÀàµÄ·Çstatic·½·¨£»
pouter po = new pouter();
pinner pi = po.new pinner();
pi.index = 40;
pi.Print();
---- ÕâÖÖ·½Ê½ÊʺÏÍⲿÀàµÄstatic·½·¨£»
ÄÚ²¿ÀàÀàËÆÍⲿÀàµÄÊôÐÔ£¬Òò´Ë·ÃÎÊÄÚ²¿Àà¶ÔÏóʱ×ÜÊÇÐèÒªÒ»¸ö´´½¨ºÃµÄÍⲿÀà¶ÔÏó¡£ÄÚ²¿Àà¶ÔÏóͨ¹ý‘ÍⲿÀàÃû.this.xxx’µÄÐÎʽ·ÃÎÊÍⲿÀàµÄÊôÐÔÓë·½·¨¡£È磺
System.out.println("Print in inner Outer.index=" + pouter.this.index);
System.out.println("Print in inner Inner.index=" + this.index);
Èç¹ûÐèÒªÔÚÆäËûÀàÖзÃÎÊÄÚ²¿À࣬¿ÉÒÔʹÓãº
(1)ÍⲿÀàÌṩ´´½¨ÄÚ²¿ÀàµÄ·½·¨¹©ÆäËûÀàʹÓá£È磺
// ÍⲿÀà
pinner getInner()
{
return new pinner();
}
// ÆäËûÀà
&nb
Ïà¹ØÎĵµ£º
DOM³õ²½
DOMÊÇDocument Object ModelµÄËõд£¬¼´Îĵµ¶ÔÏóÄ£ÐÍ¡£Ç°ÃæËµ¹ý£¬XML½«Êý¾Ý×é֯Ϊһ¿ÅÊ÷£¬ËùÒÔDOM¾ÍÊǶÔÕâ¿ÅÊ÷µÄÒ»¸ö¶ÔÏóÃèÐð¡£Í¨Ë×µÄ˵£¬¾ÍÊÇͨ¹ý½âÎöXMLÎĵµ£¬ÎªXMLÎĵµÔÚÂß¼ÉϽ¨Á¢Ò»¸öÊ÷Ä£ÐÍ£¬Ê÷µÄ½ÚµãÊÇÒ»¸ö¸ö¶ÔÏó¡£ÎÒÃÇͨ¹ý´æÈ¡ÕâЩ¶ÔÏó¾ÍÄܹ»´æÈ¡XMLÎĵµµÄÄÚÈÝ¡£
ÏÂÃæÎÒÃÇÀ´¿´Ò»¸ö¼òµ¥µÄÀý×Ó£¬¿´¿´ÔÚDOMÖ ......
ÏÈ´´½¨Ò»¸ö´æ´¢¹ý³Ì
create or replace function addvalue(value1 in number, value2 in number) return number is
result number;
begin
result:=value1+value2;
return(result);
end ;
ÏÂÃæÊÇjavaµ÷ÓÃ
Connection conn = JDBCUtils.getConnection();
CallableStatement cs = conn.prepareCall("{? = call addval ......
1.1 ²»ÓÃnew¹Ø¼ü´Ê´´½¨ÀàµÄʵÀý
¡¡¡¡ÓÃnew¹Ø¼ü´Ê´´½¨ÀàµÄʵÀýʱ£¬¹¹Ô캯ÊýÁ´ÖеÄËùÓй¹Ô캯Êý¶¼»á±»×Ô¶¯µ÷Óᣵ«Èç¹ûÒ»¸ö¶ÔÏóʵÏÖÁËCloneable½Ó¿Ú£¬ÎÒÃÇ¿ÉÒÔµ÷ÓÃËüµÄclone()·½·¨¡£clone()·½·¨²»»áµ÷ÓÃÈκÎÀ๹Ô캯Êý¡£
¡¡¡¡ÔÚʹÓÃÉè¼ÆÄ£Ê½£¨Design Pattern£©µÄ³¡ºÏ£¬Èç¹ûÓÃFactoryģʽ´´½¨¶ÔÏó£¬Ôò¸ÄÓÃclone()·½·¨´´½¨Ðµ ......
1£®Servlet³ÌÐòµÄÈë¿ÚµãÊÇ£º£¨ £©
A init£¨£©
B main£¨£©
C service£¨£©
D doGet£¨£©
²Î¿¼´ð°¸£ºA
2. SeverletÖУ¬HttpSeverletResponseµÄʲô·½·¨ÓÃÀ´°ÑÒ»¸öHTTPÇëÇóÖØ¶¨Ïòµ½ÁíÍâµÄURL£¿£¨ £©
A sendURL()
B redirectURL()
C sendRedirect()
D ......
1. StrutsÌåϵ½á¹¹ÊµÏÖÁËMVCÉè¼ÆÄ£Ê½µÄ¸ÅÄÄÇôËü½«ÒÔÏÂÑ¡ÏîÖиø³öµÄʲô·Ö±ðÓ³ÉäΪwebÓ¦ÓÃÖеÄ×é¼þ£¿£¨ £©
A View
B Model
C ActionServlet
D Action
E ActionMapping
F Controller
²Î¿¼´ð°¸£ºABF
2. ÔÚStrutsÌåϵ½á¹¹ÖУ¬ÒÔÏÂÄĸöÓÉ´ú±íϵͳ״̬ºÍÉÌÒµÂß¼µÄActionÀ´¹¹½¨ ......