SmartKeyEncodingStrategy
public enum SmartKeyEncodingStrategy : Sendable
Undocumented
-
Use the keys specified by each type. This is the default strategy.
Declaration
Swift
case useDefaultKeys
-
Convert from “camelCaseKeys” to “snake_case_keys” before writing a key to JSON payload. For example,
oneTwoThree
becomesone_two_three
._oneTwoThree_
becomes_one_two_three_
.Declaration
Swift
case toSnakeCase
-
Convert the first letter of the key to lower case before attempting to match a key with the one specified by each type. For example,
OneTwoThree
becomesoneTwoThree
.Declaration
Swift
case firstLetterLower
-
Convert the first letter of the key to upper case before attempting to match a key with the one specified by each type. For example,
oneTwoThree
becomesOneTwoThree
.Declaration
Swift
case firstLetterUpper