IoSentryAttachment.fromPath constructor

IoSentryAttachment.fromPath(
  1. String path, {
  2. String? filename,
  3. String? attachmentType,
  4. String? contentType,
})

Creates an attachment from a given path. Only available on dart:io platforms. Not available on web.

Implementation

IoSentryAttachment.fromPath(
  String path, {
  String? filename,
  String? attachmentType,
  String? contentType,
}) : this.fromFile(
        File(path),
        attachmentType: attachmentType,
        contentType: contentType,
        filename: filename,
      );