public class Utils extends Object
Constructor and Description |
---|
Utils() |
Modifier and Type | Method and Description |
---|---|
static String |
filterEndLines(String str)
Filter characters #13 (CR) from the specified String
|
static BaseDocument |
loadDocument(String text) |
static NodeList |
parseFragment(String text) |
static void |
replaceDocument(Document doc,
String newDoc) |
static void |
replaceDocument(Document doc,
String newDoc,
String prefixMark)
This method update document in editor after change in beans hierarchy.
|
public static void replaceDocument(Document doc, String newDoc, String prefixMark) throws BadLocationException
doc
- original documentnewDoc
- new value of whole documentprefixMark
- - beginning part of the document before this mark should be preservedBadLocationException
public static void replaceDocument(Document doc, String newDoc) throws BadLocationException
BadLocationException
public static String filterEndLines(String str)
str
- original stringpublic static BaseDocument loadDocument(String text) throws IOException
IOException
public static NodeList parseFragment(String text) throws IOException
IOException