posts - 11,  comments - 4,  trackbacks - 0
              xmarks是firefox的一個(gè)插件,它的原名叫做foxmakrs。
              安裝xmakrs后,只需要在它的網(wǎng)站注冊(cè)一個(gè)賬號(hào),你收藏的網(wǎng)站就會(huì)定期備份到你的賬號(hào)中。這樣就可以方便的備份你的收藏網(wǎng)址了。
              在你收藏某個(gè)網(wǎng)站的時(shí)候,它會(huì)根據(jù)別人收藏該網(wǎng)站時(shí)使用的標(biāo)簽,給你推薦一個(gè)使用人數(shù)最多的標(biāo)簽。
              由此,它給出了我認(rèn)為最好的一個(gè)功能:在你使用google進(jìn)行搜索的時(shí)候,它會(huì)自動(dòng)在google的每一個(gè)搜索結(jié)果后面,加上一個(gè)該搜索結(jié)果在相關(guān)領(lǐng)域內(nèi)收藏次數(shù)的名次。
              以我的搜索:UML為例,它就會(huì)在每個(gè)google的搜索結(jié)果后面給出其在xmarks中被以UML標(biāo)簽收藏的次數(shù)的排名。由此我就能很容易的發(fā)現(xiàn),argouml是被人以UML標(biāo)簽收藏次數(shù)最多的網(wǎng)站,所以我想argouml應(yīng)該就是我想找的最火的開源UML建模工具
          posted @ 2010-06-09 10:33 新蜂 閱讀(175) | 評(píng)論 (0)編輯 收藏

          Tab and window shortcuts

          Ctrl+N Opens a new window.
          Ctrl+T Opens a new tab.
          Ctrl+Shift+N Opens a new window in incognito mode.
          Ctrl+B Toggles the bookmarks bar on and off.
          Press Ctrl+O, then select file. Opens a file from your computer in Google Chrome.
          Press Ctrl and click a link. Or click a link with your middle mouse button (or mousewheel). Opens the link in a new tab in the background .
          Press Ctrl+Shift and click a link. Or pressShift and click a link with your middle mouse button (or mousewheel). Opens the link in a new tab and switches to the newly opened tab.
          Press Shift and click a link. Opens the link in a new window.
          Ctrl+Shift+T Reopens the last tab you've closed. Google Chrome remembers the last 10 tabs you've closed.
          Drag a link to a tab. Opens the link in the tab.
          Drag a link to a blank area on the tab strip. Opens the link in a new tab.
          Drag a tab out of the tab strip. Opens the tab in a new window.
          Drag a tab out of the tab strip and into an existing window. Opens the tab in the existing window.
          Press Esc while dragging a tab. Returns the tab to its original position.
          Ctrl+1 through Ctrl+8 Switches to the tab at the specified position number on the tab strip.
          Ctrl+9 Switches to the last tab.
          Ctrl+Tab orCtrl+PgDown Switches to the next tab.
          Ctrl+Shift+Tab orCtrl+PgUp Switches to the previous tab.
          Ctrl+Shift+Q Closes Google Chrome.
          Ctrl+W or Ctrl+F4 Closes the current tab or pop-up.
          Click a tab with your middle mouse button (or mousewheel). Closes the tab you clicked.
          Right-click, or click and hold either the Back or Forward arrow in the browser toolbar. Displays your browsing history in the tab.
          Press Backspace Goes to the previous page in your browsing history for the tab.
          PressShift+Backspace Goes to the next page in your browsing history for the tab.
          Click either the Back arrow, Forward arrow, or Go button in the toolbar with your middle mouse button (or mousewheel). Opens the button destination in a new tab in the background.
          Double-click the blank area on the tab strip. Maximizes or minimizes the window.

          Address bar shortcuts

          Use the following shortcuts in the address bar:

          Type a search term, then press Enter. Performs a search using your default search engine.
          Type a search engine keyword, press Space, type a search term, and press Enter. Performs a search using the search engine associated with the keyword.
          Begin typing a search engine URL, pressTab when prompted, type a search term, and press Enter. Performs a search using the search engine associated with the URL.
          Ctrl+L Highlights the URL.
          Ctrl+E Places a '?' in the address bar. Type a search term after the question mark to perform a search using your default search engine.
          Press Ctrl+Shift and the left arrow together. Moves your cursor to the preceding key term in the address bar
          Press Ctrl+Shift and the right arrow together. Moves your cursor to the next key term in the address bar
          Ctrl+Backspace Deletes the key term that precedes your cursor in the address bar
          Select an entry in the address bar drop-down menu with your keyboard arrows, then press Shift+Delete. Deletes the entry from your browsing history, if possible.
          Click an entry in the address bar drop-down menu with your middle mouse button (or mousewheel). Opens the entry in a new tab in the background.
          Press Page Up orPage Down when the address bar drop-down menu is visible. Selects the first or last entry in the drop-down menu.

          Webpage shortcuts

          Ctrl+P Prints your current page.
          Ctrl+S Saves your current page.
          Ctrl+R Reloads your current page.
          Esc Stops the loading of your current page.
          Ctrl+F Opens the find bar.
          Ctrl+G or Enter Finds the next match for your input in the find bar.
          Ctrl+Shift+G orShift+Enter Finds the previous match for your input in the find bar.
          Press Alt and click a link. Downloads the target of the link.
          Drag a link to bookmarks bar Bookmarks the link.
          Ctrl+D Bookmarks your current webpage.
          Space bar Scrolls down the web page.
          Home Goes to the top of the page.
          End Goes to the bottom of the page.

          Text shortcuts

          Ctrl+C Copies highlighted content to the clipboard.
          Ctrl+V or Shift+Insert Pastes content from the clipboard.
          Ctrl+Shift+V Paste content from the clipboard without formatting.
          Ctrl+X or Shift+Delete Deletes the highlighted content and copies it to the clipboard.
          posted @ 2010-05-10 16:05 新蜂 閱讀(178) | 評(píng)論 (0)編輯 收藏
          視圖的字體是用的系統(tǒng)字體。

          桌面屬性-->外觀-->高級(jí): 下拉列表里選“消息框”,把字體改大些就行了。

          不 過這個(gè)設(shè)置會(huì)改變所有的窗口的字體
          posted @ 2010-04-11 11:23 新蜂 閱讀(169) | 評(píng)論 (0)編輯 收藏
          extension points即接口,是插件暴露給其他插件的接口。

          每一個(gè)插件都是在現(xiàn)有擴(kuò)展點(diǎn)上開發(fā),并且留有自己的擴(kuò)展點(diǎn)。

          除了小型的運(yùn)行時(shí)內(nèi)核之外,eclipse中的所有東西都是插件



          org.eclipse.ui.editors 編輯器窗口

          org.eclipse.ui.views 視圖窗口





          posted @ 2010-04-11 10:33 新蜂 閱讀(153) | 評(píng)論 (0)編輯 收藏
           Java   程序是由若干個(gè)   .class   文件組成的。這些   .class   文件必須根據(jù)它們所屬的包不同而分級(jí)分目錄存放;運(yùn)行前需要把所有用到的包的根目錄指定給   CLASSPATH   環(huán)境變量或者   java   命令的   -cp   參數(shù);運(yùn)行時(shí)還要到控制臺(tái)下去使用   java   命令來運(yùn)行,如果需要直接雙擊運(yùn)行必須寫   Windows   的批處理文件   (.bat)   或者   Linux   的   Shell   程序。因此,許多人說,Java   是一種方便開發(fā)者苦了用戶的程序設(shè)計(jì)語言。  
              
            其實(shí)不然,如果開發(fā) 者能夠制作一個(gè)可執(zhí)行的   JAR   文件包交給用戶,那么用戶使用起來就方便了。在   Windows   下安裝   JRE   (Java   Runtime   Environment)   的時(shí)候,安裝文件會(huì)將   .jar   文件映射給   javaw.exe   打開。那么,對(duì)于一個(gè)可執(zhí)行的   JAR   文件包,用戶只需要雙擊它就可以運(yùn)行程序了,和閱讀   .chm   文檔一樣方便   (.chm   文檔默認(rèn)是由   hh.exe   打開的)。那么,現(xiàn)在的關(guān)鍵,就是如何來創(chuàng)建這個(gè)可執(zhí)行的   JAR   文件包。  
          posted @ 2010-04-09 17:00 新蜂 閱讀(162) | 評(píng)論 (0)編輯 收藏
          85 90 212
          posted @ 2010-04-08 23:01 新蜂 閱讀(222) | 評(píng)論 (1)編輯 收藏
          Jiri Mares wrote:

          Hi,

          I'm trying to change font size for my package explorer and it's not working. Is it right or not (I tried to find such a bug but I didn't).

          It's based on the font of your OS. You'll have to change the font in the standard OS settings.


          Dani
          posted @ 2010-04-08 22:59 新蜂 閱讀(434) | 評(píng)論 (0)編輯 收藏
          Technically, an Eclipse application is a plug-in that creates an extension for the extension point org.eclipse.core.runtime.applications.
          posted @ 2010-04-08 21:13 新蜂 閱讀(162) | 評(píng)論 (0)編輯 收藏
          JVM內(nèi)存的設(shè)置的原理
           
          默認(rèn)的java虛擬機(jī)的大小比較小,在對(duì)大數(shù)據(jù)進(jìn)行處理時(shí)java就會(huì)報(bào)錯(cuò):java.lang.OutOfMemoryError。
          設(shè)置jvm內(nèi)存的方法,對(duì)于單獨(dú)的.class,可以用下面的方法對(duì)Test運(yùn)行時(shí)的jvm內(nèi)存進(jìn)行設(shè)置。
          java -Xms64m -Xmx256m Test
          -Xms是設(shè)置內(nèi)存初始化的大小
          -Xmx是設(shè)置最大能夠使用內(nèi)存的大小(最好不要超過物理內(nèi)存大小)


          Heap設(shè)定與垃圾回收
          Java Heap分為3個(gè)區(qū),Young,Old和Permanent。Young保存剛實(shí)例化的對(duì)象。當(dāng)該區(qū)被填滿時(shí),GC會(huì)將對(duì)象移到Old區(qū)。 Permanent區(qū)則負(fù)責(zé)保存反射對(duì)象,本文不討論該區(qū)。JVM的Heap分配可以使用-X參數(shù)設(shè)定,


          -Xms
          初始Heap大小
          -Xmx
          java heap最大值
          -Xmn
          young generation的heap大小
          posted @ 2010-04-08 21:02 新蜂 閱讀(206) | 評(píng)論 (0)編輯 收藏

          在一些規(guī)模稍大的應(yīng)用中,Java虛擬機(jī)(JVM)的內(nèi)存設(shè)置尤為重要,想在項(xiàng)目中取得好的效率,GC(垃圾回收)的設(shè)置是第一步。

          PermGen space:全稱是Permanent Generation space.就是說是永久保存的區(qū)域,用于存放Class和Meta信息,Class在被Load的時(shí)候被放入該區(qū)域Heap space:存放Instance。

          GC(Garbage Collection)應(yīng)該不會(huì)對(duì)PermGen space進(jìn)行清理,所以如果你的APP會(huì)LOAD很多CLASS的話,就很可能出現(xiàn)PermGen space錯(cuò)誤

          Java Heap分為3個(gè)區(qū)
          1.Young
          2.Old
          3.Permanent

          Young保存剛實(shí)例化的對(duì)象。當(dāng)該區(qū)被填滿時(shí),GC會(huì)將對(duì)象移到Old區(qū)。Permanent區(qū)則負(fù)責(zé)保存反射對(duì)象,本文不討論該區(qū)。

          JVM的Heap分配可以使用-X參數(shù)設(shè)定,

          -Xms
          初始Heap大小

          -Xmx
          java heap最大值 

          -Xmn
          young generation的heap大小

          JVM有2個(gè)GC線程
          第一個(gè)線程負(fù)責(zé)回收Heap的Young區(qū)
          第二個(gè)線程在Heap不足時(shí), 遍歷Heap,將Young 區(qū)升級(jí)為Older區(qū)

          Older區(qū)的大小等于-Xmx減去-Xmn,不能將-Xms的值設(shè)的過大,因?yàn)榈诙? 個(gè)線程被迫運(yùn)行會(huì)降低JVM的性能。
          為什么一些程序頻繁發(fā)生GC?

          有如下原因:
          1.程序內(nèi)調(diào)用了System.gc()或Runtime.gc()。
          2.一些中間件軟件調(diào)用自己的GC方法,此時(shí)需 要設(shè)置參數(shù)禁止這些GC。
          3.Java的Heap太小,一般默認(rèn)的Heap值都很小。
          4.頻繁實(shí)例化對(duì)象,Release對(duì)象 此時(shí)盡量保存并重用對(duì)象,例如使用StringBuffer()和String()。

          如果你發(fā)現(xiàn)每次GC后,Heap的剩余空間會(huì)是總空間的50%,這表示你的Heap處于健康狀態(tài),許多Server端的Java程序每次GC后最好 能有65%的剩余空間

          經(jīng)驗(yàn)之談:

          1.Server端JVM最好將-Xms和-Xmx設(shè)為相同值。為了優(yōu)化GC,最好讓-Xmn值約等于-Xmx的1/3。
          2.一個(gè)GUI程 序最好是每10到20秒間運(yùn)行一次GC,每次在半秒之內(nèi)完成。

          注意:

          1.增加Heap的大小雖然會(huì)降低GC的頻率,但也增加了每次GC的時(shí)間。并且GC運(yùn)行時(shí),所有的用戶線程將暫停,也就是GC期間,Java應(yīng)用程 序不做任何工作。
          2.Heap大小并不決定進(jìn)程的內(nèi)存使用量。進(jìn)程的內(nèi)存使用量要大于-Xmx定義的值,因?yàn)镴ava為其他任務(wù)分配內(nèi)存,例如每 個(gè)線程的Stack等。

          Stack的設(shè)定
          每個(gè)線程都有他自己的Stack。

          -Xss
          每個(gè)線程的Stack大小

          Stack的大小限制著線程的數(shù)量。如果Stack過大就好導(dǎo)致內(nèi)存溢漏。-Xss參數(shù)決定Stack大小,例如-Xss1024K。如果 Stack太小,也會(huì)導(dǎo)致Stack溢漏。

          硬件環(huán)境

          硬件環(huán)境也影響GC的效率,例如機(jī)器的種類,內(nèi)存,swap空間,和CPU的數(shù)量。
          如果你的程序需要頻繁創(chuàng)建很多transient對(duì)象, 會(huì)導(dǎo)致JVM頻繁GC。這種情況你可以增加機(jī)器的內(nèi)存,來減少Swap空間的使用。

          4種GC

          1、第一種為單線程GC,也是默認(rèn)的GC,該GC適用于單CPU機(jī)器。
          2、第二種為Throughput GC,是多線程的GC,適用于多CPU,使用大量線程的程序。第二種GC與第一種GC相似,不同在于GC在收集Young區(qū)是多線程的,但在Old區(qū)和第 一種一樣,仍然采用單線程。-XX:+UseParallelGC參數(shù)啟動(dòng)該GC。
          3、第三種為Concurrent Low Pause GC,類似于第一種,適用于多CPU,并要求縮短因GC造成程序停滯的時(shí)間。這種GC可以在Old區(qū)的回收同時(shí),運(yùn)行應(yīng)用程序。 -XX:+UseConcMarkSweepGC參數(shù)啟動(dòng)該GC。
          4、第四種為Incremental Low Pause GC,適用于要求縮短因GC造成程序停滯的時(shí)間。這種GC可以在Young區(qū)回收的同時(shí),回收一部分Old區(qū)對(duì)象。-Xincgc參數(shù)啟動(dòng)該GC。

          單文件的JVM內(nèi)存進(jìn)行設(shè)置

          默認(rèn)的java虛擬機(jī)的大小比較小,在對(duì)大數(shù)據(jù)進(jìn)行處理時(shí)java就會(huì)報(bào)錯(cuò):java.lang.OutOfMemoryError。
          設(shè)置 jvm內(nèi)存的方法,對(duì)于單獨(dú)的.class,可以用下面的方法對(duì)Test運(yùn)行時(shí)的jvm內(nèi)存進(jìn)行設(shè)置。
          java -Xms64m -Xmx256m Test
          -Xms是設(shè)置內(nèi)存初始化的大小
          -Xmx是設(shè)置最大能夠使用內(nèi)存的大小(最好不要超過物理內(nèi)存大小)

          tomcat啟動(dòng)jvm內(nèi)存設(shè)置

          Linux:

          在/usr/local/apache-tomcat-5.5.23/bin目錄下的catalina.sh添加:JAVA_OPTS='- Xms512m -Xmx1024m'要加“m”說明是MB,否則就是KB了,在啟動(dòng)tomcat時(shí)會(huì)報(bào)內(nèi)存不足。
          -Xms:初始值
          -Xmx: 最大值
          -Xmn:最小值Windows
          在catalina.bat最前面加入
          set JAVA_OPTS=-Xms128m -Xmx350m 如果用startup.bat啟動(dòng)tomcat,OK設(shè)置生效.夠成功的分配200M內(nèi)存.但是如果不是執(zhí)行startup.bat啟動(dòng)tomcat而是 利用windows的系統(tǒng)服務(wù)啟動(dòng)tomcat服務(wù),上面的設(shè)置就不生效了,就是說set JAVA_OPTS=-Xms128m -Xmx350m 沒起作用.上面分配200M內(nèi)存就OOM了..windows服務(wù)執(zhí)行的是bin"tomcat.exe.他讀取注冊(cè)表中的值,而不是 catalina.bat的設(shè)置.解決辦法:

          修改注冊(cè)表HKEY_LOCAL_MACHINE"SOFTWARE"Apache Software Foundation"Tomcat Service Manager"Tomcat5"Parameters"JavaOptions

          原值為

          -Dcatalina.home="C:"ApacheGroup"Tomcat 5.0"
          -Djava.endorsed.dirs="C:"ApacheGroup"Tomcat 5.0"common"endorsed"
          -Xrs加入 -Xms300m -Xmx350m

          重起tomcat服務(wù),設(shè)置生效

          weblogic啟動(dòng)jvm內(nèi)存設(shè)置

          在weblogic中,可以在startweblogic.cmd中對(duì)每個(gè)domain虛擬內(nèi)存的大小進(jìn)行設(shè)置,默認(rèn)的設(shè)置是在 commEnv.cmd里面。

          JBoss

          默認(rèn)可以使用的內(nèi)存為64MB
          $JBOSSDIR$/bin/run.config
          JAVA_OPTS = "-server -Xms128 -Xmx512"

          Eclipse

          在所在目錄下,鍵入
          eclipse.exe -vmargs -Xms256m -Xmx512m
          256m表示JVM堆內(nèi)存最 小值
          512m表示JVM堆內(nèi)存最大

          Websphere

          進(jìn)入控制臺(tái)去設(shè)置:應(yīng)用程序服務(wù)器 > server1 > 進(jìn)程定義 > Java 虛擬機(jī)

          posted @ 2010-04-08 21:02 新蜂 閱讀(636) | 評(píng)論 (1)編輯 收藏
          僅列出標(biāo)題  下一頁
          <2025年6月>
          25262728293031
          1234567
          891011121314
          15161718192021
          22232425262728
          293012345

          常用鏈接

          留言簿

          隨筆分類

          隨筆檔案

          文章檔案

          搜索

          •  

          最新評(píng)論

          閱讀排行榜

          評(píng)論排行榜

          主站蜘蛛池模板: 杭锦旗| 河源市| 疏附县| 陈巴尔虎旗| 正蓝旗| 桑日县| 黑水县| 和顺县| 沙洋县| 乃东县| 通化市| 桓台县| 桐梓县| 共和县| 张家口市| 刚察县| 玛沁县| 巴楚县| 广元市| 临澧县| 通城县| 闽侯县| 长岭县| 青河县| 阿克苏市| 蓝山县| 桐城市| 嘉义市| 古丈县| 崇礼县| 盐源县| 开鲁县| 浠水县| 景洪市| 新巴尔虎左旗| 新宾| 岢岚县| 阳信县| 台江县| 澄江县| 田阳县|