Package org.apache.openjpa.lib.meta
Class JarFileURLMetaDataIterator
java.lang.Object
org.apache.openjpa.lib.meta.JarFileURLMetaDataIterator
- All Implemented Interfaces:
MetaDataFilter.Resource,MetaDataIterator,Closeable
public class JarFileURLMetaDataIterator
extends Object
implements MetaDataIterator, MetaDataFilter.Resource
Iterator over all metadata resources in a given resource addressed by a jar:file URL.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Close the resources used by this iterator.byte[]Resource content.getFile()Return the last-iterated metadata resource content as a file, or null if not an extant file.Return the last-iterated metadata resource content as a stream.getName()The name of the resource.booleanhasNext()Return whether there is another resource to iterate over.next()Return the next metadata resource.
-
Constructor Details
-
JarFileURLMetaDataIterator
- Throws:
IOException
-
-
Method Details
-
hasNext
Return whether there is another resource to iterate over.- Specified by:
hasNextin interfaceMetaDataIterator- Throws:
IOException
-
next
Return the next metadata resource.- Specified by:
nextin interfaceMetaDataIterator- Throws:
IOException
-
getInputStream
Return the last-iterated metadata resource content as a stream.- Specified by:
getInputStreamin interfaceMetaDataIterator- Throws:
IOException
-
getFile
Return the last-iterated metadata resource content as a file, or null if not an extant file.- Specified by:
getFilein interfaceMetaDataIterator- Throws:
IOException
-
close
public void close()Close the resources used by this iterator.- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceMetaDataIterator
-
getName
The name of the resource.- Specified by:
getNamein interfaceMetaDataFilter.Resource
-
getContent
Resource content.- Specified by:
getContentin interfaceMetaDataFilter.Resource- Throws:
IOException
-