omni_mapper_generator 0.5.2
omni_mapper_generator: ^0.5.2 copied to clipboard
A powerful code generator that automates boilerplate mapping conversions using the omni_mapper annotations.
0.5.2 #
- Updates the README with detailed examples for all advanced features.
0.5.1 #
- Adds support for empty collection inference (
const []andconst {}) indefaultValueproperties, bypassing strict type-validation and allowing Dart to infer generic types (e.g.List<String>).
0.5.0 #
- Adds code generation support for
@OmniFieldannotation (name,ignore,custom,defaultValue). - Fixes strict type-checking for default values across both
MappingRuleand@OmniFieldat compile-time. - Standardizes
@OmniFieldconfiguration extraction between extension mappers and abstract class generators.
0.4.0 #
- Adds code generation logic for the new
usesproperty (dependency injection). - Adds code generation for polymorphic subclass mapping (
@SubclassMapping). - Adds support for evaluating literal default values in
defaultValues. - Fixes target field shadowing issue when mapping nested fields (
target.name). - Fixes silent null returns with
InvalidGenerationSourceErrorduring unparseable annotation elements. - Fixes a bug to correctly invoke named constructors (e.g.,
super.named()) when usingusesinstead of the unnamed constructor. - Adds validation to throw an error when a fallback dependency requires constructor arguments without explicit injection.
0.3.0 #
- Adds code generation support for multiple sources in mapper methods.
- Adds code generation for automatic Enum mapping.
- Implements deep auto-flattening code generation for nested fields (
address.street). - Adds code generation for automatic reverse mapping (
generateReverse).
0.2.0 #
- Implements
strictModegeneration logic and validation. - Implements
ignoreIfNullgeneration for update methods. - Adds support for custom mapping hooks (
hook) logic generation. - Fixes strict mode false positives for fields with initializers or default values.
- Removes
constrequirements for custom mapping hooks in generated code. - Removes unnecessary null-check warnings from Dart analyzer when using
ignoreIfNull.
0.1.0 #
- Initial release.
- Adds code generation support for
@OmniMapperand@OmniMappersannotations. - Supports generation strategies: Abstract Class, Extension TO, and Extension FROM.
- Supports advanced features: custom field mapping, default values, custom type converters, list mapper generation, in-place update method generation, and field ignoring.