How do I inject managers into my plugin?

How do I inject managers into my plugin?

You can inject manager objects into your plugin through setter based injection. Managers in Bamboo provide various services that's available to the application.

For example, if you want to inject BuildResultsSummaryManager into your plugin, you can add:

private BuildResultsSummaryManager buildResultsSummaryManager;

public void setBuildResultsSummaryManager(final BuildResultsSummaryManager buildResultsSummaryManager)
{
    this.buildResultsSummaryManager = buildResultsSummaryManager;
}

Spring will search for the bean named "buildResultsSummaryManager" and call the setter, passing in the manager.

Was this page helpful?

Have a question about this article?

See questions about this article

Powered by Confluence and Scroll Viewport