Categorygithub.com/pavel-popov/go.enmime
modulepackage
0.6.1
Repository: https://github.com/pavel-popov/go.enmime.git
Documentation: pkg.go.dev

# README

enmime Build Status GoDoc

enmime is a MIME parsing library for Go. It's built ontop of Go's included mime/multipart support, but is geared towards parsing MIME encoded emails.

It is being developed in tandem with the Inbucket email service.

API documentation can be found here: http://godoc.org/github.com/jhillyerd/go.enmime

Development Status

enmime is alpha quality: it works but has not been tested with a wide variety of source data, and it's likely the API will evolve some before an official release.

About

enmime is written in Google Go.

enmime is open source software released under the MIT License. The latest version can be found at https://github.com/jhillyerd/go.enmime

# Packages

No description provided by the author
No description provided by the author

# Functions

BreadthMatchAll performs a breadth first search of the MIMEPart tree and returns all parts that cause the given matcher to return true.
BreadthMatchFirst performs a breadth first search of the MIMEPart tree and returns the first part that causes the given matcher to return true.
No description provided by the author
Decode a MIME header per RFC 2047.
Decode a MIME header per RFC 2047 to =?utf-8b?.
DepthMatchAll performs a depth first search of the MIMEPart tree and returns all parts that causes the given matcher to return true.
DepthMatchFirst performs a depth first search of the MIMEPart tree and returns the first part that causes the given matcher to return true.
IsMultipartMessage returns true if the message has a recognized multipart Content-Type header.
NewBase64Cleaner returns a Base64Cleaner object for the specified reader.
NewMIMEPart creates a new memMIMEPart object.
ParseMIME reads a MIME document from the provided reader and parses it into tree of MIMEPart objects.
ParseMIMEBody parses the body of the message object into a tree of MIMEPart objects, each of which is aware of its content type, filename and headers.

# Variables

No description provided by the author

# Structs

Base64Cleaner helps work around bugs in Go's built-in base64 decoder by stripping out whitespace that would cause Go to lose count of things and issue an "illegal base64 data at input byte..." error.
MIMEBody is the outer wrapper for MIME messages.

# Interfaces

MIMEPart is the primary interface enmine clients will use.

# Type aliases

MIMEPartMatcher is a function type that you must implement to search for MIMEParts using the BreadthMatch* functions.