Commit ecc6bd1
committed
✨ Add cached #capabilities, #capable?(name), etc
Updated methods:
* `#initialize` - save capabilities in `OK` or `PREAUTH` greeting
* `#capability` - always update saved capabilities
* `#starttls` - always clear capabilities after tagged OK response
* `#authenticate` - clear capabilities or update from tagged OK response
* `#login` - clear capabilities or update from tagged OK response
New methods:
* `#capable?(name)` - the primary API for discovering capabilities
* `#auth_capable?(name)` - returns whether a SASL mechanism is supported
* `#capabilities` - calls `capability` when needed
* `#capabilities_cached?` - whether capabilities are cached
* `#clear_cached_capabilities` - clears the cache
Also, many docs related to capabilities were reorganized and rewritten.
Fixes #31.1 parent 25d75d4 commit ecc6bd1
File tree
3 files changed
+753
-107
lines changed- lib/net
- test/net/imap
3 files changed
+753
-107
lines changed
0 commit comments