Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

javaÖÐÌæ»»ÎʺÅ

String srt="abc?abc";
str.replaceAll("?", "#");
»áÌáʾÕâÑùµÄ´íÎó
Dangling meta character '?' near index 0
?
^
at java.util.regex.Pattern.error(Unknown Source)
at java.util.regex.Pattern.sequence(Unknown Source)
at java.util.regex.Pattern.expr(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
at java.util.regex.Pattern.<init>(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
at java.lang.String.replaceAll(Unknown Source)
str.replaceAll("[?]", "#");
ÕâÑùд¾Í¿ÉÒÔÁË


Ïà¹ØÎĵµ£º

¹¦ÄÜÍêÉƵÄJavaÁ¬½Ó³Øµ÷ÓÃʵÀý


/**
* Title: ConnectPool.java
* Description: Á¬½Ó³Ø¹ÜÀíÆ÷
* Copyright: Copyright (c) 2002/12/25
* Company:
* Author :
* Version 2.0
*/
import java.io.*;
import java.sql.*;
import java.util.*;
import java.util.Date;
/**
* ¹ÜÀíÀàDBConnectionManagerÖ§³Ö¶ÔÒ»¸ö»ò¶à¸öÓÉÊôÐÔÎļ ......

»ùÓÚJavaµÄһЩȨÏÞ¿ò¼Ü¼ò½é


»ùÓÚJavaµÄһЩȨÏÞ¿ò¼Ü¼ò½é
JOSSO
  JOSSO(Java   Open   Single   Sign-On)ÊÇÒ»¸ö¿ªÔ´µÄJ2EE-basedµÄSSO(SSO£ºµ¥Ò»µÇ¼¼¼ÊõÊÇÒ»ÖÖÈÏÖ¤ºÍÊÚȨ»úÖÆ£¬ËüÔÊÐí×¢²áÓû§Ö»ÐèÒªÔÚÈÎÒ»³ÉÔ±ÍøÕ¾ÉϵǼһ´Î£¬¶øºóÊÚȨ·ÃÎÊÆäËûÁ¬½ÓµÄ·ÖÖ§ÍøÕ¾£¬ÎÞÐèÔÙ½øÐÐÑéÖ¤µÇ¼)»ù´¡½á¹¹.ËüµÄÄ¿µÄÊÇÌṩһÖÖÓÃÀ´½â¾öÔÚÍ³Ò ......

java·½·¨µÄÖØÔØÓ븲¸Ç

java¶à̬µÄ2ÖÖ±íÏÖÐÎʽ ·½·¨ÖØÔغͷ½·¨¸²¸Ç
·½·¨ÖØÔØ£ºÍ¬Ò»¸öÀàÖУ¬·½·¨ÃûÏàͬ£¬²ÎÊýÁÐ±í²»Í¬µÄ2¸ö»ò¶à¸ö·½·¨¹¹³É·½·¨µÄÖØÔØ¡£
·½·¨¸²¸Ç£º×ÓÀàÖØÐÂʵÏÖÁ˸¸ÀàÖеķ½·¨¡£
·½·¨ÖØÔØ
/**
* ·½·¨ÖØÔØÂú×ãµÄÌõ¼þ
* ͬһ¸öÀàÖУ¬·½·¨ÃûÏàͬ£¬²ÎÊýÁÐ±í²»Í¬µÄ2¸ö»ò¶à¸ö·½·¨¹¹³É·½·¨µÄÖØÔØ
* ²ÎÊýÁÐ±í²»Í¬Ö¸²ÎÊýµÄÀàÐÍ£¬²Î ......

javaºËÐļ¼Êõ¾íII±Ê¼Ç

 1.¼òµ¥Ï̴߳´½¨
(1)ʵÏÖRunnable½Ó¿Ú£¬Runnable½Ó¿ÚÖ»ÓÐÒ»¸ö·½·¨run:
public interface Runnable
{
void run();
}
´´½¨ÀàʵÏÖrun·½·¨
class MyRunnable implements Runnable
{
public void run()
{
/*ÈÎÎñ´úÂë*/
}
}
(2)´´½¨¶ÔÏó
Runnable r = new MyRunnable();
(3)ÓÉRunnable´´½¨Ò»¸öThread¶ÔÏó:
......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ