Required Initializerswift-protobuf 1.29.0SwiftProtobuf
init(repeating:count:)
An initializer for a bag of bytes type.
init(repeating: UInt8, count: Int)
An initializer for a bag of bytes type.
init(repeating: UInt8, count: Int)
s13SwiftProtobuf0aB15ContiguousBytesP9repeating5countxs5UInt8V_Sitcfc
What are these?4DR1D
import SwiftProtobuf
Support library for Swift code generated by protoc-gen-swift.
protocol SwiftProtobufContiguousBytes
Conformance to this protocol gives users a way to provide their own “bag of bytes” types to be used for serialization and deserialization of protobufs. It provides a general interface for bytes since the Swift Standard Library currently does not provide such a protocol.
@frozen struct UInt8
An 8-bit unsigned integer value type.
@frozen struct Int
A signed integer value type.
init<S>(_ sequence: S) where S : Sequence, S.Element == UInt8
An initializer for a bag of bytes type, given a sequence of bytes.
var count: Int { get }
The number of bytes in the bag of bytes.
func withUnsafeBytes<R>(_ body: (UnsafeRawBufferPointer) throws -> R) rethrows -> R
Calls the given closure with the contents of underlying storage.
mutating func withUnsafeMutableBytes<R>(_ body: (UnsafeMutableRawBufferPointer) throws -> R) rethrows -> R
Calls the given closure with the contents of underlying storage.