loadMimeFile method

void loadMimeFile(
  1. String fileName
)

Reads and parses the complete MIME entity from the local file at fileName. A successful call replaces the current MIME. If the file cannot be opened, the method returns false and preserves the existing object unchanged.

Parsing tolerance and serialization normalization are the same as loadMime.

Throws a ChilkatException if the call fails; the details are in ChilkatException.lastErrorText. Throws an ArgumentError if a string argument contains a NUL character.

Implementation

void loadMimeFile(String fileName) {
  final h = _handle;
  using((arena) {
    final r = _CkMime_LoadMimeFile(h, _toNative(arena, fileName, 'fileName'));
    if (r == 0) {
      throw _fail('loadMimeFile');
    }
  });
}