com.github.vfss3.operations.MD5HashGetter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vfs-s3-with-awssdk-v1 Show documentation
Show all versions of vfs-s3-with-awssdk-v1 Show documentation
Amazon S3 driver for VFS (Apache Commons Virtual File System)
The newest version!
package com.github.vfss3.operations;
import com.github.vfss3.S3FileObject;
import org.apache.commons.vfs2.FileSystemException;
/**
* @author Alexey Abashev
*/
public class MD5HashGetter implements IMD5HashGetter {
private final S3FileObject file;
/**
* @param file
*/
public MD5HashGetter(S3FileObject file) {
this.file = file;
}
/* (non-Javadoc)
* @see com.intridea.io.vfs.operations.IMD5HashGetter#getMD5Hash()
*/
@Override
public String getMD5Hash() throws FileSystemException {
return file.getMD5Hash().orElse(null);
}
/* (non-Javadoc)
* @see org.apache.commons.vfs.operations.FileOperation#process()
*/
@Override
public void process() throws FileSystemException {
// Do nothing
}
}