Interface Identifiable<T extends Identifiable<T>>


@NullMarked public interface Identifiable<T extends Identifiable<T>>
  • Method Summary

    Modifier and Type
    Method
    Description
    @Nullable Identifier<T>
     
    default Identifier<T>
     
  • Method Details

    • getId

      @Nullable Identifier<T> getId()
      Returns:
      the ID, may be null (e.g. because the Identifiable is in the process of being created)
    • obtainId

      default Identifier<T> obtainId()
      Returns:
      the non-null ID
      Throws:
      IllegalStateException - if the ID is null, e.g. because the Identifiable is in the process of being created