class RegisteredDocumentsMenuBuilder implements MenuFactory.CustomMenuBuilder,
                                                       RegisteredDocumentsMenuView.Presenter {

    @Override
    public void onNewDocument() {
        if (isReadOnly) {
            return;
        }
        if (newDocumentCommand != null) {
            newDocumentCommand.execute();
        }
    }

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

}