code: protected I_CmsContextMenuEntry transformSingleEntry(CmsContextMenuEntryBean bean, CmsUUID structureId) {
  
          String name = bean.getName();
          I_CmsContextMenuCommand command = null;
          if (CmsStringUtil.isNotEmptyOrWhitespaceOnly(name)) {
              command = getContextMenuCommands().get(name);
          }
          if (command instanceof I_CmsValidatingContextMenuCommand) {
              boolean ok = ((I_CmsValidatingContextMenuCommand)command).validate(bean);
              if (!ok) {
                  return null;
              }
          }
          CmsContextMenuEntry entry = new CmsContextMenuEntry(this, structureId, command);
          entry.setBean(bean);
          if (bean.hasSubMenu()) {
              entry.setSubMenu(transformEntries(bean.getSubMenu(), structureId));
          }
          return entry;
      }
docs: Creates a single context menu entry from a context menu entry bean.<p>
  
  @param bean the menu entry bean
  @param structureId the structure id
  
  @return the context menu for the given entry