public class MboxIterator extends Object implements Iterable<CharBufferWrapper>, Closeable
Class that provides an iterator over email messages inside an mbox file. An mbox file is a sequence of email messages separated by From_ lines.
Description ot the file format:
| Modifier and Type | Class and Description |
|---|---|
static class |
MboxIterator.Builder |
| Modifier and Type | Method and Description |
|---|---|
static String |
bufferDetailsToString(Buffer buffer)
Utility method to log important details about buffers.
|
void |
close() |
static MboxIterator.Builder |
fromFile(File filePath) |
static MboxIterator.Builder |
fromFile(String file) |
protected void |
initMboxIterator()
initialize the Mailbox iterator
|
Iterator<CharBufferWrapper> |
iterator() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorprotected void initMboxIterator()
throws IOException
IOExceptionCharConversionExceptionpublic Iterator<CharBufferWrapper> iterator()
iterator in interface Iterable<CharBufferWrapper>public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionpublic static MboxIterator.Builder fromFile(File filePath)
public static MboxIterator.Builder fromFile(String file)
Copyright © 2004–2023 The Apache Software Foundation. All rights reserved.