class RegisteredDocumentsMenuBuilder implements MenuFactory.CustomMenuBuilder,
                                                       RegisteredDocumentsMenuView.Presenter {

    @Override
    public MenuItem build() {
        return new BaseMenuCustom<IsWidget>() {
            @Override
            public IsWidget build() {
                return ElementWrapperWidget.getWidget(view.getElement());
            }

            @Override
            public boolean isEnabled() {
                return view.isEnabled();
            }

            @Override
            public void setEnabled(final boolean enabled) {
                view.setEnabled(enabled);
            }
        };
    }

    @Inject public  RegisteredDocumentsMenuBuilder(final RegisteredDocumentsMenuView view,
                                          final ManagedInstance<DocumentMenuItem> documentMenuItemProvider);

}