Package com.winterhavenmc.library.messagebuilder.adapters.pipeline.accessors.quantity


package com.winterhavenmc.library.messagebuilder.adapters.pipeline.accessors.quantity
Provides support for macro replacement of quantity-related values.

This package includes an implementation of the Quantifiable interface, which is used to represent objects that can supply a numeric quantity for macro substitution. These quantities are commonly used in messages to represent values such as:

  • Item stack sizes (ItemStack)
  • Inventory or chest capacities (Inventory, Chest)
  • Collection sizes
  • Custom plugin-defined types that implement Quantifiable

The BukkitQuantityAccessor provides automatic adaptation for known Bukkit types as well as user-defined classes.

When an object is adapted as a Quantifiable, it contributes the {OBJECT.QUANTITY} macro to the pipeline, populated with a localized, formatted number string based on the current locale.

See Also: