Java????÷????
???????????? ???????[ 2015/4/7 13:55:08 ] ????????Java ??????? ?÷? ???
?????????????
?????????????????????????????????????????顣
???????Runnnable??????
????void startAThread0(){
????new Thread(new MyRunnable()).start();
????}
????class MyRunnable implements Runnable{
????public void run(){
????...
????}
????}
???????Thread??????
????void startAThread1(){
????new MyThread().start();
????}
????class MyThread extends Thread{
????public void run(){
????...
????}
????}
???????????Thread??????
????void startAThread2(){
????new Thread(){
????public void run(){
????...
????}
????}.start();
????}
?????????????run()?????????????Thread.start()?????????????????????μ?????????????????run()??
?????ο???java.lang.Thread??java.lang.Runnable??
???????try-finally
????I/O???????
????void writeStuff()throws IOException{
????OutputStream out=new FileOutputStream(...);
????try{
????out.write(...);
????}finally{
????out.close();
????}
????}
???????????
????void doWithLock(Lock lock){
????lock.acquire();
????try{
????...
????}finally{
????lock.release();
????}
????}
???????try???????????????????????????finally???鯔????С??????????????????????????????????????
???????try??????????????????????????????л?????finally????????о????????????????????????????????????????????????Χ??finally???飩??
???????????????????????
????InputStream in=(...);
????try{
????while(true){
????int b=in.read();
????if(b==-1)
????break;
????(...process b...)
????}
????}finally{
????in.close();
????}
????read()??????????????δ????????????????0??255??????0??255?????????????????????-1??
?????ο???java.io.InputStream.read()??
??????????????????????
????InputStream in=(...);
????try{
????byte[]buf=new byte[100];
????while(true){
????int n=in.read(buf);
????if(n==-1)
????break;
????(...process buf with offset=0 and length=n...)
????}
????}finally{
????in.close();
????}
?????????????read()???????????????????buf????????????????????п???????????
?????ο???java.io.InputStream.read(byte[])??java.io.InputStream.read(byte[]??int??int)??
????????????????
????BufferedReader in=new BufferedReader(
????new InputStreamReader(new FileInputStream(...)??"UTF-8"));
????try{
????while(true){
????String line=in.readLine();
????if(line==null)
????break;
????(...process line...)
????}
????}finally{
????in.close();
????}
????BufferedReader??????????ú?????????????Java?????????????????????????????????????C??????????
?????????????κ??????InputStream??????FileInputStream??????socket??
??????????????????BufferedReader.readLine()????null??
???????ζ?????????????Reader.read()??????
???????????????????????????????UTF-8?????ò??????????
?????ο???java.io.BufferedReader??java.io.InputStreamReader??
???????????????????????漰???????????????????SPASVOС??(021-61079698-8054)?????????????????????????
??????
Java???????????Щ???????????????Java????????????????Java?б???Map????????Java Web???????????????Java??????????????д?????Java????????7???????????????????????(java .net ?????)???Java??????????Python??????Java webdriver??λ????????′????е?????Java??д??????????????????Java???????????????JavaScript????????????Java?????????????????? Java???????10??????????????Java?м????????????????java???????ü???????????м???????????????????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11????????
?????????App Bug???????????????????????Jmeter?????????QC??????APP????????????????app?????е????????jenkins+testng+ant+webdriver??????????????JMeter????HTTP???????Selenium 2.0 WebDriver ??????