@Description( "This is a test" ) static class DescribedBean implements Bean { }
@Override public boolean equals(final Object obj) { if (obj == this) { return true; } if (obj instanceof BeanEntryCommand) { return beanEntry.equals(((BeanEntryCommand) obj).beanEntry); } return false; } }
@EagerSingleton @javax.inject.Named static class CItem extends SomeItem { static boolean initialized; public CItem() { initialized = true; } }
public Object getInstance() { return entry.getValue(); } };
@Override public Class<?> getScannableClass() { return entry.getImplementationClass(); }
public K getKey() { return entry.getKey(); }
@Provides @Parameters String[] arguments() { return new String[] { "Hello", "World" }; }
public String getDescription() { return bean.getDescription(); }
public Provider<V> getValue() { return entry.getProvider(); }
@Override public int hashCode() { return beanEntry.hashCode(); }
@Named @EagerSingleton static class DefaultB03 { static boolean initialized; @Inject void initialize() { initialized = true; } }
public T getValue() { return bean.getValue(); }
@Inject public CoreExportsProvider( PlexusContainer container, @Nullable CoreExports exports ) { if ( exports == null ) { this.exports = new CoreExports( CoreExtensionEntry.discoverFrom( container.getContainerRealm() ) ); } else { this.exports = exports; } }
public Class<T> getImplementationClass() { return bean.getImplementationClass(); }
@Named @EagerSingleton public class ObjectMapperInitializer { @Inject public ObjectMapperInitializer(@Named("siesta") javax.inject.Provider<ObjectMapper> mapperProvider) { ObjectMapper om = mapperProvider.get(); om.registerModule(new GuavaModule()); om.registerModule(new Jdk8Module()); } }
@Override public void add(BeanEntry<Named, WebResource> entry, WebResourceServiceImpl watcher) throws Exception { watcher.addResource(entry.getValue()); }
public class Ap3Help extends Help implements Ap3Command { @Inject @Nullable protected GlobalOptions globalOptions = new GlobalOptions(); @Override public void setArgs(String[] args) { //do nothing } }
public BeanEntryCommand(final BeanLocator beanLocator, final BeanEntry<?, Action> beanEntry) { super(beanEntry.getImplementationClass()); this.beanLocator = checkNotNull(beanLocator); this.beanEntry = checkNotNull(beanEntry); }
@Override public void remove(final BeanEntry<Named, EventAware> entry, final EventManagerImpl watcher) { watcher.unregister(entry.getValue()); } }