public class StreamedFeatureFile extends FeatureFile
FeatureFile
backed by a stream or file. Doesn't require the list be
held in memory.Constructor and Description |
---|
StreamedFeatureFile()
Default constructor
|
StreamedFeatureFile(File keypointFile)
Construct with file
|
StreamedFeatureFile(File keypointFile,
Class<? extends Keypoint> clz)
Construct with file
|
StreamedFeatureFile(InputStream stream)
Construct with stream
|
StreamedFeatureFile(InputStream stream,
Class<? extends Keypoint> clz)
Construct with stream
|
StreamedFeatureFile(LocalFeatureList<? extends LocalFeature<?,?>> kpl)
Construct with list
|
Modifier and Type | Method and Description |
---|---|
void |
close()
close any connection to the underlying file
|
FeatureFileFeature |
get(int index)
The ith local feature
|
Iterator<FeatureFileFeature> |
iterator() |
void |
setIteratorType(Class<? extends Iterator<FeatureFileFeature>> cls)
Set the iterator type
|
int |
size() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public StreamedFeatureFile()
public StreamedFeatureFile(LocalFeatureList<? extends LocalFeature<?,?>> kpl)
kpl
- public StreamedFeatureFile(File keypointFile, Class<? extends Keypoint> clz) throws IOException
keypointFile
- clz
- IOException
public StreamedFeatureFile(File keypointFile) throws IOException
keypointFile
- IOException
public StreamedFeatureFile(InputStream stream) throws IOException
stream
- IOException
public StreamedFeatureFile(InputStream stream, Class<? extends Keypoint> clz) throws IOException
stream
- clz
- IOException
public void setIteratorType(Class<? extends Iterator<FeatureFileFeature>> cls)
cls
- public Iterator<FeatureFileFeature> iterator()
iterator
in interface Iterable<FeatureFileFeature>
iterator
in class FeatureFile
public int size()
size
in class FeatureFile
public FeatureFileFeature get(int index)
FeatureFile
get
in class FeatureFile
public void close()
FeatureFile
close
in class FeatureFile