schuetzejanett
Erfahrenes Mitglied
hallo,
ich schreibe eine rcp app. bevor diese startet kommt ein Login Dialog. Bei ok soll eine klasse aufgerufe werden die testet ob es die kombination von name und passwort gibt. Aber wenn ich jetzt meine client klasse aufrufen will bekomme ich eine NoClassdefFoud exception.
Kann es sein das das daran liegt. das ich das login feld hier aufrufe.
Also bevor
ausgeführt wird?
Und wie könnte ich das anders machen? Will halst das erst der Login Dialog kommt und erst wenn der nutzer bekannt ist, das richitge fenster aufgeht.?
Wie löst ihr das?
ich schreibe eine rcp app. bevor diese startet kommt ein Login Dialog. Bei ok soll eine klasse aufgerufe werden die testet ob es die kombination von name und passwort gibt. Aber wenn ich jetzt meine client klasse aufrufen will bekomme ich eine NoClassdefFoud exception.
Kann es sein das das daran liegt. das ich das login feld hier aufrufe.
Code:
public class Application implements IPlatformRunnable {
/* (non-Javadoc)
* @see org.eclipse.core.runtime.IPlatformRunnable#run(java.lang.Object)
*/
public Object run(Object args) throws Exception {
Display display = PlatformUI.createDisplay();
try {
if (!login())
return IPlatformRunnable.EXIT_OK;
int returnCode = PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor());
if (returnCode == PlatformUI.RETURN_RESTART) {
return IPlatformRunnable.EXIT_RESTART;
}
return IPlatformRunnable.EXIT_OK;
} finally {
display.dispose();
}
}
private boolean login()
{
DialogLogin dialogLogin = new DialogLogin();
if (dialogLogin.open() != Window.OK)
return false;
Preferences pref = Preferences.getInstance();
return true;
}
Code:
PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor());
Und wie könnte ich das anders machen? Will halst das erst der Login Dialog kommt und erst wenn der nutzer bekannt ist, das richitge fenster aufgeht.?
Wie löst ihr das?