Class PotionEffectPersister

java.lang.Object
net.citizensnpcs.api.persistence.PotionEffectPersister
All Implemented Interfaces:
Persister<PotionEffect>

public class PotionEffectPersister extends Object implements Persister<PotionEffect>
  • Constructor Details

    • PotionEffectPersister

      public PotionEffectPersister()
  • Method Details

    • create

      public PotionEffect create(DataKey root)
      Description copied from interface: Persister
      Creates an object instance from the given DataKey. Should not return null unless no data is present.
      Specified by:
      create in interface Persister<PotionEffect>
      Parameters:
      root - The root key to load from
      Returns:
      The created instance, or null if no data was present
    • save

      public void save(PotionEffect effect, DataKey root)
      Description copied from interface: Persister
      Saves the object instance to the given DataKey.
      Specified by:
      save in interface Persister<PotionEffect>
      Parameters:
      effect - The object instance to save
      root - The key to save into