123456789101112131415161718192021222324252627 |
- package de.tudarmstadt.informatik.hostage.io;
- import java.io.IOException;
- import java.util.List;
- /**
- * Interface for a generic class that offers methods for read and write.
- * Is used to abstract the implementation details for String and Byte protocols.
- * @author Mihai Plasoianu
- *
- * @param <T>
- */
- public interface ReaderWriter<T> {
- /**
- * Method to read from a medium.
- * @return Returns the output.
- * @throws IOException
- */
- T read() throws IOException;
- /**
- * Method to write to a medium.
- * @param outputLine The input to write.
- * @throws IOException
- */
- void write(List<T> outputLine) throws IOException;
- }
|