java.lang.Object
org.vaadin.addons.componentfactory.leaflet.layer.events.types.EventTypeRegistry

public class EventTypeRegistry extends Object
Registry that maps Leaflet event names to their corresponding LeafletEventType constants.
  • Constructor Details

    • EventTypeRegistry

      public EventTypeRegistry()
  • Method Details

    • register

      public static <T extends Enum<T> & LeafletEventType> void register(Class<T> eventType)
      Registers all constants of the given event type enum so they can be looked up by their Leaflet event name.
      Type Parameters:
      T - the enum type
      Parameters:
      eventType - the enum class implementing LeafletEventType to register
    • valueOf

      public static LeafletEventType valueOf(String stringValue)
      Returns the registered event type matching the given Leaflet event name.
      Parameters:
      stringValue - the Leaflet event name
      Returns:
      the matching event type, or null if none is registered