OlmStorage

Inheritance: java.lang.Object

All Implemented Interfaces: com.aspose.ms.System.IDisposable, java.io.Closeable

public class OlmStorage implements System.IDisposable, Closeable

Represents Outlook for Mac storage (.OLM) file.

Constructors

ConstructorDescription
OlmStorage(TraversalExceptionsCallback callback)Initializes a new instance of the OlmStorage class.
OlmStorage(String fileName)Initializes a new instance of the OlmStorage class.
OlmStorage(InputStream stream)Initializes a new instance of the OlmStorage class.

Methods

MethodDescription
close()
dispose()Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
enumerateMessages(OlmFolder folder)Exposes the enumerator, which supports an iteration of messages in folder.
equals(Object arg0)
extractMapiMessage(OlmMessageInfo messageInfo)Get the message from OLM storage.
fromFile(String fileName)Load OLM storage from file.
fromStream(InputStream stream)Load OLM from stream.
getClass()
getFolder(String name, boolean ignoreCase)Gets the folder by name.
getFolderHierarchy()Gets the folder hierarchy.
getFolders()Gets collection of folders.
hashCode()
load(InputStream stream)Load OLM storage from stream.
load(String fileName)Load OLM storage from file.
notify()
notifyAll()
toString()
wait()
wait(long arg0)
wait(long arg0, int arg1)

OlmStorage(TraversalExceptionsCallback callback)

public OlmStorage(TraversalExceptionsCallback callback)

Initializes a new instance of the OlmStorage class. Allows setting a callback method for handling exceptions that occur during OLM storage traversal.

Parameters:

ParameterTypeDescription
callbackTraversalExceptionsCallbackThe exception callback.

OlmStorage(String fileName)

public OlmStorage(String fileName)

Initializes a new instance of the OlmStorage class.

Parameters:

ParameterTypeDescription
fileNamejava.lang.StringOLM file name.

OlmStorage(InputStream stream)

public OlmStorage(InputStream stream)

Initializes a new instance of the OlmStorage class.

Parameters:

ParameterTypeDescription
streamjava.io.InputStreamSource stream java.io.InputStream with OLM storage data.

close()

public void close()

dispose()

public final void dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

enumerateMessages(OlmFolder folder)

public final System.Collections.Generic.IGenericEnumerable<MapiMessage> enumerateMessages(OlmFolder folder)

Exposes the enumerator, which supports an iteration of messages in folder.

Parameters:

ParameterTypeDescription
folderOlmFolderOlmFolder that represents information about folder in OLM storage.

Returns: com.aspose.ms.System.Collections.Generic.IGenericEnumerable<com.aspose.email.MapiMessage> - System.Collections.Generic.IEnumerableltTgt , that represents an enumerator that iterates through a messages in folder.

equals(Object arg0)

public boolean equals(Object arg0)

Parameters:

ParameterTypeDescription
arg0java.lang.Object

Returns: boolean

extractMapiMessage(OlmMessageInfo messageInfo)

public final MapiMessage extractMapiMessage(OlmMessageInfo messageInfo)

Get the message from OLM storage.

Parameters:

ParameterTypeDescription
messageInfoOlmMessageInfoAn OlmMessageInfo object that represents information about message.

Returns: MapiMessage - A MapiMessage object.

fromFile(String fileName)

public static OlmStorage fromFile(String fileName)

Load OLM storage from file.

Parameters:

ParameterTypeDescription
fileNamejava.lang.StringName of .olm file.

Returns: OlmStorage - An OlmStorage object that represents the current OLM file.

fromStream(InputStream stream)

public static OlmStorage fromStream(InputStream stream)

Load OLM from stream.

Parameters:

ParameterTypeDescription
streamjava.io.InputStreamThe System.IO.Stream.

Returns: OlmStorage - An OlmStorage object that represents the current OLM storage.

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

getFolder(String name, boolean ignoreCase)

public final OlmFolder getFolder(String name, boolean ignoreCase)

Gets the folder by name.

Parameters:

ParameterTypeDescription
namejava.lang.StringName of folder.
ignoreCasebooleanA value that indicates whether the name to match is case insensitive.

Returns: OlmFolder - An OlmFolder object.

getFolderHierarchy()

public final List<OlmFolder> getFolderHierarchy()

Gets the folder hierarchy.

Value: The folder hierarchy.

Returns: java.util.List<com.aspose.email.OlmFolder>

getFolders()

public final List<OlmFolder> getFolders()

Gets collection of folders.

Returns: java.util.List<com.aspose.email.OlmFolder> - The collection of folders that belong to the storage, i.e. the sub-folders of the current OLMStorage object.

hashCode()

public native int hashCode()

Returns: int

load(InputStream stream)

public final boolean load(InputStream stream)

Load OLM storage from stream. This method is used when a OlmStorage object is created using constructor with the TraversalExceptionsCallback parameter.

Parameters:

ParameterTypeDescription
streamjava.io.InputStreamThe stream.

Returns: boolean - ’true’ if the file has been loaded successfully and further traversal is possible; otherwise, false.

load(String fileName)

public final boolean load(String fileName)

Load OLM storage from file. This method is used when a OlmStorage object is created using constructor with the TraversalExceptionsCallback parameter.

Parameters:

ParameterTypeDescription
fileNamejava.lang.StringThe file name.

Returns: boolean - ’true’ if the file has been loaded successfully and further traversal is possible; otherwise, false.

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

toString()

public String toString()

Returns: java.lang.String

wait()

public final void wait()

wait(long arg0)

public final native void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int