Klasse OwnershipTransferService

java.lang.Object
de.delinkedde.areashopreborn.application.OwnershipTransferService

public final class OwnershipTransferService extends Object
Coordinates a direct, payment-free parcel transfer between two players.
  • Konstruktordetails

    • OwnershipTransferService

      public OwnershipTransferService(Database database, EstateRepository repository, WorldGuardGateway worldGuard, ThreadBridge threads)
      Creates the ownership transfer service.
      Parameter:
      database - asynchronous database executor
      repository - estate repository
      worldGuard - WorldGuard adapter
      threads - server-thread bridge
    • OwnershipTransferService

      public OwnershipTransferService(Database database, EstateRepository repository, WorldGuardGateway worldGuard, ThreadBridge threads, EventPublisher events)
      Creates a transfer service with an explicit event publisher.
      Parameter:
      database - asynchronous database executor
      repository - estate repository
      worldGuard - WorldGuard adapter
      threads - server-thread bridge
      events - synchronous platform event publisher
  • Methodendetails

    • transfer

      public CompletableFuture<Void> transfer(UUID ownerId, String regionName, UUID recipientId)
      Transfers an unlisted sold parcel and removes all access grants from the previous owner.
      Parameter:
      ownerId - current owner
      regionName - parcel display name or WorldGuard identifier
      recipientId - new owner
      Gibt zurück:
      completion future
    • transfer

      public CompletableFuture<Void> transfer(UUID ownerId, String regionName, UUID recipientId, OperationCause cause)
      Transfers an unlisted parcel with cancellable synchronous Bukkit events.
      Parameter:
      ownerId - current owner
      regionName - parcel display name or WorldGuard identifier
      recipientId - new owner
      cause - initiating subsystem
      Gibt zurück:
      completion future