Package-level declarations

Types

Link copied to clipboard
data class BlockKey(val world: String, val x: Int, val y: Int, val z: Int)

Immutable key identifying a block position within a world (by name). Used as the spatial index key in LocationStore; a plain data class so equality/hashing come for free and lookups are O(1).

Link copied to clipboard
data class DespawnLocation(val world: String, val x: Int, val y: Int, val z: Int, val owner: UUID)

A single despawn location: a block position (world name + integer block coords) owned by a player.

Link copied to clipboard
class JdbcLocationRepository(dataSource: DataSource, logger: Logger, poolCloseable: AutoCloseable? = null) : LocationRepository

Database-backed LocationRepository that works for SQLite and MySQL/MariaDB — the SQL is deliberately dialect-agnostic (CREATE TABLE IF NOT EXISTS, INT/VARCHAR, a composite primary key). It talks to a JDBC DataSource (a HikariCP pool in production) and touches only java.sql / javax.sql, so nothing here needs to be shaded into the plugin jar.

Link copied to clipboard

Owns the in-memory LocationStore and the persistent LocationRepository, and is the single entry point the rest of the plugin uses to read and mutate despawn locations.

Link copied to clipboard

A storage backend for despawn locations. Implementations:

Link copied to clipboard

In-memory index over every despawn location. Replaces the old flat ArrayList that was copied and linearly scanned on every query and rewritten to disk in full on every change. Provides:

Link copied to clipboard

Builds the configured LocationRepository and, when switching to a database for the first time, migrates any existing flat-file data into it. Drivers and HikariCP are provided at runtime by Paper's libraries: loader (see plugin.yml).

Link copied to clipboard

Flat-file LocationRepository: one YAML file per owner under userdata/<uuid>.yml with a locations: list of x;y;z;world strings — the same on-disk format the original plugin used, so existing servers' data loads unchanged.