registerEnumReflection<O> method

void registerEnumReflection<O>(
  1. EnumReflection<O> enumReflection
)

Called by EnumReflection when instantiated for the 1st time.

Implementation

void registerEnumReflection<O>(EnumReflection<O> enumReflection) {
  var enumType = enumReflection.enumType;
  var prev = _registeredEnumReflection[enumType];

  if (prev == null || prev.compareTo(enumReflection) < 0) {
    _registeredEnumReflection[enumType] = enumReflection;
  }
}