package com.ecep.contract.converter;

import com.ecep.contract.model.BaseEnumEntity;
import javafx.util.StringConverter;

public class EnumEntityStringConverter<E extends Enum<?>, T extends BaseEnumEntity<E>> extends StringConverter<T> {

    @Override
    public String toString(T object) {
        return object == null ? "" : object.getValue();
    }

    @Override
    public T fromString(String string) {
        return null;
        // return service.findByName(string);
    }
}
