Add RedisCommandEncoder by fabianfett · Pull Request #69 · swift-server/RediStack

@fabianfett

We want to be able to efficiently encode Redis commands that are sent to a server. This patch adds a new `RedisCommandEncoder` that allows us to efficiently create Redis commands without needing to go through RESP representations, that may require us to create Arrays. Further it introduces a `RESP3BlobStringEncodable` that must be implement to send blob strings using `RedisCommandEncoder`. This patch also adds implementations for `String` and  `ByteBuffer` for the new `RESP3BlobStringEncodable` protocol.