The file input interface is an input with specific methods that deals with files. File inputs are designed to handle graphs stored under the form of a textual or binary file either under the form of a file name or a Java input stream. If the file comes from an URL, convert the URL to an input stream.
The file package is designed under the idea that it provides graph inputs from files that store the graph under a given file format and encoding. The package provides decoders for all these formats.
Do not confuse the file package with the net package that can also read from URLs, but build graph not from encoded description of a graph, but from web services like Flickr or Amazon, or simply networks of web pages tied by web links. The graph construction task is entirely different.
Although not all graph format handle dynamic graphs, all file inputs must provide both the readAll() and begin()/nextEvents()/end() methods. The later must read one graph modification at a time.
|
|
|
|
|
|