Subversion Repositories eFlore/Applications.del

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 aurelien 1
package org.tela_botanica.del.client;
2
 
1118 gduche 3
import org.tela_botanica.del.client.cache.CacheClient;
22 aurelien 4
import org.tela_botanica.del.client.gestionhistorique.GestionnaireHistorique;
9 benjamin 5
 
1 aurelien 6
import com.google.gwt.core.client.EntryPoint;
9 benjamin 7
import com.google.gwt.user.client.History;
1 aurelien 8
 
9
public class Del implements EntryPoint {
529 jpm 10
 
1 aurelien 11
	@Override
12
	public void onModuleLoad() {
1316 aurelien 13
 
1995 aurelien 14
	    /*GWT.setUncaughtExceptionHandler(new
15
	    		GWT.UncaughtExceptionHandler() {
16
	    	public void onUncaughtException(Throwable e) {
17
	    		Throwable unwrapped = unwrap(e);
18
	    		Window.alert(buildStackTrace(unwrapped, ""));
19
	    	}
20
 
21
	    	public Throwable unwrap(Throwable e) {
22
	    		if(e instanceof UmbrellaException) {
23
	    			UmbrellaException ue = (UmbrellaException) e;
24
	    			if(ue.getCauses().size() == 1) {
25
	    				return unwrap(ue.getCauses().iterator().next());
26
	    			}
27
	    		}
28
	    		return e;
29
	    	}
30
	    });*/
1316 aurelien 31
 
1561 jpm 32
		CacheClient.getInstance().initialiserAvecParametres();
33
		History.addValueChangeHandler(new GestionnaireHistorique());
1034 benjamin 34
		History.fireCurrentHistoryState();
1 aurelien 35
	}
1316 aurelien 36
 
1501 aurelien 37
	/*private String buildStackTrace(Throwable t, String log) {
1561 jpm 38
		if (t != null) {
39
			log += t.getClass().toString();
40
			log += t.getMessage();
41
 
42
			StackTraceElement[] stackTrace = t.getStackTrace();
43
			if (stackTrace != null) {
44
				StringBuffer trace = new StringBuffer();
45
 
46
				for (int i = 0; i < stackTrace.length; i++) {
47
					trace.append(stackTrace[i].getClassName() + "." + stackTrace[i].getMethodName() + "("
48
						+ stackTrace[i].getFileName() + ":" + stackTrace[i].getLineNumber());
49
				}
50
 
51
				log += trace.toString();
52
			}
53
 
54
			Throwable cause = t.getCause();
55
			if (cause != null && cause != t) {
56
				log += buildStackTrace(cause, "CausedBy:\n");
57
			}
58
		}
59
		return log;
60
	}*/
1 aurelien 61
}