At work I spend a lot more time with JavaMail than I’d like to. It’s an awesome library, but it’s also really old (as in it’s targeted to older JVMs, and doesn’t take advantage of newer stuff, like enums or generics). I’ve thought about writing a replacement - or at least a wrapper of some kind - to make it a little more modern. Coming across kotlin, I thought this would be a great way to learn the language and build a better JavaMail at the same time.
The project is at GitHub - SlothLabs/kotlin-mail: A kotlin-esque wrapper for JavaMail., and there’s instructions for pulling it from Maven Central there as well. The feature set is lacking - mainly just builders for searching and sorting an IMAP folder - but it’s still only in 0.1.0. By 1.0.0 I’d like to wrap the entire JavaMail library, with the end goal being a full replacement.
I’d love any feedback at all. There’s API docs but no user guide yet; for now, there’s a sandbox-ish test class I’m using to flesh out usability/features, but I know that won’t work in the long run (and it isn’t commented anyways). I’m still new to kotlin, so no clue if I’m doing things “idiomatically” or if I’m using it as a better Java (I don’t think that’s the case, but still…), so any kind of code review feedback would be appreciated as well.
And of course if there’s any kind of bugs or feature requests or anything, feel free to throw them in the issues bucket on github too
Thanks!