Structureswift-protobuf 1.29.0SwiftProtobuf
JSONEncodingOptions
Options for JSONEncoding.
struct JSONEncodingOptions
Options for JSONEncoding.
struct JSONEncodingOptions
import SwiftProtobuf
Support library for Swift code generated by protoc-gen-swift.
protocol Sendable
init()
var alwaysPrintEnumsAsInts: Bool
Always print enums as ints. By default they are printed as strings.
var alwaysPrintInt64sAsNumbers: Bool
Always prints int64s values as numbers. By default, they are printed as strings as per proto3 JSON mapping rules. NB: When used as Map keys, int64s will be printed as strings as expected.
var preserveProtoFieldNames: Bool
Whether to preserve proto field names. By default they are converted to JSON(lowerCamelCase) names.
var useDeterministicOrdering: Bool
Whether to use deterministic ordering when serializing.