Changes in reverse chronological order
- Adds secure coding support
- Minor lock efficiency update
- Added Swift Package Manager support
- Resolve possible data race in getter for cache lock object
- Remove automatic trimming of underscores from specified property key paths.
- Added global optional closure that can be used to preprocess key path values:
WrapPropertyKeyPathModifier
- Allow boolean encoding type to be passed through the property wrapper.
- Added two new date property types for more flexible handling of dates:
WPDate8601
- specifyISO8601DateFormatter.Options
flags for ISO8601 date variants that don't match the default handlingWPDateFmt
- specify your ownDateFormatter
format string to handle pretty much any date
- Added property wrappers specific to most of the property types provided for less redundant property declarations.
- Property wrappers include getter and setter value modifier closure arguments (optional).
- Added
WrapPropertyArrayOfEmbeddedModel
(WPEmbModelArray
) andWrapPropertyOptionalArrayOfEmbeddedModel
(WPOptEmbModelArray
) to handle arrays of models that are embedded in one or more wrapper layers - Introduced property wrappers (
@ROProperty
and@RWProperty
) for Swift 5.1 and later that allows single-line property declarations and obviates the need to use the private property definition with public accessors pattern for Objective C compatibility.
- Fixed a thread contention issue caused by sorting the properties array in place
- Added thread protection around creation and access of date formatters
- Made copying behavior a little more explicit in the code
- Fixed a bug around copying mutable models where submodels in the cache could have an incorrect mutable status
- Fixed an issue with float values not properly decoding in some cases
- Added property classes for a dictionary of arrays of models
- Made dictionary of model properties more resilient to keys that contain a "null" value in JSON (an NSNull) - those keys are discarded rather than the entire dictionary being ignored due to a type check failure.
- Fixed an issue where a model derives from a parent class WrapModel in which the parent class' properties weren't gathered and initialized properly.
- Overrides of rawValue weren't obeying serializeForOutput flag
- Added additional boolean output mode for "Y" & "N" in addition to "yes" and "no"
- Added optional enum property type WrapPropertyOptionalEnum/WrapPropertyConvertibleOptionalEnum (WPOptEnum)
- Corrected some misnamed date format enums
- More funcs/vars in WrapModel and WrapModelProperty are open rather than public so they can be overridden.
- dictionary key tokens used for property groups made publicly accessible
- made WrapPropertyBoolean's string test for boolean value public
- fixed WrapPropertyOptionalInt which could return Int??
- added the same special-cased numeric conversion to collections of numeric values that were present in single numeric property classes
- added tests for numeric arrays
- added new date formats and simplified the way date formatters are created/stored
- added WrapPropertyOptionalIntFromString
- fixed serialization parameters not being obeyed in submodels when serializing parent model
- replaced serializationMode with serializeForOutput flag which, I think, is a lot easier to understand
- Removed nonessentials leaving only the basic WrapModel mechanism.
- Added CocoaPods podspec
- Initial Release