Interface ConfigValueAdapter<T>

Type Parameters:
T - target Java type
All Known Implementing Classes:
EnumAdapter

public interface ConfigValueAdapter<T>
Adapter for custom types used in configs. Provides explicit serialize/deserialize hooks to and from raw config values.
  • Method Summary

    Modifier and Type
    Method
    Description
    Deserialize raw config value into target type.
    serialize(T value)
    Serialize target type back to a config-friendly structure.
  • Method Details

    • deserialize

      T deserialize(Object value)
      Deserialize raw config value into target type.
      Parameters:
      value - raw value (String/Map/List/etc.)
      Returns:
      deserialized instance or null if value cannot be parsed
    • serialize

      Object serialize(T value)
      Serialize target type back to a config-friendly structure.
      Parameters:
      value - value to serialize
      Returns:
      raw representation (String/Map/List/etc.)