Interface EntityTypeKey<T>

  • All Known Implementing Classes:
    EntityTypeKeyImpl

    public interface EntityTypeKey<T>
    Name of the entity type.
    • Method Detail

      • name

        java.lang.String name()
        Name of the entity type.
        Returns:
        (undocumented)
      • persistenceIdFrom

        PersistenceId persistenceIdFrom​(java.lang.String entityId)
        Constructs a PersistenceId from this EntityTypeKey and the given entityId by concatenating them with | separator.

        The | separator is also used in Lagom's scaladsl.PersistentEntity but no separator is used in Lagom's javadsl.PersistentEntity. For compatibility with Lagom's javadsl.PersistentEntity you should use "" as the separator in EntityTypeKey.withEntityIdSeparator.

        Parameters:
        entityId - (undocumented)
        Returns:
        (undocumented)
      • withEntityIdSeparator

        EntityTypeKey<T> withEntityIdSeparator​(java.lang.String separator)
        Specify a custom separator for compatibility with old naming conventions. The separator is used between the EntityTypeKey and the entityId when constructing a persistenceId with EntityTypeKey.persistenceIdFrom.

        The default | separator is also used in Lagom's scaladsl.PersistentEntity but no separator is used in Lagom's javadsl.PersistentEntity. For compatibility with Lagom's javadsl.PersistentEntity you should use "" as the separator here.

        Parameters:
        separator - (undocumented)
        Returns:
        (undocumented)