List of usage examples for org.springframework.stereotype Component getClass
@HotSpotIntrinsicCandidate public final native Class<?> getClass();
From source file:org.vaadin.spring.samples.mvp.ui.component.listener.TabSelectedListener.java
@Override // this is kind of hacky! // since all presenters are UI-scoped we need to call them into being before publishing events // that can be received and handled by them public void selectedTabChange(final SelectedTabChangeEvent event) { eventBus.publish(context.getBean(HeaderView.class), ControlsContext.empty()); // TODO RAS enable com.vaadin.ui.Component c = event.getTabSheet().getSelectedTab(); if (View.class.isAssignableFrom(c.getClass())) { View v = (View) c; SpringView springView = v.getClass().getAnnotation(SpringView.class); if (springView != null) { context.getBeansWithAnnotation(VaadinPresenter.class); eventBus.publish(this, new Screen(springView.name())); }// ww w . jav a2 s. co m } }