comparison core/src/luan/modules/PickleServer.java @ 517:8dcf9e12446b

add Luan.on_luan_close()
author Franklin Schmidt <fschmidt@gmail.com>
date Wed, 27 May 2015 01:20:49 -0600
parents dae264ad6a7b
children f99c79b0b426
comparison
equal deleted inserted replaced
516:5752df8a67b5 517:8dcf9e12446b
44 } catch(LuanException e) { 44 } catch(LuanException e) {
45 // System.out.println(e); 45 // System.out.println(e);
46 //e.printStackTrace(); 46 //e.printStackTrace();
47 StringBuilder sb = new StringBuilder(); 47 StringBuilder sb = new StringBuilder();
48 sb.append( "return false, " ); 48 sb.append( "return false, " );
49 sb.append( con.pickle(e.getMessage()) ); 49 sb.append( con.pickle(e.getFullMessage(con.luan)) );
50 sb.append( ", " ); 50 sb.append( ", " );
51 sb.append( con.pickle(con.src) ); 51 sb.append( con.pickle(con.src) );
52 sb.append( '\n' ); 52 sb.append( '\n' );
53 /*
54 Throwable cause = e.getCause();
55 if( cause != null ) {
56 sb.append( "\nCaused by: " );
57 StringWriter sw = new StringWriter();
58 cause.printStackTrace(new PrintWriter(sw));
59 sb.append( sw );
60 }
61 */
62 con.write( sb.toString() ); 53 con.write( sb.toString() );
63 } 54 }
64 } catch(LuanException e2) { 55 } catch(LuanException e2) {
65 throw new RuntimeException(e2); 56 throw new RuntimeException(e2);
66 } 57 }