com.dangdang.config.service.file.protocol.Protocol Maven / Gradle / Ivy
package com.dangdang.config.service.file.protocol;
import java.io.Closeable;
import com.dangdang.config.service.exception.InvalidPathException;
import com.dangdang.config.service.file.FileLocation;
import com.dangdang.config.service.file.FileConfigGroup;
/**
*
* @author Yuxuan Wang
*
*/
public interface Protocol extends Closeable {
/**
* Read data of file
*
* @param location
* @return
*/
byte[] read(FileLocation location) throws InvalidPathException;
/**
* Register watcher for the file
*
* @param location
* @param fileConfigGroup
*/
void watch(FileLocation location, FileConfigGroup fileConfigGroup) throws InvalidPathException;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy