public DocType build(DocumentType doctype) {
    String publicID = doctype.getPublicId();
    String systemID = doctype.getSystemId();
    String internalDTD = doctype.getInternalSubset();

    DocType docType = factory.docType(doctype.getName());
    docType.setPublicID(publicID);
    docType.setSystemID(systemID);
    docType.setInternalSubset(internalDTD);
    return docType;
  }
public DocType build(DocumentType doctype)