timeBench.data.io.TemporalDatasetReader Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of timebench Show documentation
Show all versions of timebench Show documentation
TimeBench, a flexible, easy-to-use, and reusable software library written in Java that provides foundational data structures and algorithms for time- oriented data in Visual Analytics.
The newest version!
package timeBench.data.io;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
import prefuse.data.io.DataIOException;
import prefuse.data.parser.DataParseException;
import timeBench.data.TemporalDataException;
import timeBench.data.TemporalDataset;
/**
* interface for classes that read in a temporal dataset from a particular file
* format.
*
* Based on {@link prefuse.data.io.GraphReader}.
*
* @author Alexander Rind
*/
public interface TemporalDatasetReader {
/**
* Read in a temporal dataset from the file at the given location. Though
* not required by this interface, the String is typically resolved using
* the {@link prefuse.util.io.IOLib#streamFromString(String)} method,
* allowing URLs, classpath references, and files on the file system to be
* accessed.
*
* @param location
* the location to read the temporal dataset from
* @return the loaded temporal dataset
* @throws TemporalDataException
* @throws FileNotFoundException
* @throws IOException
*/
public TemporalDataset readData(String location) throws DataIOException,
TemporalDataException;
/**
* Read in a temporal dataset from the given URL.
*
* @param url
* the url to read the temporal dataset from
* @return the loaded temporal dataset
* @throws TemporalDataException
* @throws IOException
*/
public TemporalDataset readData(URL url) throws DataIOException,
TemporalDataException;
/**
* Read in a temporal dataset from the given File.
*
* @param f
* the file to read the temporal dataset from
* @return the loaded temporal dataset
* @throws TemporalDataException
* @throws FileNotFoundException
* @throws IOException
*/
public TemporalDataset readData(File f) throws DataIOException,
TemporalDataException;
/**
* Read in a temporal dataset from the given InputStream.
*
* @param is
* the InputStream to read the temporal dataset from
* @return the loaded temporal dataset
* @throws TemporalDataException
* @throws IOException
*/
public TemporalDataset readData(InputStream is) throws DataIOException,
TemporalDataException;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy