锘??xml version="1.0" encoding="utf-8" standalone="yes"?>午夜在线亚洲男人午在线,a级亚洲片精品久久久久久久,亚洲精品亚洲人成在线观看麻豆http://m.tkk7.com/tufanshu/category/9675.html娌℃湁椋庨洦韜茬殑榪囷紝 娌℃湁鍧庡澐涓嶅繀璧扳︹? zh-cnWed, 28 Feb 2007 23:36:51 GMTWed, 28 Feb 2007 23:36:51 GMT60appfuse鐨勫畨瑁呴厤緗瘒http://m.tkk7.com/tufanshu/archive/2006/04/07/39904.html闆湴瀛ら縛闆湴瀛ら縛Fri, 07 Apr 2006 11:55:00 GMThttp://m.tkk7.com/tufanshu/archive/2006/04/07/39904.htmlhttp://m.tkk7.com/tufanshu/comments/39904.htmlhttp://m.tkk7.com/tufanshu/archive/2006/04/07/39904.html#Feedback0http://m.tkk7.com/tufanshu/comments/commentRss/39904.htmlhttp://m.tkk7.com/tufanshu/services/trackbacks/39904.html 鍦ㄧ綉涓婃壘浜嗗緢涔咃紝鐪嬩簡寰堝鐨勬枃妗o紝緇堜簬灝哸ppfuse鎴愬姛鐨勭紪璇戯紝鍙戝竷浜嗭細榪欐牱鎰熻阿騫垮ぇ緗戝弸鐨勬棤縐佸鐚簡錛屽ソ浜嗭紝闂茶瘽灝戣浜嗭紝鍏蜂綋鐨勬搷浣滃涓嬶細
Appfuse1.9,JDK1.5,ANT1.6.2,Mysql5.0,Tomcat5.5

涓.鐜璁劇疆錛?br />浠ヤ笅鐜鍙橀噺鍧囨寜鏈満鐨勫畨瑁呰礬寰勮緗嵆鍙?br />ANT_HOME,
JAVA_HOME,
CATALINA_HOME,
MYSQL_HOME
Path涓姞鍏?br />%JAVA_HOME%bin;%ANT_HOME%bin;%CATALINA_HOME%bin;%MYSQL_HOME%bin;
浜?鍦╡clipse涓嬌鐢╝nt緙栬瘧錛屽彂甯冿紝嫻嬭瘯appfuse
1.Create New Java Project in Eclipse
Open Eclipse (either with an existing or a new workspace) and to go File 鈫?New 鈫?Project. Then select "Java Project" and hit the Next button. In the Project Name field, enter the name of your project (i.e. appfuse) and the directory that your project lives (i.e. c:\source\appfuse) in the box below. If you're prompted to switch the Java Perspective, choose Yes.
If you try to build the project at this point, you'll likely get numerous errors. Most of them involve the fact that the UserForm class can not be found. This is because all of the ActionForms in AppFuse (if you're using the Struts version) are generated from POJOs with XDoclet.

All of the tasks for XDoclet are configured in the Ant build.xml file so the easiest thing to do is to run "ant gen-forms" to generate the ActionForms. If you have Ant 1.6.2+ installed and in your path, you can do this from the command line. The next step shows you how configure Eclipse to run your AppFuse build.xml.

2.Configuring Ant in Eclipse

The easiest way to configure Eclipse for AppFuse is to install Ant on your hard drive (i.e. c:\Tools\apache-ant-1.6.2) and then point Eclipse's ANT_HOME to this directory. To do this, go to Window 鈫?Preferences 鈫?Ant 鈫?Runtime. Then click the "Ant Home" button and select the installation folder on your hard drive.

If you'd rather use Eclipse's built-in Ant, you'll need to add junit.jar to its classpath. To do this, go to Window 鈫?Preferences 鈫?Ant 鈫?Runtime. Then click the "Add JARs" button and select junit.jar from appfuse/lib/junit3.8.1/lib/junit.jar. Click OK until you arrive back at the workbench view.

Next, add the catalina-ant.jar (from $CATALINA_HOME/server/lib) to the ant classpath. Then in the property tab, add tomcatTasks.properties (in lib/ant-contrib) file as a global properties file.

Below is a screenshot of what your Ant Runtime classpath should look like after the above modifications:
ant-runtime.png

3.Add build.xml to Ant View
Now we need to add the build.xml to Eclipse's Ant View. To do this, go to Window 鈫?Show View 鈫?Ant. Then click on the first icon in this view (screenshot below) to add AppFuse's build file.
ant-view.png

4.Run Ant
After adding the build.xml, you should be able to expand it in the Ant View and execute any of the targets. I usually do "test-all" to verify all the tests pass in my initial project. For a list of targets I use most often, see AppFuse Ant Targets.
Now if you run the "compile" target and then refresh the project (right-click on project 鈫?Refresh) you shouldn't see any errors in the "Problems" pane. You should now be able to compile and create classes as you normally would. Sometimes when my imports aren't resolving correctly in Eclipse, I do have to run Project 鈫?Clean in Eclipse.

NOTE: If you're using the internal version of Ant, you may get an error message like the one below:
BUILD FAILED: C:\source\appfuse\build.xml:802: The following error occurred while executing this line:
C:\source\appfuse\build.xml:780: The following error occurred while executing this line:
java.lang.NoClassDefFoundError: org/apache/xml/serialize/OutputFormat
This is because there are tasks that require Xerces to be in your Ant classpath [reference]. I added xercesImpl.jar and xml-apis.jar (from my self-installed version of Ant) to Eclipse's Ant classpath to solve this.
5.Run JUnit Tests in Eclipse
It's also possible to run your JUnit tests in Eclipse. But before running them, you need to run the "war" target. After this target completes, refresh your project.
After you have successfully done so, in Eclipse open a test you'd like to run (i.e. UserDaoTest) and go to Run 鈫?Debug As 鈫?JUnit Test. Note that you may have to run the "db-load" target before you run your tests every so often. I did have the following method in the Base*TestCase class for each layer, but this caused DBUnit to reload the database before every test in a Test class. Removing it reduces the execution time of "test-all" by more than 30 seconds.

聽聽聽 protected void setUp() throws Exception {
聽聽聽聽聽聽聽 DataSource ds = (DataSource) ctx.getBean("dataSource");
聽聽聽聽聽聽聽 IDatabaseConnection conn = new DatabaseConnection(ds.getConnection());
聽聽聽聽聽聽聽 IDataSet dataSet =
聽聽聽聽聽聽聽聽聽聽聽 new XmlDataSet(new FileInputStream("metadata/sql/sample-data.xml"));
聽聽聽聽聽聽聽 // clear table and insert only sample data
聽聽聽聽聽聽聽 DatabaseOperation.CLEAN_INSERT.execute(conn, dataSet);
聽聽聽聽聽聽聽 conn.close();
聽聽聽 }聽


If the instructions above don't work for running JUnit tests in Eclipse, I suggest just using the command line - i.e. ant test-dao -Dtestcase=UserDAO. Running tests from the command line always works. ;-)

濂戒簡 錛屽湪eclipse涓熀鏈寜浠ヤ笂鎿嶄綔灝卞彲浠ユ垚鍔熶簡錛岀瓑鏈夋椂闂達紝鎴戞潵緲昏瘧涓涓嬶紝铏界劧鎴戠殑e鏂囨瘮杈冪儌錛屼絾鏄繕鏄箰浜庤澶у鏍℃鐨?br />錛氾級鍘熸枃鐨勫湴鍧錛?a >http://raibledesigns.com/wiki/Wiki.jsp?page=AppFuseEclipse
闂鎻忚堪
1.鍒氬紑濮嬬殑鏃跺欙紝鎴戜滑鐨刴ysql鐨勭敤鎴峰悕鍜屽瘑鐮佸彲鑳藉拰appfuse鐨勯粯璁ょ殑鐢ㄦ埛鍜屽瘑鐮佷細涓嶄竴鏍風殑錛岃繖涓彲浠ュ埌properties.xml鏂囦歡涓慨鏀逛負鎴戜滑瀹夎mysql鏄緗殑鐢ㄦ埛鍚嶅拰瀵嗙爜錛屾垜鐨勪慨鏀瑰涓嬶細
聽<!-- Defaults for database.properties -->
聽聽聽 <property name="database.jar" location="${mysql.jar}"/>
聽聽聽 <property name="database.type" value="mysql"/>
聽聽聽 <property name="database.name" value="appfuse"/>
聽聽聽 <property name="database.host" value="localhost"/>
聽聽聽 <property name="database.username" value="root"/>
聽聽聽 <property name="database.password" value="780121"/>
聽聽聽
聽聽聽 <!-- database URL for creating other dbs - used in db-create target -->
聽聽聽 <property name="database.admin.url" value="jdbc:${database.type}://${database.host}/mysql"/>
聽聽聽 <property name="database.admin.username" value="root"/>
聽聽聽 <property name="database.admin.password" value="780121"/>
聽聽聽 <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLInnoDBDialect"/>
聽聽聽 <property name="database.driver_class" value="com.mysql.jdbc.Driver"/>
聽聽聽 <property name="database.url"
聽聽聽聽聽聽聽 value="jdbc:${database.type}://${database.host}/${database.name}?useUnicode=true&amp;amp;characterEncoding=utf-8"/>
聽聽聽 <property name="database.show_sql" value="true"/>

鎴戞槸淇敼浜唕oot鐢ㄦ埛鐨勫瘑鐮侊紝褰撶劧浣犱篃鍙互寤虹珛test鐢ㄦ埛騫剁粰鍒濆瀵嗙爜錛氾級
2.榪炴帴鏁版嵁搴撶殑闂瑙e喅鍚庯紝鍙﹀涓涓棶棰樻湁鍑烘潵浜嗭紝寤虹珛user_role琛ㄧ殑鏃跺欏嚭闂浜嗭細org.dbunit.dataset.NoSuchTableException: user_role
榪欎釜闂鐨勮В鍐蟲柟寮忓涓嬶細
setup-tomcat deploy
ant setup -Ddatabase.username=foo -Ddatabase.password=bar
榪欎釜涓昏鏄厛鎵ц浠ヤ笅build.xml涓殑setup-tomcate deploy鎸囦護灝卞彲浠ヤ簡錛氾級
鍘熻澆鍦板潃錛?a >http://b0r0j0.blogbus.com/logs/2005/12/1725103.html



闆湴瀛ら縛 2006-04-07 19:55 鍙戣〃璇勮
]]>
主站蜘蛛池模板: 亚洲国产无线乱码在线观看| 两个人的视频www免费| 3d成人免费动漫在线观看| 国精无码欧精品亚洲一区| 又粗又长又爽又长黄免费视频 | 国内精品99亚洲免费高清| 亚洲国产精品国产自在在线| 午夜成人无码福利免费视频| 亚洲欧洲中文日韩av乱码| 精品一区二区三区高清免费观看| 亚洲伊人成无码综合网| 国产无遮挡色视频免费观看性色| 亚洲欧洲日本在线| 国偷自产一区二区免费视频| 亚洲av无码不卡一区二区三区| 日韩精品在线免费观看| 亚洲色图.com| 永久免费看bbb| 青青草国产免费国产是公开| 在线亚洲人成电影网站色www| 免费国产叼嘿视频大全网站 | 国产亚洲精品激情都市| a级毛片在线免费| 亚洲综合精品香蕉久久网97| 2020久久精品国产免费| 亚洲精品国产电影| a级毛片毛片免费观看永久| 精品亚洲成AV人在线观看| 无码乱肉视频免费大全合集| 日日噜噜噜噜夜夜爽亚洲精品| 在线播放免费人成毛片乱码| 亚洲最大在线观看| 又粗又硬又黄又爽的免费视频| 韩国免费A级毛片久久| 亚洲精品乱码久久久久久下载| 日韩成人免费视频播放| 野花香高清在线观看视频播放免费| 亚洲a级在线观看| 国产日产亚洲系列| 日韩精品无码区免费专区 | 亚洲国产精品国自产电影|