KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > avalon > phoenix > components > deployer > installer > FileDigest


1 package org.apache.avalon.phoenix.components.deployer.installer;
2
3 import java.io.File JavaDoc;
4
5 /**
6  * FileDigest holds file deployment information. Information
7  * used to verify if file was modified since deployment.
8  *
9  * @version $Revision: 1.2 $ $Date: 2002/07/26 09:49:20 $
10  */

11 public class FileDigest
12 {
13     private final File JavaDoc m_file;
14
15     private final long m_checksum;
16
17     /** Create a new FileDigest object.
18      *
19      * @param file the file.
20      * @param checksum the checksum value of the file.
21      */

22     public FileDigest( final File JavaDoc file, final long checksum )
23     {
24         m_file = file;
25         m_checksum = checksum;
26     }
27
28     /** Retrieve the file.
29      *
30      * @return the file.
31      */

32     public File JavaDoc getFile()
33     {
34         return m_file;
35     }
36
37     /** Retrieve the checksum calculated at deployment time.
38      *
39      * @return the checksum value.
40      */

41     public long getChecksum()
42     {
43         return m_checksum;
44     }
45 }
46
47
Popular Tags