|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fuin.serialver4j.base.Utils
public final class Utils
Helper class.
| Method Summary | |
|---|---|
static com.thoughtworks.xstream.XStream |
createConfiguredXStream()
Creates a ready initialized XStream instance. |
static String |
getContent(String str,
String beginTag,
String endTag)
Returns the content between the begin and the and tag. |
static long |
getLongContent(String str,
String beginTag,
String endTag)
Returns the content between the begin and the and tag as long value. |
static long |
getSerialVersionUID(Class<?> clasz)
Returns the serial version UID from a class. |
static ClassesHistory |
readFromFile(File file)
Reads the history from an XML file. |
static void |
writeToFile(File file,
ClassesHistory history)
Writes the history into an XML file. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static void writeToFile(File file,
ClassesHistory history)
throws IOException
file - Target file.history - History to serialize into XML.
IOException - Error writing the file.
public static ClassesHistory readFromFile(File file)
throws IOException
file - XML file to read.
IOException - Error reading the file.public static long getSerialVersionUID(Class<?> clasz)
clasz - Class with static serial version UID field.
serialVersionUID attribute.
public static String getContent(String str,
String beginTag,
String endTag)
throws ContentNotFoundException
str - Text to search within.beginTag - Start tag.endTag - End tag.
ContentNotFoundException - The content cannot be extracted.
public static long getLongContent(String str,
String beginTag,
String endTag)
throws ContentNotFoundException
str - Text to search within.beginTag - Start tag.endTag - End tag.
ContentNotFoundException - The content cannot be extracted.public static com.thoughtworks.xstream.XStream createConfiguredXStream()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||