Skip to content

Commit 01a2c0c

Browse files
committed
More renaming
1 parent d108975 commit 01a2c0c

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

src/main/java/com/fasterxml/jackson/databind/introspect/POJOPropertiesCollector.java

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -651,19 +651,19 @@ protected void _addCreators(Map<String, POJOPropertyBuilder> props)
651651
// Then find what is the Primary Constructor (if one exists for type):
652652
// for Java Records and potentially other types too ("data classes"):
653653
// Needs to be done early to get implicit names populated
654-
final PotentialCreator canonical;
654+
final PotentialCreator primary;
655655
if (_isRecordType) {
656-
canonical = JDK14Util.findCanonicalRecordConstructor(_config, _classDef, constructors);
656+
primary = JDK14Util.findCanonicalRecordConstructor(_config, _classDef, constructors);
657657
} else {
658-
canonical = _annotationIntrospector.findPrimaryCreator(_config, _classDef,
658+
primary = _annotationIntrospector.findPrimaryCreator(_config, _classDef,
659659
constructors, factories);
660660
}
661661
// Next: remove creators marked as explicitly disabled
662662
_removeDisabledCreators(constructors);
663663
_removeDisabledCreators(factories);
664664

665665
// And then remove non-annotated static methods that do not look like factories
666-
_removeNonFactoryStaticMethods(factories, canonical);
666+
_removeNonFactoryStaticMethods(factories, primary);
667667

668668
// and use annotations to find explicitly chosen Creators
669669
if (_useAnnotations) { // can't have explicit ones without Annotation introspection
@@ -683,16 +683,16 @@ protected void _addCreators(Map<String, POJOPropertyBuilder> props)
683683

684684
// But if no annotation-based Creators found, find/use Primary Creator
685685
// detected earlier, if any
686-
if (canonical != null) {
686+
if (primary != null) {
687687
if (!creators.hasPropertiesBased()) {
688688
// ... but only process if still included as a candidate
689-
if (constructors.remove(canonical)
690-
|| factories.remove(canonical)) {
689+
if (constructors.remove(primary)
690+
|| factories.remove(primary)) {
691691
// But wait! Could be delegating
692-
if (_isDelegatingConstructor(canonical)) {
693-
creators.addExplicitDelegating(canonical);
692+
if (_isDelegatingConstructor(primary)) {
693+
creators.addExplicitDelegating(primary);
694694
} else {
695-
creators.setPropertiesBased(_config, canonical, "Primary");
695+
creators.setPropertiesBased(_config, primary, "Primary");
696696
}
697697
}
698698
}
@@ -720,12 +720,12 @@ protected void _addCreators(Map<String, POJOPropertyBuilder> props)
720720

721721
// And finally add logical properties for the One Properties-based
722722
// creator selected (if any):
723-
PotentialCreator primary = creators.propertiesBased;
724-
if (primary == null) {
723+
PotentialCreator propsCtor = creators.propertiesBased;
724+
if (propsCtor == null) {
725725
_creatorProperties = Collections.emptyList();
726726
} else {
727727
_creatorProperties = new ArrayList<>();
728-
_addCreatorParams(props, primary, _creatorProperties);
728+
_addCreatorParams(props, propsCtor, _creatorProperties);
729729
}
730730
}
731731

0 commit comments

Comments
 (0)