package com.avg.zaap.crashlibrary.publish.packer;

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

/**
 * Implementation of factory interface used in {@link BinPacker}.
 * Created by marek.osvald on 18.4.2016.
 */
public class BinPackerFactory implements IBinPackerFactory {
    @Override
    public File getFile(String path) {
        return new File(path);
    }

    @Override
    public FileOutputStream getFileOutputStream(File output) throws FileNotFoundException {
        return new FileOutputStream(output);
    }

    @Override
    public FileInputStream getFileInputStream(File input) throws FileNotFoundException {
        return new FileInputStream(input);
    }

    @Override
    public FileInputStream getFileInputStream(String path) throws FileNotFoundException {
        return new FileInputStream(path);
    }
}
