def []=(name, registered_class)
      unless registered_class.is_a?(Class)
        raise TypeError, 'Can only register class objects'
      end

      case name
      when String, Symbol
        @registry[name.to_sym] = registered_class
      else
        raise TypeError, "Can not use #{name.inspect} to register a #{@object_type} class"
      end
      registered_class
    end
def []=(name, registered_class)
      unless registered_class.is_a?(Class)
        raise TypeError, 'Can only register class objects'
      end

      case name
      when String, Symbol
        @registry[name.to_sym] = registered_class
      else
        raise TypeError, "Can not use #{name.inspect} to register a #{@object_type} class"
      end
      registered_class
    end
Register a class for the given name.

 @param name [String, Symbol] the name at which the class should be
   registered
 @param registered_class [Class] the class to register at `name`
 @raise [TypeError] if `name` is not a `String` or `Symbol`, or if
   `registered_class` is not a `Class`
 @return [Class] the `registered_class`