diff options
author | Daniel Gultsch <daniel.gultsch@rwth-aachen.de> | 2014-04-13 11:32:45 +0200 |
---|---|---|
committer | Daniel Gultsch <daniel.gultsch@rwth-aachen.de> | 2014-04-13 11:32:45 +0200 |
commit | 27d5966ac356fd10365d848332b127b0b8f417da (patch) | |
tree | eb98cb6d7fdcc79b5e405acadcef9d8bbcc1e2c8 /src/eu/siacs/conversations/xmpp/jingle/JingleFile.java | |
parent | 7b554f20013441e7c2a4f803870edfc9ca5d2cca (diff) |
more efficant way of calculating the sha1 sum. closing connections
Diffstat (limited to 'src/eu/siacs/conversations/xmpp/jingle/JingleFile.java')
-rw-r--r-- | src/eu/siacs/conversations/xmpp/jingle/JingleFile.java | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/xmpp/jingle/JingleFile.java b/src/eu/siacs/conversations/xmpp/jingle/JingleFile.java new file mode 100644 index 00000000..21cbd716 --- /dev/null +++ b/src/eu/siacs/conversations/xmpp/jingle/JingleFile.java @@ -0,0 +1,35 @@ +package eu.siacs.conversations.xmpp.jingle; + +import java.io.File; + +public class JingleFile extends File { + + private static final long serialVersionUID = 2247012619505115863L; + + private long expectedSize = 0; + private String sha1sum; + + public JingleFile(String path) { + super(path); + } + + public long getSize() { + return super.length(); + } + + public long getExpectedSize() { + return this.expectedSize; + } + + public void setExpectedSize(long size) { + this.expectedSize = size; + } + + public String getSha1Sum() { + return this.sha1sum; + } + + public void setSha1Sum(String sum) { + this.sha1sum = sum; + } +} |