Interface SSTableId.Builder<T extends SSTableId>

All Known Implementing Classes:
SequenceBasedSSTableId.Builder, UUIDBasedSSTableId.Builder
Enclosing interface:
SSTableId

public static interface SSTableId.Builder<T extends SSTableId>
Builder that can create instances of certain implementation of SSTableId.
  • Method Details

    • generator

      Supplier<T> generator(Stream<SSTableId> existingIdentifiers)
      Creates a new generator of identifiers. Each supplied value must be different to all the previously generated values and different to all the provided existing identifiers.
    • isUniqueIdentifier

      boolean isUniqueIdentifier(String str)
    • isUniqueIdentifier

      boolean isUniqueIdentifier(ByteBuffer bytes)
    • fromString

      T fromString(String str) throws IllegalArgumentException
      Creates an identifier instance from its string representation
      Parameters:
      str - string representation as returned by SSTableId.toString()
      Throws:
      IllegalArgumentException - when the provided string is not a valid string representation of the identifier
    • fromBytes

      T fromBytes(ByteBuffer bytes) throws IllegalArgumentException
      Creates an identifier instance from its binary representation

      The method expects the identifier is encoded in all remaining bytes of the buffer. The method does not move the pointer of the buffer.

      Parameters:
      bytes - binary representation as returned by SSTableId.asBytes()
      Throws:
      IllegalArgumentException - when the provided bytes are not a valid binary representation of the identifier