class ContainerCardPresenter {

    public void setup( final Container container ) {
        final LinkTitlePresenter linkTitlePresenter = presenterProvider.select( LinkTitlePresenter.class ).get();
        linkTitlePresenter.setup( container.getContainerName() != null ?
                                          container.getContainerName() :
                                          container.getContainerSpecId(),
                                  new Command() {
                                      @Override
                                      public void execute() {
                                          containerSpecSelectedEvent.fire( new ContainerSpecSelected( buildContainerSpecKey( container ) ) );
                                      }
                                  } );

        final InfoTitlePresenter infoTitlePresenter = presenterProvider.select( InfoTitlePresenter.class ).get();
        infoTitlePresenter.setup( container.getResolvedReleasedId() );

        final BodyPresenter bodyPresenter = presenterProvider.select( BodyPresenter.class ).get();
        bodyPresenter.setup( container.getMessages() );

        final FooterPresenter footerPresenter = presenterProvider.select( FooterPresenter.class ).get();
        footerPresenter.setup( container.getUrl(), container.getResolvedReleasedId().getVersion() );

        CardPresenter card = presenterProvider.select( CardPresenter.class ).get();
        card.addTitle( linkTitlePresenter );
        card.addTitle( infoTitlePresenter );
        card.addBody( bodyPresenter );
        card.addFooter( footerPresenter );

        view.setCard( card.getView() );
    }

    @Inject public  ContainerCardPresenter( final ManagedInstance<Object> presenterProvider,
                                   final org.kie.workbench.common.screens.server.management.client.container.status.card.ContainerCardPresenter.View view,
                                   final Event<ContainerSpecSelected> containerSpecSelectedEvent );

}