code: public static void require(Element ele, String expected) {
          String got;
          
          got = ele.getTagName();
          if (!expected.equals(ele.getTagName())) {
              throw new DomException("'" + expected + "' element expected, got '" + got + "'");
          }
      }
docs: --