Config

public struct Config

The Config struct allows for configuring Parser and Serializer to allow for separators other than comma or string delimiters like quotation marks

  • The character that separates one cell from another.

    Declaration

    Swift

    public let cellSeparator: UInt8
  • The character that is used to denote the start and end of a cell’s contents.

    Declaration

    Swift

    public let cellDelimiter: UInt8?
  • The deault Config instance that uses commas for cell separators and double quotes for cell delimiters.

    Declaration

    Swift

    public static let `default`: Config = Config(cellSeparator: 44, cellDelimiter: 34)
  • Creates a new Config instance

    Declaration

    Swift

    public init(cellSeparator: UInt8, cellDelimiter: UInt8?)

    Parameters

    cellSeparator

    The character that separates one cell from another.

    cellDelimiter

    The character that is used to denote the start and end of a cell’s contents.

  • Creates a new Config instance from UnicdeScalar literals.

    Declaration

    Swift

    public init(separator: UnicodeScalar, delimiter: UnicodeScalar)

    Parameters

    separator

    The UnicodeScalar for the separator between cells (',').

    delimiter

    The UnicdeScalar for the delimiter that marks the start and end of a cell ('"').