- Timestamp:
- 2019-04-30T18:33:42+12:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/src/java/org/greenstone/gsdl3/util/GSXML.java
r32942 r33043 43 43 44 44 import org.greenstone.gsdl3.util.MyNodeList; 45 import org.greenstone.util.Misc; 46 45 47 /** various functions for extracting info out of GS XML */ 46 48 public class GSXML … … 1629 1631 } 1630 1632 1631 public static String elementToString(Element e, boolean indent) 1633 // pass in debugEncoding=true to investigate encoding issues. This function will then return non-basic ASCII characters in hex 1634 public static String elementToString(Element e, boolean indent, boolean debugEncoding) 1632 1635 { 1633 1636 String str = ""; … … 1647 1650 trans.transform(new DOMSource(e), new StreamResult(sw)); 1648 1651 str += sw.toString(); 1652 1653 // if debugging encoding issues, then encode unicode code pts as hex for all but non-alphanumeric and space/tab/newline chars 1654 if(debugEncoding) str = Misc.stringToHex(str); 1649 1655 } 1650 1656 catch (Exception ex) … … 1658 1664 } 1659 1665 1666 public static String elementToString(Element e, boolean indent) 1667 { 1668 return elementToString(e, indent, false); 1669 } 1670 1660 1671 public static ArrayList<String> getGroupsFromSecurityResponse(Element securityResponse) 1661 1672 {
Note:
See TracChangeset
for help on using the changeset viewer.