ѧϰģʽÖУ¬Çë´ó¼Ò¶àÖ¸Õý
˵Ã÷£º
Ò»¡¢ÊÂÀý˵Ã÷£º
1. Ä£Äâ²ÉÓÃBlogÐÎʽµÄͼƬվµã¡£
2. Ö÷ÒªÓû§ÎªÆÕͨä¯ÀÀÕߣ¨Browser£©£¬×¢²áÓû§£¨Bloger£©£¬ÏµÍ³¹ÜÀíÔ±£¨Admin£©¡£
3. ÍøÕ¾´æ´¢Êý¾ÝΪͼƬ£¨Pic£©£¬Í¼Æ¬·ÖÀࣨList£©£¬Í¼Æ¬ÆÀÂÛ£¨Comment£©£»
4. Ö÷ÒªÐÐΪÓÐ
4.1 ä¯ÀÀÕߣ¨Browser£©¶ÔͼƬ£¨Pic£©¼°·ÖÀࣨList£©µÄä¯ÀÀ£¨browse£©¡¢²éѯ£¨find£©¼°·¢±íÆÀÂÛ£¨comeout£©¡£
4.2 ×¢²áÓû§£¨Bloger£©¶ÔͼƬ£¨Pic£©¼°·ÖÀࣨList£©µÄä¯ÀÀ£¨browse£©¡¢²éѯ£¨find£©¡¢ÉÏ´«£¨upload£©¡¢ÏÂÔØ£¨download£©¡¢´´½¨£¨create£©¡¢É¾³ý£¨delete£©¡¢·¢²¼£¨issue£©µÈ¹ÜÀí£¨Control£©¹¦ÄÜ¡£¶Ô¸öÈËÐÅÏ¢£¨Personal£©µÄ×¢²á£¨enrol£©¡¢µÇ½£¨login£©±à¼£¨Edit£©¡¢¼ÓÃÜ£¨encrypt£©¡¢·¢²¼£¨issue£©µÈ¹ÜÀí£¨Control£©¹¦ÄÜ¡£
4.3 ¹ÜÀíÔ±£¨Admin£©¶ÔͼƬ£¨Pic£©¡¢·ÖÀࣨList£©¼°ÆÀÂÛ£¨Comment£©µÄÉóºË£¨audit£©¡¢±¸·Ý£¨backup£©¡¢·¢²¼£¨issue£©µÈ¹ÜÀí£¨Control£©¹¦ÄÜ¡£¶Ô×¢²áÓû§£¨Bloger£©µÄä¯ÀÀ£¨browse£©¡¢²éѯ£¨find£©¡¢´´½¨£¨create£©¡¢É¾³ý£¨delete£©¡¢ÉóºË£¨audit£©µÈ¹ÜÀí¹¦ÄÜ¡£
5. Ö÷Ҫģ¿éÓÐ
5.1 Àࣺä¯ÀÀÕߣ¨Browser£©¡¢×¢²áÓû§£¨Bloger£©¡¢ÏµÍ³¹ÜÀíÔ±£¨Admin£©¡¢Í¼Æ¬£¨Pic£©¡¢Í¼Æ¬·ÖÀࣨList£©¡¢Í¼Æ¬ÆÀÂÛ£¨Comment£©¡¢¸öÈËÐÅÏ¢£¨Personal£©¡£
5.2 ¹¦ÄÜ»ò½Ó¿Ú£º
a¡¢ ͼƬä¯ÀÀ£¨browsePic£©¡¢Í¼Æ¬²éѯ£¨findPic£©¡¢¡¢Í¼Æ¬ÉÏ´«£¨uploadPic£©¡¢Í¼Æ¬ÏÂÔØ£¨downloadPic£©¡¢Í¼Æ¬´´½¨£¨createPic£©¡¢Í¼Æ¬É¾³ý£¨delPic£©¡¢Í¼Æ¬·¢²¼£¨issuePic£©¡¢Í¼Æ¬ÉóºË£¨auditPic£©¡¢Í¼Æ¬±¸·Ý£¨backupPic£©¡¢Í¼Æ¬¹ÜÀí£¨controlPic£©¡£
b¡¢ ·ÖÀàä¯ÀÀ£¨browseList£©¡¢·ÖÀà²éѯ£¨findList£©¡¢·ÖÀà´´½¨£¨createList£©¡¢·ÖÀàɾ³ý£¨delList£©¡¢·ÖÀà·¢²¼£¨issueList£©¡¢·ÖÀàÉóºË£¨auditList£©¡¢·ÖÀà¹ÜÀí£¨ControlList£©¡£
c¡¢ ÆÀÂÛä¯ÀÀ£¨browseComment£©¡¢ÆÀÂÛ·¢±í£¨comeoutComment£©¡¢ÆÀÂÛɾ³ý£¨delComment£©¡¢ÆÀÂÛÉóºË£¨auditComment£©¡¢ÆÀÂÛ¹ÜÀí£¨ControlComment£©¡£
d¡¢ Óû§×¢²á£¨enrol£©¡¢Óû§µÇ½£¨login£©¡¢
e¡¢ ¸öÈËÐÅÏ¢ä¯ÀÀ£¨browsePersonal£©¡¢¸öÈËÐÅÏ¢²éѯ£¨findPersonal£©¡¢¸öÈËÐÅÏ¢´´½¨£¨createPersonal£©¡¢¸öÈËÐÅÏ¢±à¼£¨editPersonal£©¡¢¸öÈËÐÅϢɾ³ý£¨delPersonal£©¡¢¸öÈËÐÅÏ¢¼ÓÃÜ£¨encryptPersonal£©¡¢¸öÈËÐÅÏ¢·¢²¼£¨issuePersonal£©¡¢¸öÈËÐÅÏ¢ÉóºË£¨auditPersonal£©¡¢¸öÈËÐÅÏ¢¹ÜÀí£¨ControlPersonal£©¡£
6. ±¾ÊÂÀýΪѧϰJavaģʽ½øÐÐÊÔÑéËù¹¹£¬·ÇÕæʵÊÂÀý¡£
ģʽ£º
Ò»¡¢¼òµ¥¹¤³§
1. »ù±¾µÄ¼òµ¥¹¤³§£¨SimpleFactoryBisic£©£º
1.1 Éè¼Æ˼·£º
¼òµ¥¹¤³§Ä£Ê½£¨Simple Factory£©ÊÇÀàµÄ´´½¨Ä£Ê½£¬Óֽо²Ì¬¹¤³§·½·¨£¨Static Factory Method£©Ä£Ê½¡£¼òµ¥¹¤³§Ä£Ê½¾ÍÊÇÓÉÒ»¸ö¹¤³§Àà¸ù¾Ý´«ÈëµÄ²ÎÊý¾ö¶¨´´½¨ÄÄÒ»ÖֵIJúÆ·Àà¡£
ÔÚ±¾ÀýÖвÉÓõ¥Ò»µÄ¼òµ¥¹¤³§¹¹½¨ÏµÍ³£¬Æä½ÇÉ«¶¨Î»Îª£º
¹¤³§Àà½ÇÉ«£ºBlogerÒòBlogerΪϵͳÖÐÒµÎñÂß¼µÄÖ÷ÒªÖ´ÐÐÕߣ¬Ò²ÊǾßÌå²úÆ·Àà½ÇÉ«Ö±½Óµ÷ÓÃÕß¡£
³éÏó²úÆ·½ÇÉ«£ºResult£¬ResultΪһ½Ó¿Ú»ò³éÏóÀ࣬¸ºÔð¾ßÌå²úÆ·½ÇÉ«µÄ¶¨Ò壬¼°Óë¿Í»§¶ËµÄ½»»¥¡£
¾ßÌå²úÆ·½ÇÉ«£ºPic¡¢List¡¢Comment¡¢Personal£¬±»¹¤³§Àà´´½¨µÄ¶ÔÏó£¬Ò²ÊÇ¿Í»§¶Ëʵ¼Ê²Ù×÷¶ÔÏó¡£
¿Í»§¶Ë£ºBrowser¡¢Admin£¬µ÷Óù¤³§ÀàBloger²úÉúResultʵÀý£¬²¢µ÷ÓÃResult½øÐÐÏàÓ¦¹¤×÷¡£
1.2 UMLͼ£º
1.1 ˼¿¼£º
ÔÚ±¾ÀýÖвÉÓõ¥Ò»µÄ¼òµ¥¹¤³§Ä£Ê½Ð§¹û²»¼Ñ£¬Æ䱩¶µÄȱµãÓУº1¡¢¾ßÌå²úÆ·ÀàµÄ¹²ÐÔÉÙ£¬ÊôÐÔÓë·½·¨ÎÞ·¨Í³Ò»ÔÚͬһ¸ö½Ó¿ÚÖУ¬ÎÞ·¨Í»³ö¸öÐÔ£¬Ò²Ê¹Óû§È¨ÏÞ»®·ÖÀ§ÄÑ¡£Ê¹²úÆ·ÀàÔö¼Ó²»±ØÒªµÄ·½·¨¡£2¡¢Bloger½ÇÉ«¹¦ÄÜ´íλ¡£3¡¢¼òµ¥¹¤³§Ä£Ê½ÎÞÒÉÊǼòµ¥µÄ¡£
1. À©Õ¹µÄ¼òµ¥¹¤³§£¨SimpleFactoryUpgrade£©£º
2.1 Éè¼Æ˼·£º
ÔÚSimpleFactoryBasic»ù´¡ÉÏ°´Óû§È¨ÏÞ»®·ÖÄ£¿é£¬ÌåÏÖÓû§Ö®¼äµÄ¼Ì³Ð¹Øϵ£¬¸ù¾ÝÒÀÀµµ¹×ªÔÔò½«¾ßÌ幦ÄܳéÏóΪ½Ó¿Ú£¬Óɲ»Í¬Óû§µÄ¹¤³§Àà´´½¨£¬²»Í¬µÄÓû§Ö»Äܵ÷ÓÃÆä×ÔÉíµÄ¹¦ÄÜ£¬ ʹ³ÌÐòÌõÀýÇåÎú£¬¹¦ÄÜÃ÷È·¡£
2.2 UMLͼ£º
2.1 ˼¿¼£º
ÔÚ±¾ÀýÖÐÓÐЧµÄ½â¾öÁËÔÚBasicÉÏÓû§È¨ÏÞ»®·ÖÀ§Äѵġ£Í¬Ê±ÊÍ·ÅÁËBlogerÀ࣬ʹ³ÌÐò¸ü¼ÓÇåÎúÃ÷È·£¬Ò²Ê¹¾ßÌå²úÆ·ÀàµÄÊôÐÔÓë·½·¨³åÍ»µÄì¶ÜµÄµ½Ò»¶¨µÄ½â¾ö£¬¾ßÓÐÒ»¶¨µÄ¿ÉʵʩÐÔ¡£ÆäȱµãÖ÷ÒªÔÚ¾ßÌå²úÆ·Àà¼äÊôÐÔÓë·½·¨£¬²úÆ·Óë½Ó¿ÚÖ®¼ä³åÍ»ÒÀ¾É¡£
±¾ÎĵØÖ·£ºhttp://com.8s8s.com/it/it11445.htm