mirror of
https://github.com/apple/swift-nio-imap
synced 2026-11-25 04:47:51 +00:00
* Primitive capability support * Sample move capability requirement * More examples * Write binary literals * Sanity * Rename to encoding options * Fix sanity * Fix * Add IMAP base options * Rename * Update Capability.swift * Fix * Use EncodeBuffer * Fix writing greeting * Fix sanity * Fix assert * Use EncodeBuffers everywhere * Use EncodingCapabilities * Remove base capabilities * Create CommandEncodeBuffer * Dedicated buffer types * Fix sanity * Clear test buffer * PR review changes * Remove has more chunks * Remove dead code * Fix sanity * Fix
24 lines
764 B
Swift
24 lines
764 B
Swift
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This source file is part of the SwiftNIO open source project
|
|
//
|
|
// Copyright (c) 2020 Apple Inc. and the SwiftNIO project authors
|
|
// Licensed under Apache License v2.0
|
|
//
|
|
// See LICENSE.txt for license information
|
|
// See CONTRIBUTORS.txt for the list of SwiftNIO project authors
|
|
//
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
import struct NIO.ByteBuffer
|
|
|
|
public struct CommandEncodeBuffer {
|
|
public var buffer: EncodeBuffer
|
|
|
|
public init(buffer: ByteBuffer, capabilities: EncodingCapabilities) {
|
|
self.buffer = EncodeBuffer(buffer, mode: .client, capabilities: capabilities)
|
|
}
|
|
}
|