Minimal mime type implementation optimized for minimal memory use.