public static function registerEnumTypes(array $types = [])
    {
        foreach ($types as $name => $callbacks) {
            [$constructor, $serializer] = (is_array($callbacks) ? $callbacks : [$callbacks, null]);

            static::registerEnumType($name, $constructor, $serializer);
        }
    }