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

flexÇëÇóÖÐץȡJAVAÒì³£ÐÅÏ¢

     ÈçºÎ»ñÈ¡LCDSÇëÇó¹ý³ÌÖÐJAVAÅ׳öÀ´µÄExceptionÄØ£¿ µ±flexͨ¹ýÇëÇó¶ÔÏóÇëÇó·þÎñ¶ËµÄʱºò£¬ÇëÇó³É¹¦»á·¢mx.rpc.events.ResultEventʼþ£¬Óöµ½·þÎñ¶ËÒì³£»òÆäËû·Ç200µÄHTTP״̬Â루ÀýÈç404£¬403£©Ôò»á·¢mx.rpc.events.FaultEventʼþ£¬µ«ÇëÇóʧ°ÜÊÇÒòΪʲôԭÒòÄØ£¿ÒòΪ²»Í¬µÄÔ­Òò¿ÉÄܵ¼Ö½çÃæÉϲ»Í¬µÄ´¦Àí²Ù×÷£¬×î¼òµ¥µÄ°ì·¨¾ÍÊÇ´Ó·þÎñ¶ËµÄÒì³£ÖлñÈ¡£¬ÎÒÃÇ¿ÉÒÔ°ÑÕâЩÐÅÏ¢·ÅÔÚÒì³£ÖУ¬ÓÉÇ°¶ËFLEXÈ¥¶ÁÈ¡²¢´¦Àí£»
  FaultEventʼþÖÐÓÐÒ»¸ömessageÊôÐÔ£¬ÊÇÒ»¸öÀàÐÍΪmx.messaging.messages.ErrorMessageµÄÏûÏ¢À࣬¸ÃÀàÖÐÓÐÒ»¸örootCauseÊôÐÔ£¬Òì³£µÄÏà¹ØÐÅÏ¢¶¼·ÅÔÚÕâ¸ö¶ÔÏóÖУ¬ÏȽ¨Ò»¸ö×Ô¶¨ÒåµÄJAVAÒì³££º
package com.hanover.ml.servicebroker;
public class CustomException extends Exception {
private int errorCode;
private String errorDesc;

public int getErrorCode(){
return errorCode;
}

public void setErrorCode(int value){
errorCode = value;
}

public String getErrorDesc(){
return errorDesc;
}

public void setErrorDesc(String value){
errorDesc = value;
}

}
 
 
ÀïÃæÓÐÁ½¸öÊôÐÔ£¬·Ö±ðÊÇerrorCodeºÍerrorDesc£¬·Ö±ð¿ÉÒÔ´ú±íÒì³£µÄÖÖÀàºÍÃèÊö£¬È»ºóÎÒÃÇÔÚµ÷Ó÷½·¨ÖÐץȡµ½ËùÓÐÒì³£²¢×ª³ÉÕâ¸ö×Ô¶¨ÒåµÄCustomException£º
public void getExceptionTest() throws CustomException
{
try{
//function content
//Âß¼­Òì³£
CustomException ce = new CustomException();
ce.setErrorCode(201);
ce.setErrorDesc("¸Ã¼Ç¼Òѱ»É¾³ý");
throw ce;
}catch(NullPointerException ne){
CustomException ce = new CustomException();
ce.setErrorCode(101);
ce.setErrorDesc("type1 error desc");
throw ce;
}catch(Exception e){
CustomException ce = new CustomException();
ce.setErrorCode(101);
ce.setErrorDesc(e.getMessage());
throw ce;
}

½Ó×ÅÔÚflex¶ËµÄfaultʼþÖлñÈ¡Òì³£ÐÅÏ¢£º
public function fault(event:Object):void
{
var faultEvent:FaultEvent = event as FaultEvent;
var errorMessage:ErrorMessage = faultEvent.message as ErrorMessage;
if(errorMessage && errorMessage.rootCause)
{


Ïà¹ØÎĵµ£º

ÀûÓÃJAVA²Ù×÷EXCELÎļþ

2003 Äê 1 ÔÂ 11 ÈÕ
ʹÓÃWindows²Ù×÷ϵͳµÄÅóÓѶÔExcel£¨µç×Ó±í¸ñ£©Ò»¶¨²»»áÄ°Éú£¬µ«ÊÇҪʹÓÃJavaÓïÑÔÀ´²Ù×ÝExcelÎļþ²¢²»ÊÇÒ»¼þÈÝÒ×µÄÊ¡£ÔÚWebÓ¦ÓÃÈÕÒæÊ¢ÐеĽñÌ죬ͨ¹ýWebÀ´²Ù×÷ExcelÎļþµÄÐèÇóÔ½À´Ô½Ç¿ÁÒ£¬Ä¿Ç°½ÏΪÁ÷ÐеIJÙ×÷ÊÇÔÚJSP»òServlet Öд´½¨Ò»¸öCSV £¨comma separated values£©Îļþ£¬²¢½«Õâ¸öÎļþÒÔMIME£¬tex ......

½« Flex ¼¯³Éµ½ Java EE Ó¦ÓóÌÐòµÄ×î¼Ñʵ¼ù


Ô­ÌûµØÖ·£ºhttp://www.ibm.com/developerworks/cn/java/j-lo-jeeflex/?S_TACT=105AGX52&S_CMP=tec-csdn
´«Í³µÄ Java EE Ó¦ÓóÌÐòͨ³£Ê¹ÓÃijÖÖ MVC ¿ò¼Ü£¨ÀýÈ磬Struts£©×÷Ϊǰ¶ËÓû§½çÃ棬Ëæ×Å Flex µÄÐËÆ𣬻ùÓÚ RIA µÄ¿Í»§¶ËÄܹ»¸øÓû§´øÀ´¸ü¿áµÄ½çÃ棬¸ü¶ÌµÄÏìӦʱ¼ä£¬ÒÔ¼°¸ü½Ó½üÓÚ×ÀÃæÓ¦ÓóÌÐòµÄÌåÑé¡£±¾ÎĽ«½²Ê ......

Java´íÎó´¦Àí´ó¼¯ºÏ


0¡¢ ÐèÒª±êʶ·û
a) ²»ÔÚº¯ÊýÄÚ
1¡¢ ·Ç·¨±í´ïʽ¿ªÊ¼
b) ¿ÉÄÜ:¶ªÊ§À¨ºÅ .
2. no data found
a) ¿ÉÄÜ:setInt(1,100)ÖÐ,ûÓÐ100Õâ¸öÖµ
3. ÕÒ²»µ½·ûºÅ
a) ¿ÉÄÜ:ûµ¼Èë°ü
4. Ö¸¶¨ÁËÎÞЧURL
a) ¿ÉÄÜ:Êý¾Ý¿âÃû»òIP´íÎó,¼´Á¬½Ó³ö´í
5. Àà·¾¶Ã»ÓÐÕÒµ½
a) ¿ÉÄÜ: ClassNotFoundException: oracle.jdbc.driver.OracleDriv ......

½âÎöJava¶ÔÏóµÄequals()ºÍhashCode()µÄʹÓÃ

ÔÚJavaÓïÑÔÖУ¬equals()ºÍhashCode()Á½¸öº¯ÊýµÄʹÓÃÊǽôÃÜÅäºÏµÄ£¬ÄãÒªÊÇ×Ô¼ºÉè¼ÆÆäÖÐÒ»¸ö£¬¾ÍÒªÉè¼ÆÁíÍâÒ»¸ö¡£ÔÚ¶àÊýÇé¿ö
Ï£¬ÕâÁ½¸öº¯ÊýÊDz»Óÿ¼Âǵģ¬Ö±½ÓʹÓÃËüÃǵÄĬÈÏÉè¼Æ¾Í¿ÉÒÔÁË¡£µ«ÊÇÔÚһЩÇé¿öÏ£¬ÕâÁ½¸öº¯Êý×îºÃÊÇ×Ô¼ºÉè¼Æ£¬²ÅÄÜÈ·±£Õû¸ö³ÌÐòµÄÕý³£ÔËÐС£×î³£¼ûµÄÊǵ±
Ò»¸ö¶ÔÏó±»¼ÓÈëÊÕ¼¯¶ÔÏó£¨collection
ob ......

JAVA²ÎÊý´«µÝÖµ´«µÝµÄÀí½â¡£

Ê×ÏÈÃ÷ȷһϣºjavaÀïÃæÖ»ÓÐÖµ´«µÝ£¬ÒýÓô«µÝÖ»ÊÇÒ»Ö»Îó¶Á¶øÒÑ¡£
À´¿´Ò»¸öÀý×Ó£º
public static void main(String[] args)
{
StringBuffer str1 = new StringBuffer("hello");
test(str1);
System.out.println("main : " + str1);
}
public static void test(StringBuffer s ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ