public class DataFileUtils
extends java.lang.Object
| Constructor and Description |
|---|
DataFileUtils() |
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
fedoraXMLHashFormat(byte[] data) |
static java.lang.String |
format(byte[] document) |
static java.lang.String |
format(org.w3c.dom.Document doc) |
static org.w3c.dom.Document |
getDocumentFromFile(java.io.File file) |
static java.lang.String |
getHash(byte[] data) |
static byte[] |
loadFile(java.io.File file) |
static byte[] |
loadFile(java.lang.String filename) |
static void |
saveDocument(java.lang.String filename,
byte[] document) |
static void |
saveDocument(java.lang.String filename,
org.w3c.dom.Document doc) |
public static org.w3c.dom.Document getDocumentFromFile(java.io.File file)
throws java.lang.Exception
java.lang.Exceptionpublic static byte[] loadFile(java.lang.String filename)
throws java.lang.Exception
java.lang.Exceptionpublic static byte[] loadFile(java.io.File file)
throws java.lang.Exception
java.lang.Exceptionpublic static void saveDocument(java.lang.String filename,
byte[] document)
throws java.lang.Exception
java.lang.Exceptionpublic static void saveDocument(java.lang.String filename,
org.w3c.dom.Document doc)
throws java.lang.Exception
java.lang.Exceptionpublic static java.lang.String format(org.w3c.dom.Document doc)
public static java.lang.String format(byte[] document)
throws java.lang.Exception
java.lang.Exceptionpublic static byte[] fedoraXMLHashFormat(byte[] data)
throws java.lang.Exception
java.lang.Exceptionpublic static java.lang.String getHash(byte[] data)
throws java.security.NoSuchAlgorithmException
java.security.NoSuchAlgorithmExceptionCopyright © 2014 DuraSpace. All Rights Reserved.