FileDao.java 643 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10
package at.ac.tuwien.sepm.assignment.individual.persistence;

import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;

public interface FileDao {
    /**
     * Used for saving files on the local file system
     * @param file file to save
11
     * @throws IOException if something goes wrong with saving the file
12 13
     */
    void save(MultipartFile file) throws IOException;
14 15 16 17 18 19 20

    /**
     * Used for deleting file from the local filesystem
     * @param fileName file to delete
     * @throws IOException if something goes wrong with deleting the file
     */
    void delete(String fileName) throws IOException;
21
}