use of com.google.gwt.inject.client.assistedinject.GinFactoryModuleBuilder in project che by eclipse.
the class EditorPreferencesModule method configure.
@Override
protected void configure() {
GinMultibinder.newSetBinder(binder(), PreferencePagePresenter.class).addBinding().to(EditorPreferencePresenter.class);
bind(EditorPreferenceView.class).to(EditorPreferenceViewImpl.class);
bind(KeymapsPreferenceView.class).to(KeymapsPreferenceViewImpl.class);
bind(KeyMapsPreferencePresenter.class);
install(new GinFactoryModuleBuilder().implement(EditorPreferenceSection.class, EditorPropertiesSectionPresenter.class).build(EditorPreferenceSectionFactory.class));
GinMultibinder<EditorPropertiesSection> editorPropertiesSectionBinder = GinMultibinder.newSetBinder(binder(), EditorPropertiesSection.class);
editorPropertiesSectionBinder.addBinding().to(TabsPropertiesSection.class);
editorPropertiesSectionBinder.addBinding().to(LanguageToolsPropertiesSection.class);
editorPropertiesSectionBinder.addBinding().to(TypingPropertiesSection.class);
editorPropertiesSectionBinder.addBinding().to(WhiteSpacesPropertiesSection.class);
editorPropertiesSectionBinder.addBinding().to(RulersPropertiesSection.class);
}
use of com.google.gwt.inject.client.assistedinject.GinFactoryModuleBuilder in project rstudio by rstudio.
the class RStudioGinModule method configure.
@Override
protected void configure() {
bind(EventBus.class).in(Singleton.class);
bind(Session.class).in(Singleton.class);
bind(Projects.class).in(Singleton.class);
bind(Satellite.class).in(Singleton.class);
bind(SatelliteManager.class).in(Singleton.class);
bind(AskPassManager.class).in(Singleton.class);
bind(ProfilerPresenter.class).in(Singleton.class);
bind(WorkbenchContext.class).asEagerSingleton();
bind(DependencyManager.class).asEagerSingleton();
bind(WorkbenchListManager.class).asEagerSingleton();
bind(ApplicationQuit.class).asEagerSingleton();
bind(ApplicationInterrupt.class).asEagerSingleton();
bind(ApplicationVisibility.class).asEagerSingleton();
bind(ClientStateUpdater.class).asEagerSingleton();
bind(ConsoleProcessFactory.class).asEagerSingleton();
bind(RnwWeaveRegistry.class).asEagerSingleton();
bind(LatexProgramRegistry.class).asEagerSingleton();
bind(Commands.class).in(Singleton.class);
bind(DefaultCRANMirror.class).in(Singleton.class);
bind(ChooseFile.class).in(Singleton.class);
bind(ConsoleDispatcher.class).in(Singleton.class);
bind(FileTypeCommands.class).in(Singleton.class);
bind(Synctex.class).in(Singleton.class);
bind(PDFViewer.class).in(Singleton.class);
bind(HTMLPreview.class).in(Singleton.class);
bind(ShinyApplication.class).in(Singleton.class);
bind(BreakpointManager.class).asEagerSingleton();
bind(DebugCommander.class).asEagerSingleton();
bind(ShortcutViewer.class).asEagerSingleton();
bind(RSConnect.class).asEagerSingleton();
bind(RmdOutput.class).in(Singleton.class);
bind(HelpStrategy.class).in(Singleton.class);
bind(RSAccountConnector.class).in(Singleton.class);
bind(PlotPublishMRUList.class).asEagerSingleton();
bind(SourceWindowManager.class).in(Singleton.class);
bind(SourceWindow.class).in(Singleton.class);
bind(EditorCommandManager.class).in(Singleton.class);
bind(UserCommandManager.class).in(Singleton.class);
bind(ApplicationCommandManager.class).in(Singleton.class);
bind(CodeSearchLauncher.class).in(Singleton.class);
bind(AddinsMRUList.class).asEagerSingleton();
bind(AceEditorCommandDispatcher.class).asEagerSingleton();
bind(DataImportPresenter.class).in(Singleton.class);
bind(MathJaxLoader.class).asEagerSingleton();
bind(ProjectTemplateRegistryProvider.class).in(Singleton.class);
bind(PackageProvidedExtensions.class).asEagerSingleton();
bind(ApplicationView.class).to(ApplicationWindow.class).in(Singleton.class);
bind(VCSApplicationView.class).to(VCSApplicationWindow.class).in(Singleton.class);
bind(ReviewPresenter.class).to(ReviewPresenterImpl.class);
bind(HTMLPreviewApplicationView.class).to(HTMLPreviewApplicationWindow.class);
bind(ShinyApplicationView.class).to(ShinyApplicationWindow.class);
bind(RmdOutputView.class).to(RmdOutputWindow.class);
bind(SourceSatelliteView.class).to(SourceSatelliteWindow.class);
bind(Server.class).to(RemoteServer.class);
bind(WorkbenchServerOperations.class).to(RemoteServer.class);
bind(EditingTargetSource.class).to(EditingTargetSource.Impl.class);
// Bind workbench views
// eager loaded
bindPane("Console", ConsolePane.class);
bind(Source.Display.class).to(SourcePane.class);
bind(TerminalTabPresenter.Display.class).to(TerminalPane.class);
bind(History.Display.class).to(HistoryPane.class);
bind(Data.Display.class).to(DataPane.class);
bind(Files.Display.class).to(FilesPane.class);
bind(Plots.Display.class).to(PlotsPane.class);
bind(Packages.Display.class).to(PackagesPane.class);
bind(Help.Display.class).to(HelpPane.class);
bind(Edit.Display.class).to(EditView.class);
bind(GitPresenter.Display.class).to(GitPane.class);
bind(SVNPresenter.Display.class).to(SVNPane.class);
bind(BuildPresenter.Display.class).to(BuildPane.class);
bind(Presentation.Display.class).to(PresentationPane.class);
bind(EnvironmentPresenter.Display.class).to(EnvironmentPane.class);
bind(ViewerPresenter.Display.class).to(ViewerPane.class);
bind(ConnectionsPresenter.Display.class).to(ConnectionsPane.class);
bind(Ignore.Display.class).to(IgnoreDialog.class);
bind(FindOutputPresenter.Display.class).to(FindOutputPane.class);
bind(SourceCppOutputPresenter.Display.class).to(SourceCppOutputPane.class);
bind(MarkersOutputPresenter.Display.class).to(MarkersOutputPane.class);
bindTab("History", HistoryTab.class);
bindTab("Data", DataTab.class);
bindTab("Files", FilesTab.class);
bindTab("Plots", PlotsTab.class);
bindTab("Packages", PackagesTab.class);
bindTab("Help", HelpTab.class);
bindTab("VCS", VCSTab.class);
bindTab("Build", BuildTab.class);
bindTab("Presentation", PresentationTab.class);
bindTab("Environment", EnvironmentTab.class);
bindTab("Viewer", ViewerTab.class);
bindTab("Connections", ConnectionsTab.class);
bindTab("Compile PDF", CompilePdfOutputTab.class);
bindTab("R Markdown", RenderRmdOutputTab.class);
bindTab("Find", FindOutputTab.class);
bindTab("Source Cpp", SourceCppOutputTab.class);
bindTab("Deploy", RSConnectDeployOutputTab.class);
bindTab("Markers", MarkersOutputTab.class);
bindTab("Terminal", TerminalTab.class);
bind(Shell.Display.class).to(ShellPane.class);
bind(HelpSearch.Display.class).to(HelpSearchWidget.class);
bind(CodeSearch.Display.class).to(CodeSearchWidget.class);
bind(GitReviewPresenter.Display.class).to(GitReviewPanel.class);
bind(SVNReviewPresenter.Display.class).to(SVNReviewPanel.class);
bind(LineTablePresenter.Display.class).to(LineTableView.class);
bind(HistoryPresenter.DisplayBuilder.class).to(HistoryPanel.Builder.class);
bind(HTMLPreviewPresenter.Display.class).to(HTMLPreviewPanel.class);
bind(ShinyApplicationPresenter.Display.class).to(ShinyApplicationPanel.class);
bind(RmdOutputPresenter.Display.class).to(RmdOutputPanel.class);
bind(GlobalDisplay.class).to(DefaultGlobalDisplay.class).in(Singleton.class);
bind(ApplicationServerOperations.class).to(RemoteServer.class);
bind(ChooseFileServerOperations.class).to(RemoteServer.class);
bind(CodeToolsServerOperations.class).to(RemoteServer.class);
bind(ConsoleServerOperations.class).to(RemoteServer.class);
bind(SourceServerOperations.class).to(RemoteServer.class);
bind(DataServerOperations.class).to(RemoteServer.class);
bind(FilesServerOperations.class).to(RemoteServer.class);
bind(HistoryServerOperations.class).to(RemoteServer.class);
bind(PlotsServerOperations.class).to(RemoteServer.class);
bind(PackagesServerOperations.class).to(RemoteServer.class);
bind(HelpServerOperations.class).to(RemoteServer.class);
bind(EditServerOperations.class).to(RemoteServer.class);
bind(MirrorsServerOperations.class).to(RemoteServer.class);
bind(VCSServerOperations.class).to(RemoteServer.class);
bind(GitServerOperations.class).to(RemoteServer.class);
bind(SVNServerOperations.class).to(RemoteServer.class);
bind(PrefsServerOperations.class).to(RemoteServer.class);
bind(ProjectsServerOperations.class).to(RemoteServer.class);
bind(CodeSearchServerOperations.class).to(RemoteServer.class);
bind(WorkbenchListsServerOperations.class).to(RemoteServer.class);
bind(CryptoServerOperations.class).to(RemoteServer.class);
bind(TexServerOperations.class).to(RemoteServer.class);
bind(SpellingServerOperations.class).to(RemoteServer.class);
bind(CompilePdfServerOperations.class).to(RemoteServer.class);
bind(FindInFilesServerOperations.class).to(RemoteServer.class);
bind(SynctexServerOperations.class).to(RemoteServer.class);
bind(HTMLPreviewServerOperations.class).to(RemoteServer.class);
bind(ShinyServerOperations.class).to(RemoteServer.class);
bind(RSConnectServerOperations.class).to(RemoteServer.class);
bind(RPubsServerOperations.class).to(RemoteServer.class);
bind(BuildServerOperations.class).to(RemoteServer.class);
bind(PresentationServerOperations.class).to(RemoteServer.class);
bind(EnvironmentServerOperations.class).to(RemoteServer.class);
bind(DebuggingServerOperations.class).to(RemoteServer.class);
bind(MetaServerOperations.class).to(RemoteServer.class);
bind(ViewerServerOperations.class).to(RemoteServer.class);
bind(ConnectionsServerOperations.class).to(RemoteServer.class);
bind(ProfilerServerOperations.class).to(RemoteServer.class);
bind(RMarkdownServerOperations.class).to(RemoteServer.class);
bind(DependencyServerOperations.class).to(RemoteServer.class);
bind(PackratServerOperations.class).to(RemoteServer.class);
bind(CppServerOperations.class).to(RemoteServer.class);
bind(MarkersServerOperations.class).to(RemoteServer.class);
bind(LintServerOperations.class).to(RemoteServer.class);
bind(RoxygenServerOperations.class).to(RemoteServer.class);
bind(SnippetServerOperations.class).to(RemoteServer.class);
bind(AddinsServerOperations.class).to(RemoteServer.class);
bind(ProjectTemplateServerOperations.class).to(RemoteServer.class);
bind(WorkbenchMainView.class).to(WorkbenchScreen.class);
bind(DocDisplay.class).to(AceEditor.class);
install(new GinFactoryModuleBuilder().implement(CompileOutputPaneDisplay.class, CompileOutputPane.class).build(CompileOutputPaneFactory.class));
bind(ChunkWindowManager.class).in(Singleton.class);
bind(ChunkSatelliteView.class).to(ChunkSatelliteWindow.class);
bind(RStudioAPI.class).asEagerSingleton();
bind(RStudioAPIServerOperations.class).to(RemoteServer.class);
}
use of com.google.gwt.inject.client.assistedinject.GinFactoryModuleBuilder in project che by eclipse.
the class ProjectImportModule method configure.
@Override
protected void configure() {
bind(ProjectImportersServiceClient.class).to(ProjectImportersServiceClientImpl.class).in(Singleton.class);
GinMultibinder.newSetBinder(binder(), ImportWizardRegistrar.class).addBinding().to(ZipImportWizardRegistrar.class);
bind(ImportWizardRegistry.class).to(ImportWizardRegistryImpl.class).in(Singleton.class);
install(new GinFactoryModuleBuilder().build(ImportWizardFactory.class));
bind(ProjectNotificationSubscriber.class).to(ProjectNotificationSubscriberImpl.class).in(Singleton.class);
install(new GinFactoryModuleBuilder().implement(ProjectNotificationSubscriber.class, ProjectNotificationSubscriberImpl.class).build(ImportProjectNotificationSubscriberFactory.class));
}
use of com.google.gwt.inject.client.assistedinject.GinFactoryModuleBuilder in project che by eclipse.
the class JavaGinModule method configure.
/** {@inheritDoc} */
@Override
protected void configure() {
GinMapBinder<String, ProposalAction> proposalActionMapBinder = GinMapBinder.newMapBinder(binder(), String.class, ProposalAction.class);
proposalActionMapBinder.addBinding(JAVA_ORGANIZE_IMPORT_ID).to(OrganizeImportsAction.class);
bind(NewJavaSourceFileView.class).to(NewJavaSourceFileViewImpl.class).in(Singleton.class);
bind(QuickDocumentation.class).to(QuickDocPresenter.class).in(Singleton.class);
bind(JavaNavigationService.class).to(JavaNavigationServiceImpl.class);
bind(JavaClasspathServiceClient.class).to(JavaClasspathServiceClientImpl.class);
bind(JavaSearchService.class).to(JavaSearchServiceWS.class);
GinMultibinder.newSetBinder(binder(), NodeInterceptor.class).addBinding().to(TestFolderDecorator.class);
GinMultibinder.newSetBinder(binder(), NodeInterceptor.class).addBinding().to(JavaPackageConnector.class);
GinMultibinder.newSetBinder(binder(), NodeIconProvider.class).addBinding().to(SourceFolderDecorator.class);
GinMultibinder.newSetBinder(binder(), NodeInterceptor.class).addBinding().to(LibraryNodeProvider.class);
GinMultibinder.newSetBinder(binder(), ResourceInterceptor.class).addBinding().to(SourceFolderInterceptor.class);
GinMultibinder.newSetBinder(binder(), ResourceInterceptor.class).addBinding().to(ClassInterceptor.class);
GinMultibinder.newSetBinder(binder(), CommandType.class).addBinding().to(JavaCommandType.class);
GinMapBinder<String, FqnProvider> fqnProviders = GinMapBinder.newMapBinder(binder(), String.class, FqnProvider.class);
fqnProviders.addBinding("maven").to(JavaFqnProvider.class);
install(new GinFactoryModuleBuilder().build(JavaNodeFactory.class));
install(new GinFactoryModuleBuilder().implement(PropertyWidget.class, PropertyWidgetImpl.class).build(PropertyWidgetFactory.class));
install(new GinFactoryModuleBuilder().build(NodeFactory.class));
install(new GinFactoryModuleBuilder().build(org.eclipse.che.ide.ext.java.client.navigation.factory.NodeFactory.class));
GinMultibinder<PreferencePagePresenter> settingsBinder = GinMultibinder.newSetBinder(binder(), PreferencePagePresenter.class);
settingsBinder.addBinding().to(JavaCompilerPreferencePresenter.class);
bind(PreferencesManager.class).annotatedWith(JavaCompilerPreferenceManager.class).to(ErrorsWarningsPreferenceManager.class);
GinMultibinder.newSetBinder(binder(), PreferencesManager.class).addBinding().to(ErrorsWarningsPreferenceManager.class);
GinMultibinder.newSetBinder(binder(), Macro.class).addBinding().to(ClasspathMacro.class);
GinMultibinder.newSetBinder(binder(), Macro.class).addBinding().to(OutputDirMacro.class);
GinMultibinder.newSetBinder(binder(), Macro.class).addBinding().to(MainClassMacro.class);
GinMultibinder.newSetBinder(binder(), Macro.class).addBinding().to(SourcepathMacro.class);
GinMultibinder.newSetBinder(binder(), Macro.class).addBinding().to(CurrentClassFQN_Macro.class);
GinMultibinder.newSetBinder(binder(), ClasspathPagePresenter.class).addBinding().to(LibEntryPresenter.class);
GinMultibinder.newSetBinder(binder(), ClasspathPagePresenter.class).addBinding().to(SourceEntryPresenter.class);
GinMultibinder.newSetBinder(binder(), RenamingSupport.class).addBinding().to(JavaSourceRenameValidator.class);
}
use of com.google.gwt.inject.client.assistedinject.GinFactoryModuleBuilder in project che by eclipse.
the class UiModule method configure.
@Override
protected void configure() {
bind(IconRegistry.class).to(IconRegistryImpl.class).in(Singleton.class);
GinMapBinder<String, Component> componentsBinder = GinMapBinder.newMapBinder(binder(), String.class, Component.class);
componentsBinder.addBinding("DefaultIconsComponent").to(DefaultIconsComponent.class);
componentsBinder.addBinding("FontAwesomeInjector").to(FontAwesomeInjector.class);
// core UI components
install(new GinFactoryModuleBuilder().implement(WorkBenchPartController.class, WorkBenchPartControllerImpl.class).build(WorkBenchControllerFactory.class));
bind(WorkspaceView.class).to(WorkspaceViewImpl.class).in(Singleton.class);
bind(MainMenuView.class).to(MainMenuViewImpl.class).in(Singleton.class);
bind(ToolbarView.class).to(ToolbarViewImpl.class);
bind(ToolbarPresenter.class).annotatedWith(MainToolbar.class).to(ToolbarPresenter.class).in(Singleton.class);
// dialog factory
bind(MessageDialogFooter.class);
bind(MessageDialogView.class).to(MessageDialogViewImpl.class);
bind(ConfirmDialogFooter.class);
bind(ConfirmDialogView.class).to(ConfirmDialogViewImpl.class);
bind(ChoiceDialogFooter.class);
bind(ChoiceDialogView.class).to(ChoiceDialogViewImpl.class);
bind(InputDialogFooter.class);
bind(InputDialogView.class).to(InputDialogViewImpl.class);
install(new GinFactoryModuleBuilder().implement(MessageDialog.class, MessageDialogPresenter.class).implement(ConfirmDialog.class, ConfirmDialogPresenter.class).implement(ChoiceDialog.class, ChoiceDialogPresenter.class).implement(InputDialog.class, InputDialogPresenter.class).build(DialogFactory.class));
// drop down list widget
install(new GinFactoryModuleBuilder().implement(DropDownWidget.class, DropDownWidgetImpl.class).build(DropDownListFactory.class));
// multi-split panel
install(new GinFactoryModuleBuilder().implement(SubPanel.class, SubPanelPresenter.class).build(SubPanelFactory.class));
install(new GinFactoryModuleBuilder().implement(SubPanelView.class, SubPanelViewImpl.class).build(SubPanelViewFactory.class));
install(new GinFactoryModuleBuilder().implement(Tab.class, TabWidget.class).build(TabItemFactory.class));
// miscellaneous UI components
install(new GinFactoryModuleBuilder().implement(ConsoleButton.class, ConsoleButtonImpl.class).build(ConsoleButtonFactory.class));
bind(StatusPanelGroupView.class).to(StatusPanelGroupViewImpl.class).in(Singleton.class);
}
Aggregations