Class PlayerRegisterTransaction

java.lang.Object
com.djrapitops.plan.storage.database.transactions.Transaction
com.djrapitops.plan.storage.database.transactions.events.PlayerRegisterTransaction
Direct Known Subclasses:
StoreServerPlayerTransaction

public class PlayerRegisterTransaction extends Transaction
Transaction for registering player's BaseUser to the database.
  • Field Details

    • playerUUID

      protected final UUID playerUUID
    • registered

      protected final LongSupplier registered
  • Constructor Details

    • PlayerRegisterTransaction

      public PlayerRegisterTransaction(UUID playerUUID, LongSupplier registered, String playerName)
  • Method Details

    • shouldBeExecuted

      protected boolean shouldBeExecuted()
      Description copied from class: Transaction
      Override this method for conditional execution.

      Please note that the transaction has not been initialized and class variables are not available for queries. The condition should depend on other variables (Like the data that is to be stored) given to the transaction.

      Overrides:
      shouldBeExecuted in class Transaction
      Returns:
      false if the transaction should not execute.
    • performOperations

      protected void performOperations()
      Description copied from class: Transaction
      Implement this method for transaction execution.
      Specified by:
      performOperations in class Transaction
    • getUserId

      public Optional<Integer> getUserId()