Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Axis2 java WebServices¿ª·¢¶þ

¿ª·¢»·¾³  eclipse3.2 £¨Ã»ÓÐÅäÖû·¾³ Çë²Î¿´ÉÏһƪÈÕÖ¾£©
н¨ÏîÄ¿£º
UserCover£¨Ãû³ÆËæ±ã£© ×ö¸ö¼òµ¥µÄ±¨µÀ²¢¼Ç¼µ÷ÓÃserverµÄusername
н¨°ü£ºcom.axis2.test
н¨½Ó¿Ú£º
package com.axis2.test;
public interface UserCover {
public void CoverName(String myname);
public String getUserList();
}

н¨°ü£ºcom.axis2.test.impl
±àдʵÏÖÀࣺ
package com.axis2.test.impl;
import java.util.ArrayList;
import java.util.List;
import com.axis2.test.UserCover;
public class UserCoverService implements UserCover {

public static List<String> userlist = new ArrayList<String>();
public void CoverName(String myname) {
if(myname != null)
userlist.add(myname);

}
public String getUserList() {
String usernames = "";
for(String username:userlist){
usernames += username+"\n";
}
return usernames;
}
}

½ÓÏÂÀ´ÊÇÓÿª·¢Ò»ÖнéÉܵÄeclipse²å¼þ Éú³É·þÎñÇø¶ËºÍ¿Í»§¶ËÎļþ
1.Ê×ÏÈÉú³É·þÎñÆ÷¶ËʹÓõÄaarÎļþ
ͼ½â£º
Ñ¡Ôñ´ËÏîÄ¿µÄclass·¾¶
Èç¹ûÓÐwsdl¿ÉÒÔÑ¡ÔñÖ¸¶¨µÄwsdl ²»Ñ¡Ôñwsdl ·þÎñÆ÷¶ËÔÚµ÷ÓõÄʱºòÒ²ÊÇ»á×Ô¶¯Éú³ÉµÄ £¨ºóÃæÉú³É¿Í»§¶ËµÄʱºò»áÉú³Éwsdl£©
 ²»ÐèÒªÆäËûµÄjar°ü ÕâÀïʲô¶¼²»ÓÃÑ¡ ¼ÌÐøÏÂÒ»²½
Ñ¡Ôñ×Ô¶¯Éú³Éserver.xmlÎļþ
 server nameËæ±ãÆð£¬
classÄÇôΪÌṩ¸ø¿Í»§¶ËµÄserverÀà ¼´¿ªÊ¼±àдµÄUserCoverÀࣨ´ø°üÃû£© ÌîдÍê³Éºóµã»÷load °´Å¥ ¼ÓÔØ´ËÀàÖеķ½·¨
 
 ÕâÀïµÄfilenameΪaarÎļþµÄÃû³Æ Ò²¿ÉÒÔËæ±ãÈ¡£¬³ÌÐòÖÐÒªÓõÄÊÇÉÏÒ»²½ÖеÄserver name¡£¼´ÅäÖÃÔÚserver.xmlÖеÄserver name¡£
Êä³öÎļþ¼ÐÑ¡Ôñ ²¿ÊðµÄaxis2µÄwebĿ¼µÄWEB-INF/servicesĿ¼Ï£¬Èç¹ûûÓÐʹÓÃweb ÈÝÆ÷ ¿ÉʹÓÃaxis½âѹºó×Ô´øµÄÈÝÆ÷ ½«´ËÎļþÊä³öµ½
%AXIS2_HOME%\repository\services
ÏÖÔÚ¿ÉÒÔÆô¶¯tomcat »òÊÇaxis2 
¼ì²âÊÇ·ñ³É¹¦
http://localhost:8080/axis2/services/UserCoverService?wsdl
Èç¹û³É¹¦½«³öÏÖwsdlÎļþµÄÄÚÈÝ ±ÊÕßÏÔʾÄÚÈÝΪ
<?xml version="1.0" encoding="UTF-8" ?>
- <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns


Ïà¹ØÎĵµ£º

MyEclipseÉèÖÃjavaÎļþ×¢ÊÍ

MyEclipseÉèÖÃJSPÒ³ÃæĬÈϱàÂ뷽ʽ£º
windows(´°¿Ú)-Preferences(Ê×Ñ¡Ïî)-MyEclipse-Files & Editors-JSP-ÓÒ²àencoding:ÉèÖÃΪISO10646/Unicode(UTF-8)
MyEclipseÔÚJavaÎļþÖÐÉèÖÃ×÷Õß¡¢ÈÕÆÚµÈ˵Ã÷£º
windows(´°¿Ú)-Preferences(Ê×Ñ¡Ïî)-Java-Code Style(´úÂëÑùʽ)-Code Templates(´úÂëÄ£°æ)-ÓÒ²àComments(×¢ÊÍ)- ......

2009Äêjava±ÊÊÔÌ⣨Ç×ÉíÃæÊÔ¹ýµÄ£©

Êý¾Ý¿â²¿·Ö:
1.¾ÙÀý˵Ã÷Dynamic SQLµÄÔ­Àí¼°Ó¦Óã¿
2.¾ÙÀý˵Ã÷Êý¾Ý¿âË÷ÒýµÄÓÅȱµã£¿
3.Èç¹ûÓÉÄãÀ´Éè¼ÆÊý¾ÝµÄrollback,ÄãµÄ˼·ºÍ·½°¸£¿
4.¼ÙÉèÓÐÒ»¸ötable£¬ÃûΪpages£¬ÓÐËĸö×Ö¶Î,id ,url,title,body¡£ÀïÃæ´¢Á˺ܶàÍøÒ³£¬ÍøÒ³µÄurlµØÖ·£¬titleºÍÍøÒ³ÄÚÈÝ£¬ÓÃÒ»¸ö
sql²éѯ½«urlÆ¥ÅäµÄÅÅÔÚ×îÇ°Ã棬titleÆ¥ÅäµÄÔÚÆä´Î£¬b ......

Java½Ó¿ÚµÄ×÷Óü°ÊµÀý

 ½üÈÕÔÚ±à³ÌÖÐÓõ½½Ó¿Ú֪ʶ,ÓÉÓڿα¾ÖжԽӿÚÃèÊö½ÏÉÙ,ËùÒÔÏë´ÓÍøÉϲéÕÒ×ÊÁÏ,µ«ÍøÉϵÄ×ÊÁÏ´ó¶àÒ²Ö»ÊÇÈß³¤µÄÃèÊö,ËùÒÔÔÚ´ËÌṩһ×Ô¼ºÐ´µÄʵÀý,¹©´ó¼Ò²Î¿¼:
Ô­ÌâÊÇÕâÑùµÄ£ºÔÚjavaÖУ¬¶¨ÒåÒ»¸ö½Ó¿Ú£¬ÉùÃ÷¼ÆË㳤·½ÐÎÃæ»ýºÍÖܳ¤µÄ³éÏó·½·¨£¬ÔÙÓÃÒ»¸öÀàȥʵÏÖÕâ¸ö½Ó¿Ú£¬ÔÙ±àдһ¸ö²âÊÔÀàȥʹÓÃÕâ¸ö½Ó¿Ú¡£
Ê×ÏÈ£¬½Ó¿Ú±ØÐëµ¥ ......

´ÓC++תµ½JavaÐè×¢ÒâµÄµØ·½

 1.JavaÔÚÐéÄâ»úÉÏÔËÐÐ
JavaÔ´´úÂë²¢²»ÊDZ»±àÒë³ÉΪÆÕͨµÄ»úÆ÷´úÂë¡£¶øÊDZ»·­Òë³ÉΪÐéÄâ»ú¿ÉÒÔÖ´ÐеĴúÂë¡£Ò»¸öJava½âÊÍÆ÷×îÖÕÖ´ÐÐÕâЩ´úÂë¡£ÕâÆäÖÐûÓÐÁ¬½ÓµÄ¹ý³Ì£»½âÊÍÔÚÐèÒªµÄʱºò¶¯Ì¬µÄ¼ÓÔØһЩÀࣻ
2.JavaÊÇÍêÈ«ÃæÏò¶ÔÏóµÄ
JavaÊÇÒ»ÖÖÍêÈ«ÃæÏò¶ÔÏóµÄÓïÑÔ¡£ÕâÒâζ×ÅÄã¶ÔÈκÎÒ»¸öJava¶ÔÏóËù×öµÄ¶¯×÷¶¼ÊÇͨ¹ýÒ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ