@@ -41,14 +41,29 @@ public function getTypes(Direction $direction): iterable
4141
4242 // Adds support for the "string" type
4343 yield new Builder \SimpleTypeBuilder (['string ' , \Stringable::class], Type \StringType::class);
44+ if ($ direction === Direction::Normalize) {
45+ yield new Builder \SimpleTypeBuilder ('lowercase-string ' , Type \StringType::class);
46+ yield new Builder \SimpleTypeBuilder ('uppercase-string ' , Type \StringType::class);
47+ } else {
48+ yield new Builder \SimpleTypeBuilder ('lowercase-string ' , Type \LowercaseString::class);
49+ yield new Builder \SimpleTypeBuilder ('uppercase-string ' , Type \UppercaseString::class);
50+ }
4451
4552 // Adds support for the "int" type
4653 yield new Builder \IntRangeTypeBuilder (['int ' , 'integer ' ]);
47- yield new Builder \PositiveIntBuilder ('positive-int ' );
48- yield new Builder \NonPositiveIntBuilder ('non-positive-int ' );
49- yield new Builder \NegativeIntBuilder ('negative-int ' );
50- yield new Builder \NonNegativeIntBuilder ('non-negative-int ' );
51- yield new Builder \NonZeroIntBuilder ('non-zero-int ' );
54+ if ($ direction === Direction::Normalize) {
55+ yield new Builder \SimpleTypeBuilder ('positive-int ' , Type \IntType::class);
56+ yield new Builder \SimpleTypeBuilder ('non-positive-int ' , Type \IntType::class);
57+ yield new Builder \SimpleTypeBuilder ('negative-int ' , Type \IntType::class);
58+ yield new Builder \SimpleTypeBuilder ('non-negative-int ' , Type \IntType::class);
59+ yield new Builder \SimpleTypeBuilder ('non-zero-int ' , Type \IntType::class);
60+ } else {
61+ yield new Builder \PositiveIntBuilder ('positive-int ' );
62+ yield new Builder \NonPositiveIntBuilder ('non-positive-int ' );
63+ yield new Builder \NegativeIntBuilder ('negative-int ' );
64+ yield new Builder \NonNegativeIntBuilder ('non-negative-int ' );
65+ yield new Builder \SimpleTypeBuilder ('non-zero-int ' , Type \NonZeroIntType::class);
66+ }
5267
5368 // Adds support for the "float" type
5469 yield new Builder \SimpleTypeBuilder (['float ' , 'double ' , 'real ' ], Type \FloatType::class);
0 commit comments