class DefaultBeanFactory implements BeanFactory {

    @Override
    public WorkbenchPartPresenter newWorkbenchPart(final Menus menus,
                                                   final String title,
                                                   final IsWidget titleDecoration,
                                                   final PartDefinition definition,
                                                   final Class<? extends WorkbenchPartPresenter> partType) {
        final WorkbenchPartPresenter part = iocManager.lookupBean(partType).getInstance();

        part.setTitle(title);
        part.setMenus(menus);
        part.setTitleDecoration(titleDecoration);
        part.setDefinition(definition);

        return part;
    }

}