顯示具有 Java 標籤的文章。 顯示所有文章
顯示具有 Java 標籤的文章。 顯示所有文章

2014年3月19日 星期三

Java - 關閉Java更新通知的方法 Disable Windows7每次都跳出java auto update訊息




http://blog.xuite.net/qzwxeasd/Note/66414791-+%E9%97%9C%E9%96%89Java%E6%9B%B4%E6%96%B0%E9%80%9A%E7%9F%A5%E7%9A%84%E6%96%B9%E6%B3%95+%E4%B8%8D%E8%AE%93Windows7%E6%AF%8F%E6%AC%A1%E9%96%8B%E6%A9%9F%E9%83%BD%E8%B7%B3%E4%B8%80%E6%AC%A1java+auto+update%E8%A8%8A%E6%81%AF+msconfig%E5%95%9F%E5%8B%95%E8%A8%AD%E5%AE%9A%E6%96%B9%E6%B3%95


1. Uninstall JRE7
2. Install JRE6
jdk-6u32-windows-x64.exe
3. Reboot
4. 開始>控制台>Java
開始>控制台>JAVA>Java>JRE Seetings

5. 開始>控制台>Java>Advanced>JRE Auto-Download>
Choose Never Auto-Download
6. 開始>所有程式>附屬應用程式>命令提示字元
輸入msconfig 按Enter 會跳出一個"系統設定"視窗 
到"啟動"頁籤 啟動項目找 "Java(TM)..."開頭的 取消勾選 按 確定
他會跳出 下次開機後才生效 確定
這樣就一勞永逸了
"Java(TM)..."就是JAVA程式每次開機檢查更新的程式 不影響JAVA程式的運行

2012年5月25日 星期五

Java - 第一支java程式


C:\workspace>type HelloWorld.java
public class HelloWorld {
        public static void main(String[] args) {
                System.out.println("Hello! World!");
        }
}

C:\workspace>javac HelloWorld.java

C:\workspace>java HelloWorld
Hello! World!

Java - 安裝JDK Java SE Development Kit 6 Update 32





[root@testdb1 source]# ll
total 3946192
-rw-r--r-- 1 oracle oinstall   68835673 May 25 05:26 jdk-6u32-linux-x64-rpm.bin
[root@testdb1 source]# chmod 744 jdk-6u32-linux-x64-rpm.bin
[root@testdb1 source]# ll
total 3946192
-rwxr--r-- 1 oracle oinstall   68835673 May 25 05:26 jdk-6u32-linux-x64-rpm.bin
[root@testdb1 source]# ./jdk-6u32-linux-x64-rpm.bin
Unpacking...
Checksumming...
Extracting...
UnZipSFX 5.50 of 17 February 2002, by Info-ZIP (Zip-Bugs@lists.wku.edu).
  inflating: jdk-6u32-linux-amd64.rpm
  inflating: sun-javadb-common-10.6.2-1.1.i386.rpm
  inflating: sun-javadb-core-10.6.2-1.1.i386.rpm
  inflating: sun-javadb-client-10.6.2-1.1.i386.rpm
  inflating: sun-javadb-demo-10.6.2-1.1.i386.rpm
  inflating: sun-javadb-docs-10.6.2-1.1.i386.rpm
  inflating: sun-javadb-javadoc-10.6.2-1.1.i386.rpm
Preparing...                ########################################### [100%]
   1:jdk                    ########################################### [100%]
Unpacking JAR files...
        rt.jar...
        jsse.jar...
        charsets.jar...
        tools.jar...
        localedata.jar...
        plugin.jar...
        javaws.jar...
        deploy.jar...
Installing JavaDB
Preparing...                ########################################### [100%]
   1:sun-javadb-common      ########################################### [ 17%]
   2:sun-javadb-core        ########################################### [ 33%]
   3:sun-javadb-client      ########################################### [ 50%]
   4:sun-javadb-demo        ########################################### [ 67%]
   5:sun-javadb-docs        ########################################### [ 83%]
   6:sun-javadb-javadoc     ########################################### [100%]


Java(TM) SE Development Kit 6 successfully installed.


Product Registration is FREE and includes many benefits:
* Notification of new versions, patches, and updates
* Special offers on Oracle products, services and training
* Access to early releases and documentation


Product and system data will be collected. If your configuration
supports a browser, the JDK Product Registration form will
be presented. If you do not register, none of this information
will be saved. You may also register your JDK later by
opening the register.html file (located in the JDK installation
directory) in a browser.


For more information on what data Registration collects and
how it is managed and used, see:
http://java.sun.com/javase/registration/JDKRegistrationPrivacy.html


Press Enter to continue.....




Done.


[root@testdb1 bin]# pwd
/usr/java/jdk1.6.0_32/bin

[root@testdb1 bin]# ls
appletviewer   jar        javap     jinfo       jstat         pack200      serialver   xjc
apt            jarsigner  javaws    jmap        jstatd        policytool   servertool
ControlPanel   java       jconsole  jps         jvisualvm     rmic         tnameserv
extcheck       javac      jcontrol  jrunscript  keytool       rmid         unpack200
HtmlConverter  javadoc    jdb       jsadebugd   native2ascii  rmiregistry  wsgen
idlj           javah      jhat      jstack      orbd          schemagen    wsimport




[root@testdb1 bin]# su - oracle





oracle_DGTEST_testdb1.rgp.raritan.com$vi .bash_profile
# .bash_profile


# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi


# User specific environment and startup programs


PATH=$PATH:$HOME/bin


export PATH


export ORACLE_SID=DGTEST
ORACLE_BASE=/u01/oracle
ORACLE_HOME=/u01/oracle/product/11.2.0
LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/rdbms/lib
NLS_LANG=american_america.UTF8
PATH=/usr/bin:$ORACLE_HOME/bin:$PATH:$HOME/bin
PATH=/usr/java/jdk1.6.0_32/bin:$PATH


export PATH ORACLE_BASE ORACLE_HOME LD_LIBRARY_PATH NLS_LANG ORACLE_SID
#export TZ=GMT
#export DB_UNIQUE_NAME=ERP
PS1=$USER'_'$ORACLE_SID'_'$HOSTNAME'$'





oracle_DGTEST_testdb1.rgp.raritan.com$java -version
java version "1.6.0_32"
Java(TM) SE Runtime Environment (build 1.6.0_32-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)






2012年5月24日 星期四

Java - 網路上的學習資源

同事遇到一個Java程式的效能問題,但是我學校畢業後,就沒有在coding了,所以幫不上忙。
想要買書來自學,去 www.books.com.tw 逛逛,還真的貴,也不知道該怎麼選擇。

所以還是google了一下,發現網路上的學習資源,就夠我用了,謝謝這些專業好心人士的分享。

http://www.javaworld.com.tw/jute/post/page?bid=29&sty=1&age=0&tpg=1

http://caterpillar.onlyfun.net/Gossip/index.html