com.vaadin.server.
Interface ConnectorIdGenerator
-
All Superinterfaces:
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface ConnectorIdGenerator extends Serializable
Callback for generating the id for new connectors. A generator can be registered to be used with an application by overriding
VaadinService.initConnectorIdGenerator(java.util.List)
or by callingServiceInitEvent.addConnectorIdGenerator(ConnectorIdGenerator)
from aVaadinServiceInitListener
.Since:
8.1
Author:
Vaadin Ltd
-
-
Method Summary
All Methods Modifier and Type Method Description String
generateConnectorId(ConnectorIdGenerationEvent event)
Generates a connector id for a connector.
static String
generateDefaultConnectorId(ConnectorIdGenerationEvent event)
Generates a connector id using the default logic by using
VaadinSession.getNextConnectorId()
.
-
-
-
Method Detail
-
generateConnectorId
String generateConnectorId(ConnectorIdGenerationEvent event)
Generates a connector id for a connector.
Parameters:
event
- the event object that has a reference to the connector and the session, notnull
Returns:
the connector id to use for the connector, not
null
-
generateDefaultConnectorId
static String generateDefaultConnectorId(ConnectorIdGenerationEvent event)
Generates a connector id using the default logic by using
VaadinSession.getNextConnectorId()
.Parameters:
event
- the event object that has a reference to the connector and the session, notnull
Returns:
the connector id to use for the connector, not
null
-
-