@EBean(scope = Scope.Singleton) public class SomeSingleton { @RootContext public Context context; /* * Should not be injected (singleton) */ @ViewById public View myTextView; @Bean public BeanWithView beanWithView; }
@EActivity @Fullscreen @WindowFeature({ Window.FEATURE_NO_TITLE, Window.FEATURE_INDETERMINATE_PROGRESS }) public class WindowFeatureActivity extends Activity { }
@EActivity @OptionsMenu(R.menu.my_menu3) public class OptionsMenuSubActivity extends OptionsMenuActivity { // CHECKSTYLE:OFF @OptionsMenuItem MenuItem menu_settings; // CHECKSTYLE:ON }
@EActivity public class AfterInjectActivity extends Activity { public boolean afterInjectCalled = false; public boolean notificationManagerNullAfterInject = true; @SystemService NotificationManager notificationManager; @AfterInject void afterInject() { afterInjectCalled = true; notificationManagerNullAfterInject = notificationManager == null; } }
@EActivity public class InstanceStateAfterInjectActivity extends Activity { @InstanceState int instanceField = -1; int restoredInAfterInject; @AfterInject void afterInject() { restoredInAfterInject = instanceField; } }
@PreferenceHeaders(R.xml.headers) @EActivity public class PreferenceHeadersActivity extends PreferenceActivity { List<Header> headers; @Override public void onBuildHeaders(List<Header> target) { headers = target; super.onBuildHeaders(target); } }
@EFragment public class GenericFragmentArguments<S extends Serializable & Closeable, P extends Account> extends Fragment { @FragmentArg S[] serializableArray; @FragmentArg P[] parcelableArray; @FragmentArg S serializable; @FragmentArg P parcelable; }
@EApplication public class SampleRoboApplication extends Application { @Bean public EmptyDependency someDependency; }
@EBean public class BeanWithSupportFragments { @FragmentById public MySupportFragment mySupportFragment; @FragmentById(R.id.mySupportFragment) public MySupportFragment mySupportFragment2; @FragmentByTag public MySupportFragment mySupportFragmentTag; @FragmentByTag("mySupportFragmentTag") public MySupportFragment mySupportFragmentTag2; }
@SeekBarTouchStart(R.id.seekBar2) @SeekBarProgressChange(R.id.seekBar2) @SeekBarTouchStop(R.id.seekBar2) void m8(SeekBar seekBar) { }
@ReceiverAction(actions = ACTION_EXTRA_PARAMETER_TEST) public void onExtraParameterAction(@ReceiverAction.Extra(EXTRA_ARG_NAME1) String thisIsAParameter) { extraParameterActionReceived = true; extraParameterActionValue = thisIsAParameter; }
@EBean public class BeanWithFragments { @FragmentById public MyFragment myFragment; @FragmentById(R.id.myFragment) public MyFragment myFragment2; @FragmentByTag public MyFragment myFragmentTag; @FragmentByTag("myFragmentTag") public MyFragment myFragmentTag2; }
@ReceiverAction(actions = ACTION_EXTRA_INTENT_PARAMETERS_TEST) public void onIntentParametersAction(Intent originalIntent, @ReceiverAction.Extra Intent extraIntent) { this.originalIntent = originalIntent; this.extraIntent = extraIntent; } }