Package org.apache.openjpa.lib.meta
Class URLMetaDataIterator
- java.lang.Object
-
- org.apache.openjpa.lib.meta.URLMetaDataIterator
-
- All Implemented Interfaces:
MetaDataIterator,Closeable
public class URLMetaDataIterator extends java.lang.Object implements MetaDataIterator
Iterator over the metadata resource represented by a URL.- Author:
- Abe White
-
-
Constructor Summary
Constructors Constructor Description URLMetaDataIterator(java.net.URL url)Constructor; supply resource URL.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Close the resources used by this iterator.java.io.FilegetFile()Return the last-iterated metadata resource content as a file, or null if not an extant file.java.io.InputStreamgetInputStream()Return the last-iterated metadata resource content as a stream.booleanhasNext()Return whether there is another resource to iterate over.java.net.URLnext()Return the next metadata resource.
-
-
-
Method Detail
-
hasNext
public boolean hasNext()
Description copied from interface:MetaDataIteratorReturn whether there is another resource to iterate over.- Specified by:
hasNextin interfaceMetaDataIterator
-
next
public java.net.URL next() throws java.io.IOExceptionDescription copied from interface:MetaDataIteratorReturn the next metadata resource.- Specified by:
nextin interfaceMetaDataIterator- Throws:
java.io.IOException
-
getInputStream
public java.io.InputStream getInputStream() throws java.io.IOExceptionDescription copied from interface:MetaDataIteratorReturn the last-iterated metadata resource content as a stream.- Specified by:
getInputStreamin interfaceMetaDataIterator- Throws:
java.io.IOException
-
getFile
public java.io.File getFile()
Description copied from interface:MetaDataIteratorReturn the last-iterated metadata resource content as a file, or null if not an extant file.- Specified by:
getFilein interfaceMetaDataIterator
-
close
public void close()
Description copied from interface:MetaDataIteratorClose the resources used by this iterator.- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceMetaDataIterator
-
-