Ponder is a library, not a plugin, so it does not add any in-game commands. This document describes the public API exposed by each module.
A generic key/value cache.
| Method | Description |
|---|---|
get(K key) |
Returns the value associated with the key, or null. |
set(K key, V value) |
Stores a value under the given key. |
containsKey(K key) |
Returns true if the cache holds an entry for the key. |
remove(K key) |
Removes the entry for the key. |
removeMatching(Predicate<V> predicate) |
Removes all entries whose value matches the predicate. |
keys() |
Returns the set of all keys currently in the cache. |
clear() |
Removes all entries from the cache. |
Immutable configuration for a Cache instance.
| Constructor | Description |
|---|---|
CacheConfiguration(String name) |
Creates a configuration with the given name and default capacity (20). |
CacheConfiguration(String name, long capacity) |
Creates a configuration with explicit capacity. |
| Method | Description |
|---|---|
getName() |
Returns the cache name. |
getCapacity() |
Returns the maximum capacity. |
The standard Cache implementation backed by a LinkedHashMap. Accepts a CacheConfiguration at construction time.
Manages a collection of named caches.
The standard CacheManager implementation.
Represents a single executable command.
Abstraction for the entity that sends a command (e.g. a player or console).
Wrapper around the raw argument string passed to a command. Provides helpers for parsing positional arguments.
Represents the outcome of executing a command.
A CommandResult subtype indicating that the command was invoked with invalid arguments.
Accepts raw command input and dispatches it to the appropriate Command implementation.
The standard CommandService implementation.
A Command that forwards execution to a child command based on the first argument (sub-command routing).
All members are Kotlin extension functions/properties in the preponderous.ponder.minecraft.bukkit packages.
| Member | Description |
|---|---|
Distance (value class) |
Wraps a Double representing a block distance. |
Int.blocks |
Converts an Int to a Distance. |
Double.blocks |
Converts a Double to a Distance. |
location within distance (infix) |
Returns a Predicate<Location> that matches locations within the given distance. Usage: location within 10.blocks. |
player within distance (infix) |
Returns a Predicate<Player> that matches players within the given distance. Usage: player within 10.blocks. |
Player.findPlayersWithin(distance) |
Returns all players in the same world within the given distance, excluding the receiver. |
| Member | Description |
|---|---|
Plugin.registerListeners(vararg listeners) |
Registers one or more Listener instances with the server's plugin manager. |