LittleRain

          小雨不打傘 打傘雨不小

          置頂隨筆

          windows安裝基于Apache的Subversion服務(wù)器

          1.先下載并安裝Apche/Subversion/TortoiseSVN
          apache:http://httpd.apache.org/download.cgi
          Subversion:http://subversion.tigris.org/
          TortoiseSVN:http://tortoisesvn.tigris.org/
          我用的是apche2.0.55/svn-1.3.2/TortoiseSVN-1.3.5.6804

          注意:目前的subversion1.3.2只能跟Apache2.0.x配合,不能用于Apache2.2.x
          建議:先裝apache再安裝svn,這樣可以讓svn自動搜索到以安裝的apache,省去一些設(shè)置。否則自己參考網(wǎng)上不是這種安裝順序的解決辦法。

          2.path中添加svn的bin目錄,測試apache和svn是否安裝成功。

          3.(下面均以我自己的目錄為例)
          建立目錄:G:\svnhome\svn1(svnhome用來保存每個工程的版本庫,svn1為其中一個project)
          并建立初始化配置:G:\svnhome\svn1文件夾右鍵-->TortiseSVN-->Create Repository here

          創(chuàng)建客戶端工作目錄G:\svnuser??????????????????????????????????????????
          ????????????????????????????????????????????????|
          ????????????????????????????????????????????? svn1???????????????????????????????????????????????
          ??????????????????????????????????????????????? |----user1
          ??????????????????????????????????????????????? |----user2
          ??????????????????????????????????????????????? |----user3
          ??????????????????????????????????????????????svn1_work

          用來初始化訪問初始結(jié)構(gòu)的。

          4.開啟svn服務(wù)(對G:\svnhome目錄下的所有project開啟服務(wù))
          命令行下:svnserve -d -r g:\svnhome

          5.導(dǎo)入初始化版本庫配置(即G:\svnhome\svn1目錄)配置,
          ??
          G:\svnuser\svn1右鍵->tortoise->import
          ? url of repository:svn://localhost/svn1(svn://localhost表示本地對應(yīng)G:\svnhome目錄,svn1表示項目名,)
          ? import message:隨便寫

          這時會出現(xiàn)錯誤提示(見下圖):
          o_svnPic1.bmp

          錯誤原因:是因為沒有對svnhome\svn1目錄下的配置文件進行過設(shè)置
          具體設(shè)置:a)g:\svnhome\svn1\conf下的svnserve.conf文件中:[general]、anon-access = read、auth-access = write
          ????????????????????????? password-db = passwd前面的#去掉,其他不變。
          ?????????????????????b)a)中相同目錄下的passwd文件中:harry = harryssecret和 sally = sallyssecret前面的#去掉
          ???????????????????????? 并且可以執(zhí)行添加自己需要的用戶名和密碼。
          接下來就可以再次進行步驟5了,正確提示:Compelet at version1

          6. 檢出原始文件信息:G:\svnuser\svn1_work目錄右鍵->SVN Checkout
          ?????????????URL of repository:svn://localhost/SVN1
          ?????????????Checkout directory:G:\svnuser\svn1_work
          ??????ok確定,正確提示:Complete at version1
          ??????這個時候去G:\svnuser\svn1_work目錄下觀察,發(fā)現(xiàn)已經(jīng)將
          G:\svnuser\svn1下的文件結(jié)構(gòu)全部導(dǎo)入。
          ??
          7 .打開%APACHE_HOME%\conf\httpd.conf文件,在末尾添加如下語句:(關(guān)于其中)
          ???
          <Location /svn>
          ??????DAV svn
          ??????SVNParentPath G:\svnhome
          ??? </Location>

          <Location /svn>:意味著可以通過像這樣的URL(http://MyServer/svn)來訪問Subversion版本庫
          DAV svn:告訴Apache哪個模塊負(fù)責(zé)服務(wù)像那樣的URL--在這里就是Subversion模塊SVNParentPath G:\svnhome:告訴Subversion在目錄G:\SVN下尋找版本庫

          8 .重啟apache,輸入url:http://localhost/svn/svn1/,正確顯示:
          r_svnPic2.bmp
          9,支持svn的基本功能搭建完畢。再配合花生殼,就可以搭建遠(yuǎn)程的svn系統(tǒng)了。


          Eclipse中安裝subclipse插件使用subvsersion

          1.到http://subclipse.tigris.org/站點找Installation教程,一般是為了找新的用來在eclipse中更新的url(有時候會變化的)


          2.用eclipse自帶的plugin的update功能安裝即可,注意版本問題,好像目前為止只支持到3.x的
          posted @ 2006-09-20 07:52 小雨不打傘 閱讀(1201) | 評論 (1)編輯 收藏

          2007年9月30日

                  第一步,在作為服務(wù)器的微機上安裝兩塊網(wǎng)卡,聯(lián)接到ISP的網(wǎng)卡取名"外網(wǎng)卡",聯(lián)接到局域網(wǎng)的網(wǎng)卡取名"內(nèi)網(wǎng)卡";

            第二步,在"外網(wǎng)卡"上配置IP地址和子網(wǎng)掩碼(由ISP提供),如IP是10.32.101.11,子網(wǎng)掩碼是255.255.255.0(表示局域網(wǎng)規(guī)模小于256臺);其它都按ISP的要求設(shè)置。注意:下面的操作是關(guān)鍵:

            1、在Windows 2000操作系統(tǒng)中,雙擊"外網(wǎng)卡"連接屬性,選"共享"標(biāo)簽,選中"啟用此連接的Internet連接共享"項。
            2、在Windows 98操作系統(tǒng)中,點設(shè)置,控制面板,雙擊Internet選項,點"連接"標(biāo)簽,單擊"局域網(wǎng)設(shè)置"下的"共享"選項,選中"啟用此連接的Internet連接共享"項。
            第三步,"內(nèi)網(wǎng)卡"IP地址設(shè)為:192.168.0.1。

            第四步,局域網(wǎng)中其它客戶機網(wǎng)卡靜態(tài)設(shè)置為192.168.0.2到192.168.0.253之間的任何IP地址,網(wǎng)關(guān)、DNS均設(shè)為192.168.0.1(即服務(wù)器"內(nèi)網(wǎng)卡"的IP地址),照此設(shè)置,即可共享一條線路連上Internet,很簡單吧。
          posted @ 2007-09-30 21:15 小雨不打傘 閱讀(364) | 評論 (0)編輯 收藏

          2007年4月21日

          1):http://blog.csdn.net/jrq/archive/2007/03/17/1531812.aspx
          posted @ 2007-04-21 06:56 小雨不打傘 閱讀(932) | 評論 (1)編輯 收藏

          2007年4月18日

          1.使用Servlet2.4/jsp2.0

          1. 確定Web Container支持Serverlet2.4, 復(fù)制支持jstl 1.1版本的jstl.jar,standard.jar(可查閱meta-inf)到web-inf/lib。

          2. 在Web.xml,Root節(jié)點改為

          <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee 
           http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd ">

          3.在jsp中,對core,ftm taglib的引入改為  

          <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"% >
          <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"% >

          2.直接在html里面使用EL,而不是<c:out value="">

            充分使用JSP2.0的EL,直接在html中寫${book} 而不是<c:out value="${book}">將獲得簡潔無比,可比美velocity,freemarker的界面。

          3.新增的Function標(biāo)簽

              Function標(biāo)簽里最有用的一項是取得List,Map的size了。另外有一些StringUtils和Collection的函數(shù)。

              JSTL里面不給調(diào)用對象除getXXX()外的任何方法真是件很讓讓人郁悶的事情!!

          <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
          ${fn:length(myList)}

          4.其他的EL知識點

          4.1 EL的運算符

                除了最基本的算術(shù)運算符,邏輯運算符,比較運算符外,還有一個empty運算符,用來判斷變量是否為null 或list, map的size 是否為零。

          <c:if test="${not empty myList}">
          

          EL的運算符都有文字和符號兩種版本,如|| 和 or, >= 和 ge,適用于不能使用文字或符號的時候。

          4.2 []與. 兩種訪問屬性或元素的方式

                 ${book.name}與${book["name"]}等價。

                 ${book["name"]}主要用于"name"串為變量,或者字符串中含有"."字符的情況

                 如 ${myMap[order.status]} 是訪問Map元素的一種很重要的方式。

          4.3 list與map

              orderList[0]  返回第一個元素

               用key和value遍歷map

          <c:forEach var="entry" items="${myMap}">
             <option value="${entry.key}">${entry.value}</option> </c:forEach>

          4.4.訪問靜態(tài)變量

                EL本身不支持靜態(tài)變量訪問,變通的方法是寫一個tag,將某個類的靜態(tài)變量反射到一個map中, 如http://www.javaranch.com/journal/200601/Journal200601.jsp#a3

               不過使用Map將失去靜態(tài)變量編譯期安全的意義,因此還是建議在這種情況下,使用普通JSP,見showOrder.jsp

          posted @ 2007-04-18 17:43 小雨不打傘 閱讀(1892) | 評論 (0)編輯 收藏

          2007年4月2日

          chapter2:
          package com.apress.prospring.ch2;

          import java.io.FileInputStream;
          import java.util.Properties;

          import org.springframework.beans.factory.BeanFactory;
          import org.springframework.beans.factory.support.DefaultListableBeanFactory;
          import org.springframework.beans.factory.support.PropertiesBeanDefinitionReader;

          public class HelloWorldWithDI {

              public static void main(String[] args) throws Exception {
                  //get BeanFactory
                  BeanFactory factory=getBeanFactory();
                 
                  MessageRenderer mr=(MessageRenderer)factory.getBean("renderer");
                  mr.render();
              }
             
              private static BeanFactory getBeanFactory() throws Exception {
                 
                  // get the bean factory
                  DefaultListableBeanFactory factory = new DefaultListableBeanFactory();

                  // create a definition reader
                  PropertiesBeanDefinitionReader rdr = new PropertiesBeanDefinitionReader(
                          factory);

                  // load the configuration options
                  Properties props = new Properties();
                  props.load(new FileInputStream("./ch2/src/conf/beans.properties"));

                  rdr.registerBeanDefinitions(props);

                  return factory;
              }

          }

          beans.properties:
          renderer.class=com.apress.prospring.ch2.StandardOutMessageRenderer
          renderer.messageProvider(ref)=provider

          provider.class=com.apress.prospring.ch2.HelloWorldMessageProvider

          DefaultListableBeanFactory負(fù)責(zé)從properties文件讀取BeanFactory的配置信息,然后返回已配置的實例。
          這個配置文件已經(jīng)定義了DI關(guān)系,所以在main方法中無需設(shè)置MessageRenderer 和MessageProvider的依賴關(guān)系。
          posted @ 2007-04-02 13:16 小雨不打傘 閱讀(381) | 評論 (0)編輯 收藏
          1:http://tiwen.javaeye.com/blog/66624
          2:http://www.aygfsteel.com/czcode/archive/2006/12/18/88448.html
          3:http://hbcui1984.javaeye.com/blog/post/230199
          posted @ 2007-04-02 10:05 小雨不打傘 閱讀(476) | 評論 (0)編輯 收藏

          2007年3月20日

          http://cs.cuc.edu.cn/linweiguo/archives/000023.html#2
          這里是原文地址
          posted @ 2007-03-20 18:27 小雨不打傘 閱讀(451) | 評論 (0)編輯 收藏

          2007年3月17日

          (一)關(guān)聯(lián)(Association)
          一對一、一對多、多對多
          class A
          {
          ???private B b;
          }

          class B
          {
          ???private A a;
          }

          (二)依賴(Dependency)
          A以來B:類A訪問B的屬性或方法,或者類A負(fù)責(zé)實例化類B,但是類B不是類A的屬性。

          (三)聚集(Aggregation)
          指的是整體與部分的關(guān)系:如人和手的關(guān)系,部分類不能脫離整體類單獨存在。
          posted @ 2007-03-17 11:55 小雨不打傘 閱讀(579) | 評論 (0)編輯 收藏

          2007年3月14日

          1)"Caused by: java.sql.SQLException: Syntax error or access violation message from server: "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'group, testoption.content as content, testoption.score as score, testoption.Ques' at line 1"
          ----:在你的pojo中定義了數(shù)據(jù)庫的key word,例如:group等等.

          2)net.sf.hibernate.QueryException: could not resolve property type: username [select user.password from cn.org.sppc.ipmanager.User user where user.username=?]
          ----:username在Form類中、在Hibernate的xml文件中和相對應(yīng)的PO對象中名稱都要保持一致(包括大小寫)。包括struts-config.xml中的。

          posted @ 2007-03-14 09:10 小雨不打傘 閱讀(536) | 評論 (0)編輯 收藏

          2007年3月12日

          ???凸-_-'',前面馬上就快寫完了,機器居然突然重啟,我。。。
          ???ofbiz的homepage:http://ofbiz.apache.org?,那里沒有找到下載的鏈接,在https://ofbiz.dev.java.net找到了。具體下載地址
          ???(1)我這里下的是:OFBiz-2.1.1-Apps,下載完畢后解壓,得到一個ofbiz的目錄。
          ???(2)安裝jdk1.3+(不是jre)版本,配置好JAVA_HOME并將其添加到PATH下,cmd下java -version看到版本信息就ok了。進入下一步。
          ???(3)cmd下進入(1)中解壓得到的ofbiz目錄,通過命令“java -jar ofbiz.jar”進行ofbiz的初始化,初始化完畢后大家可以通過幾個url來驗證安裝的情況。testUrl-1testUrl-2testUrl-3
          ???
          posted @ 2007-03-12 11:53 小雨不打傘 閱讀(2082) | 評論 (0)編輯 收藏

          2007年2月17日

          2.1.?Eclipse 3.1.x

          Follow these steps :

          • Start Eclipse.
          • Select Help > Software Updates > Find and Install...
          • Select Search for new features to install, and press Next >
          • Select New Remote Site... from the right menu. In the dialog fill the name with JBoss Eclipse IDE and the URL with http://download.jboss.org/jbosside/updates/stable
          • Make sure JBoss Eclipse IDE has a check next to it, and press Finish.
          • Expand the JBoss Eclipse IDE tree, and check the release named JBossIDE 1.5. Click Next >, and Eclipse will ask you if you agree to the licensing terms of JBoss Eclipse IDE. If you agree, select I accept the terms in the license agreement, and press Next >
          • Eclipse will show you a list of features it is going to install. See Figure 1. Press Finish to start installation.
          • After all the features have been downloaded, Eclipse will prompt if you want to install each feature. The quickest way to install everything is to press the Install All button.
          • At the end of the installation, you will be prompted to restart Eclipse. Click Yes.

          Tip

          If you are behind a proxy you have to go to Window > Preferences > Install/Update, select Enable HTTP Proxy Connection and insert values for Host Address and Port.

          Tip

          You can be notified when new updates are available. You can also configure Eclipse to fetch new updates and make them ready to install. All this configuration can be done through the Help > Software Updates > Configuration Manager menu.

          Have a look at the Eclipse documentation to get more information about the Configuration Manager.

          Features in JBoss Eclipse IDE 1.5.

          Figure?2.1.?Features in JBoss Eclipse IDE 1.5.

          posted @ 2007-02-17 00:40 小雨不打傘 閱讀(11347) | 評論 (0)編輯 收藏
          僅列出標(biāo)題  下一頁

          公告

          點擊這里給我發(fā)消息 QQ:232720563


            MSN:new_haihua@hotmail.com

          導(dǎo)航

          統(tǒng)計

          常用鏈接

          留言簿(2)

          隨筆分類(51)

          最新隨筆

          積分與排名

          最新評論

          閱讀排行榜

          主站蜘蛛池模板: 藁城市| 甘肃省| 大宁县| 钟祥市| 昭苏县| 武定县| 靖边县| 香港 | 仙游县| 通辽市| 台江县| 伊通| 洞头县| 吴川市| 江安县| 天门市| 旌德县| 安溪县| 蛟河市| 关岭| 清新县| 南召县| 西乌珠穆沁旗| 上蔡县| 宝应县| 扎鲁特旗| 甘泉县| 含山县| 西宁市| 利津县| 赤水市| 镶黄旗| 梁山县| 贞丰县| 梨树县| 新乡县| 屏南县| 大渡口区| 德庆县| 汉阴县| 文山县|