Interface AnyProvider

All Known Subinterfaces:
AnyAmount, AnyContains<Type>, AnyNamed
All Known Implementing Classes:
Config, CursorSlot, DisplayEntitySlot, DroppedItemSlot, DynamicFunctionReference, EntryNode, EquipmentSlot, InvalidNode, InventorySlot, ItemFrameSlot, ItemType, Node, Script, SectionNode, SimpleNode, SkriptQueue, Slot, SlotWithIndex, ThrowableProjectileSlot, VoidNode

public interface AnyProvider
'AnyProvider' types are holders for common properties (e.g. name, size) where it is highly likely that things other than Skript may wish to register exponents of the property.

If possible, types should implement an AnyProvider subtype directly for the best possible parsing efficiency. However, implementing the interface may not be possible if:
  • registering an existing class from a third-party library
  • the subtype getter method conflicts with the type's own methods or erasure
  • the presence of the supertype might confuse the class's design
In these cases, a converter from the class to the AnyX type can be registered. The converter should not permit right-chaining or unsafe casts.

The root provider supertype cannot include its own common methods, since these may conflict between things that provide two values (e.g. something declaring both a name and a size)