Skip to content

Instantly share code, notes, and snippets.

@lincolnthree
Created February 13, 2012 22:29
Show Gist options
  • Save lincolnthree/1821004 to your computer and use it in GitHub Desktop.
Save lincolnthree/1821004 to your computer and use it in GitHub Desktop.
package org.jboss.errai.ioc.client.api;
import com.ocpsoft.socialpm.gwt.client.local.App;
import com.ocpsoft.socialpm.gwt.client.local.AppActivityMapper;
import com.ocpsoft.socialpm.gwt.client.local.AppPlaceHistoryMapper;
import com.ocpsoft.socialpm.gwt.client.local.ClientFactory;
import com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl;
import com.ocpsoft.socialpm.gwt.client.local.EventsFactory;
import com.ocpsoft.socialpm.gwt.client.local.ServiceFactory;
import com.ocpsoft.socialpm.gwt.client.local.view.HomeView;
import com.ocpsoft.socialpm.gwt.client.local.view.HomeViewImpl;
import com.ocpsoft.socialpm.gwt.client.local.view.LoginView;
import com.ocpsoft.socialpm.gwt.client.local.view.LoginViewImpl;
import com.ocpsoft.socialpm.gwt.client.local.view.ProfileView;
import com.ocpsoft.socialpm.gwt.client.local.view.ProfileViewImpl;
import com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent;
import com.ocpsoft.socialpm.gwt.client.shared.HelloMessage;
import com.ocpsoft.socialpm.gwt.client.shared.Response;
import com.ocpsoft.socialpm.gwt.client.shared.rpc.AuthenticationService;
import com.ocpsoft.socialpm.gwt.client.shared.rpc.ProfileService;
import java.lang.annotation.Annotation;
import java.util.Set;
import javax.enterprise.event.Event;
import org.jboss.errai.bus.client.api.Message;
import org.jboss.errai.enterprise.client.cdi.AbstractCDIEventCallback;
import org.jboss.errai.enterprise.client.cdi.CDIProtocol;
import org.jboss.errai.enterprise.client.cdi.EventProvider;
import org.jboss.errai.ioc.client.ContextualProviderContext;
import org.jboss.errai.ioc.client.InterfaceInjectionContext;
import org.jboss.errai.ioc.client.api.builtin.CallerProvider;
import org.jboss.errai.ioc.client.api.builtin.MessageBusProvider;
import org.jboss.errai.ioc.client.api.builtin.RequestDispatcherProvider;
import org.jboss.errai.ioc.client.api.builtin.RootPanelProvider;
public class BootstrapperImpl implements Bootstrapper {
private native static void com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_authService(ServiceFactory instance, Caller<AuthenticationService> value) /*-{
[email protected]::authService = value;
}-*/;
private native static Caller<AuthenticationService> com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_authService(ServiceFactory instance) /*-{
return [email protected]::authService;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_profileService(ServiceFactory instance, Caller<ProfileService> value) /*-{
[email protected]::profileService = value;
}-*/;
private native static Caller<ProfileService> com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_profileService(ServiceFactory instance) /*-{
return [email protected]::profileService;
}-*/;
private native static void org_jboss_errai_enterprise_client_cdi_EventProvider_context(EventProvider instance, ContextualProviderContext value) /*-{
[email protected]::context = value;
}-*/;
private native static ContextualProviderContext org_jboss_errai_enterprise_client_cdi_EventProvider_context(EventProvider instance) /*-{
return [email protected]::context;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_EventsFactory_loggedInEvent(EventsFactory instance, Event<LoginEvent> value) /*-{
[email protected]::loggedInEvent = value;
}-*/;
private native static Event<LoginEvent> com_ocpsoft_socialpm_gwt_client_local_EventsFactory_loggedInEvent(EventsFactory instance) /*-{
return [email protected]::loggedInEvent;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_EventsFactory_messageEvent(EventsFactory instance, Event<HelloMessage> value) /*-{
[email protected]::messageEvent = value;
}-*/;
private native static Event<HelloMessage> com_ocpsoft_socialpm_gwt_client_local_EventsFactory_messageEvent(EventsFactory instance) /*-{
return [email protected]::messageEvent;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(ClientFactoryImpl instance, EventsFactory value) /*-{
instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::eventFactory = value;
}-*/;
private native static EventsFactory com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(ClientFactoryImpl instance) /*-{
return instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::eventFactory;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(ClientFactoryImpl instance, ServiceFactory value) /*-{
instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::serviceFactory = value;
}-*/;
private native static ServiceFactory com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(ClientFactoryImpl instance) /*-{
return instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::serviceFactory;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_homeView(ClientFactoryImpl instance, HomeView value) /*-{
instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::homeView = value;
}-*/;
private native static HomeView com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_homeView(ClientFactoryImpl instance) /*-{
return instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::homeView;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_loginView(ClientFactoryImpl instance, LoginView value) /*-{
instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::loginView = value;
}-*/;
private native static LoginView com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_loginView(ClientFactoryImpl instance) /*-{
return instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::loginView;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_viewProfileView(ClientFactoryImpl instance, ProfileView value) /*-{
instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::viewProfileView = value;
}-*/;
private native static ProfileView com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_viewProfileView(ClientFactoryImpl instance) /*-{
return instance.@com.ocpsoft.socialpm.gwt.client.local.ClientFactoryImpl::viewProfileView;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_App_clientFactory(App instance, ClientFactory value) /*-{
[email protected]::clientFactory = value;
}-*/;
private native static ClientFactory com_ocpsoft_socialpm_gwt_client_local_App_clientFactory(App instance) /*-{
return [email protected]::clientFactory;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_App_historyMapper(App instance, AppPlaceHistoryMapper value) /*-{
[email protected]::historyMapper = value;
}-*/;
private native static AppPlaceHistoryMapper com_ocpsoft_socialpm_gwt_client_local_App_historyMapper(App instance) /*-{
return [email protected]::historyMapper;
}-*/;
private native static void com_ocpsoft_socialpm_gwt_client_local_App_activityMapper(App instance, AppActivityMapper value) /*-{
[email protected]::activityMapper = value;
}-*/;
private native static AppActivityMapper com_ocpsoft_socialpm_gwt_client_local_App_activityMapper(App instance) /*-{
return [email protected]::activityMapper;
}-*/;
public InterfaceInjectionContext bootstrapContainer() {
InterfaceInjectionContext ctx = new InterfaceInjectionContext();
final RequestDispatcherProvider inj1313 = new RequestDispatcherProvider();
final RootPanelProvider inj1320 = new RootPanelProvider();
final MessageBusProvider inj1325 = new MessageBusProvider();
final ClientFactoryImpl inj102 = new ClientFactoryImpl();
final ClientFactoryImpl inj1344 = new ClientFactoryImpl();
final ServiceFactory inj1346 = new ServiceFactory();
final CallerProvider inj1312 = new CallerProvider();
com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_authService(inj1346, inj1312.provide(new Class[] { AuthenticationService.class }, null));
final CallerProvider inj1347 = new CallerProvider();
com_ocpsoft_socialpm_gwt_client_local_ServiceFactory_profileService(inj1346, inj1347.provide(new Class[] { ProfileService.class }, null));
final AppPlaceHistoryMapper inj1348 = new AppPlaceHistoryMapper();
final EventsFactory inj1349 = new EventsFactory();
final EventProvider inj1308 = new EventProvider();
org_jboss_errai_enterprise_client_cdi_EventProvider_context(inj1308, new ContextualProviderContext() {
public Annotation[] getQualifiers() {
return new Annotation[0];
}
public Class[] getTypeArguments() {
return new Class[] { LoginEvent.class };
}
});
com_ocpsoft_socialpm_gwt_client_local_EventsFactory_loggedInEvent(inj1349, inj1308.get());
final EventProvider inj1350 = new EventProvider();
org_jboss_errai_enterprise_client_cdi_EventProvider_context(inj1350, new ContextualProviderContext() {
public Annotation[] getQualifiers() {
return new Annotation[0];
}
public Class[] getTypeArguments() {
return new Class[] { HelloMessage.class };
}
});
com_ocpsoft_socialpm_gwt_client_local_EventsFactory_messageEvent(inj1349, inj1350.get());
final ProfileViewImpl inj1351 = new ProfileViewImpl(inj1346, inj1349);
final MessageBusProvider inj1329 = new MessageBusProvider();
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1351.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
final LoginViewImpl inj1342 = new LoginViewImpl(inj1346, inj1349);
final ClientFactoryImpl inj102 = new ClientFactoryImpl();
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(inj102, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(inj102, inj1346);
final HomeViewImpl inj120 = new HomeViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj120.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.shared.Response", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj120.response(message.get(Response.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_homeView(inj102, inj120);
final LoginViewImpl inj121 = new LoginViewImpl(inj1346, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_loginView(inj102, inj121);
final ProfileViewImpl inj119 = new ProfileViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj119.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_viewProfileView(inj102, inj119);
final AppActivityMapper inj1343 = new AppActivityMapper(inj102);
final ClientFactoryImpl inj1344 = new ClientFactoryImpl();
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(inj1344, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(inj1344, inj1346);
final HomeViewImpl inj1355 = new HomeViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1355.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.shared.Response", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1355.response(message.get(Response.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_homeView(inj1344, inj1355);
final LoginViewImpl inj1356 = new LoginViewImpl(inj1346, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_loginView(inj1344, inj1356);
final ProfileViewImpl inj1357 = new ProfileViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1357.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_viewProfileView(inj1344, inj1357);
final HomeViewImpl inj1345 = new HomeViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.shared.Response", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1345.response(message.get(Response.class, CDIProtocol.BeanReference));
}
}
});
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1345.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
final App inj1359 = new App();
final ClientFactoryImpl inj1360 = new ClientFactoryImpl();
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(inj1360, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(inj1360, inj1346);
final HomeViewImpl inj1361 = new HomeViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1361.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.shared.Response", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1361.response(message.get(Response.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_homeView(inj1360, inj1361);
final LoginViewImpl inj1362 = new LoginViewImpl(inj1346, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_loginView(inj1360, inj1362);
final ProfileViewImpl inj1363 = new ProfileViewImpl(inj1346, inj1349);
inj1329.get().subscribe("cdi.event:com.ocpsoft.socialpm.gwt.client.local.view.events.LoginEvent", new AbstractCDIEventCallback() {
public void callback(Message message) {
Set<String> msgQualifiers = message.get(Set.class, CDIProtocol.Qualifiers);
if (qualifiers.equals(msgQualifiers) || ((msgQualifiers == null) && qualifiers.isEmpty())) {
inj1363.onLogin(message.get(LoginEvent.class, CDIProtocol.BeanReference));
}
}
});
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_viewProfileView(inj1360, inj1363);
com_ocpsoft_socialpm_gwt_client_local_App_clientFactory(inj1359, inj1360);
com_ocpsoft_socialpm_gwt_client_local_App_historyMapper(inj1359, inj1348);
com_ocpsoft_socialpm_gwt_client_local_App_activityMapper(inj1359, inj1343);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(inj1360, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(inj1360, inj1346);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_eventFactory(inj1344, inj1349);
com_ocpsoft_socialpm_gwt_client_local_ClientFactoryImpl_serviceFactory(inj1344, inj1346);
inj1359.setup();
return ctx;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment