|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.Dictionary<K,V>
java.util.Hashtable<Object,Object>
java.util.Properties
edu.rice.cs.util.MD5ChecksumProperties
public class MD5ChecksumProperties
Create a property file with MD5 checksums
| Field Summary | |
|---|---|
static int |
BUFFER_SIZE
|
| Fields inherited from class java.util.Properties |
|---|
defaults |
| Constructor Summary | |
|---|---|
MD5ChecksumProperties()
|
|
MD5ChecksumProperties(Properties p)
|
|
| Method Summary | |
|---|---|
boolean |
addMD5(File f)
Add the MD5 checksum for the data in the input stream to the properties, using the name of the file as key. |
boolean |
addMD5(File f,
OutputStream os)
Add the MD5 checksum for the data in the input stream to the properties, using the name of the file as key. |
boolean |
addMD5(String key,
byte[] b)
Add the MD5 checksum for the data in the byte array to the properties, using the specified key. |
boolean |
addMD5(String key,
byte[] b,
OutputStream os)
Add the MD5 checksum for the data in the byte array to the properties, using the specified key. |
boolean |
addMD5(String key,
File f)
Add the MD5 checksum for the data in the file to the properties, using the specified key. |
boolean |
addMD5(String key,
File f,
OutputStream os)
Add the MD5 checksum for the data in the file to the properties, using the specified key. |
boolean |
addMD5(String key,
InputStream is)
Add the MD5 checksum for the data in the input stream to the properties, using the specified key. |
boolean |
addMD5(String key,
InputStream is,
OutputStream os)
Add the MD5 checksum for the data in the input stream to the properties, using the specified key. |
static byte[] |
getMD5(byte[] b)
|
static byte[] |
getMD5(File f)
|
static byte[] |
getMD5(InputStream is)
Return the MD5 checksum for the data in the stream |
static byte[] |
getMD5(InputStream is,
OutputStream os)
Return the MD5 checksum for the data in the stream, while copying the data into the output stream. |
static String |
getMD5String(byte[] b)
|
static String |
getMD5String(File f)
|
static String |
getMD5String(InputStream is)
Return the MD5 checksum as string for the data in the stream. |
static String |
getMD5String(InputStream is,
OutputStream os)
Return the MD5 checksum as string for the data in the stream, while copying the data into the output stream. |
static void |
main(String[] args)
Main method. |
| Methods inherited from class java.util.Properties |
|---|
getProperty, getProperty, list, list, load, load, loadFromXML, propertyNames, save, setProperty, store, store, storeToXML, storeToXML, stringPropertyNames |
| Methods inherited from class java.util.Hashtable |
|---|
clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keys, keySet, put, putAll, rehash, remove, size, toString, values |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int BUFFER_SIZE
| Constructor Detail |
|---|
public MD5ChecksumProperties()
public MD5ChecksumProperties(Properties p)
| Method Detail |
|---|
public static byte[] getMD5(InputStream is,
OutputStream os)
throws IOException
is - input streamos - output stream (or null if no copying desired)
IOException
public static byte[] getMD5(InputStream is)
throws IOException
is - input stream
IOException
public static String getMD5String(InputStream is,
OutputStream os)
throws IOException
is - input streamos - output stream (or null if no copying desired)
IOException
public static String getMD5String(InputStream is)
throws IOException
is - input stream
IOException
public static byte[] getMD5(File f)
throws IOException
IOException
public static String getMD5String(File f)
throws IOException
IOException
public static byte[] getMD5(byte[] b)
throws IOException
IOException
public static String getMD5String(byte[] b)
throws IOException
IOException
public boolean addMD5(String key,
InputStream is,
OutputStream os)
throws IOException
key - key to store the checksum underis - input stream with the dataos - output stream to copy to (or null if not wanted)
IOException
public boolean addMD5(String key,
InputStream is)
throws IOException
key - key to store the checksum underis - input stream with the data
IOException
public boolean addMD5(String key,
File f,
OutputStream os)
throws IOException
key - key to store the checksum underf - file with the dataos - output stream to copy to (or null if not wanted)
IOException
public boolean addMD5(String key,
File f)
throws IOException
key - key to store the checksum underf - file with the data
IOException
public boolean addMD5(String key,
byte[] b,
OutputStream os)
throws IOException
key - key to store the checksum underb - byte array with the dataos - output stream to copy to (or null if not wanted)
IOException
public boolean addMD5(String key,
byte[] b)
throws IOException
key - key to store the checksum underb - byte array with the data
IOException
public boolean addMD5(File f,
OutputStream os)
throws IOException
f - file with the dataos - output stream to copy to (or null if not wanted)
IOException
public boolean addMD5(File f)
throws IOException
f - file with the data
IOException
public static void main(String[] args)
throws IOException
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||