Klasse LimitService
java.lang.Object
de.delinkedde.areashopreborn.application.LimitService
Resolves permission-selected limit profiles without blocking Paper's server thread.
-
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungLimitService(LimitProfileRegistry profiles, PermissionGateway permissions, ThreadBridge threads, Database database, RegionGroupRepository groups) Creates the limit resolver.LimitService(LimitProfileRegistry profiles, PermissionGateway permissions, ThreadBridge threads, Database database, RegionGroupRepository groups, int maximumAssignmentsPerRegion) Creates a resolver with a hard ceiling for direct and inherited group rules. -
Methodenübersicht
-
Konstruktordetails
-
LimitService
public LimitService(LimitProfileRegistry profiles, PermissionGateway permissions, ThreadBridge threads, Database database, RegionGroupRepository groups) Creates the limit resolver.- Parameter:
profiles- validated profile registrypermissions- Vault permission adapterthreads- Paper main-thread bridgedatabase- asynchronous SQLite executorgroups- persistent region-group repository
-
LimitService
public LimitService(LimitProfileRegistry profiles, PermissionGateway permissions, ThreadBridge threads, Database database, RegionGroupRepository groups, int maximumAssignmentsPerRegion) Creates a resolver with a hard ceiling for direct and inherited group rules.- Parameter:
profiles- validated profile registrypermissions- Vault permission adapterthreads- Paper main-thread bridgedatabase- asynchronous SQLite executorgroups- persistent region-group repositorymaximumAssignmentsPerRegion- maximum direct assignments on one region
-
-
Methodendetails
-
resolve
Resolves the effective profile for a player UUID. The virtual server identity always receives an unlimited synthetic profile.- Parameter:
playerId- player or system identity- Gibt zurück:
- future containing the effective immutable profile
-
resolve
Resolves the effective profile including deterministic rules assigned to one region. Explicit player permission profiles take precedence over group overrides.- Parameter:
playerId- player whose permission profile is selectedregionId- city or parcel providing group context- Gibt zurück:
- future containing the effective immutable profile
-
reload
Reloads the limits file after validation.- Gibt zurück:
- completion future
-
profiles
Lists configured profiles in selection order.- Gibt zurück:
- immutable configured profiles
-