using System;
namespace BepInEx.Configuration
{
///
/// Base type of all classes representing and enforcing acceptable values of config settings.
///
public abstract class AcceptableValueBase
{
/// Type of values that this class can Clamp.
protected AcceptableValueBase(Type valueType)
{
ValueType = valueType;
}
///
/// Change the value to be acceptable, if it's not already.
///
public abstract object Clamp(object value);
///
/// Check if the value is an acceptable value.
///
public abstract bool IsValid(object value);
///
/// Type of the supported values.
///
public Type ValueType { get; }
///
/// Get the string for use in config files.
///
public abstract string ToSerializedString();
}
}