Skip to main content
summaryrefslogtreecommitdiffstats
blob: b9b325152d3b080b6eaf2be86500ea4f23d4ef52 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package org.eclipse.osee.ote.rest.client;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;

import org.eclipse.osee.framework.jdk.core.util.ChecksumUtil;

public class OTECacheItem {
   private File file;
   private String md5;
   
   public OTECacheItem(File file, String md5){
      this.file = file;
      this.md5 = md5;
   }
   
   public OTECacheItem(File file) throws FileNotFoundException, Exception{
      this.file = file;
      md5 = ChecksumUtil.createChecksumAsString(new FileInputStream(file), "MD5");
   }
   
   public File getFile() {
      return file;
   }
   
   public String getMd5() {
      return md5;
   }
   
}

Back to the top