#ifndef SMELTING_RULE_HPP_
#define SMELTING_RULE_HPP_

#include <ItemStack/ItemStack.hpp>

/**
 * @brief Represents a smelting rule.
 * 
 * This is used to define which items convert into which items in pots, electric furnace,
 * etc.
 */
class SmeltingRule
{
public:
    virtual ~SmeltingRule() = default;

    /**
     * @brief Returns true if the specified stack is a valid smelting input under this rule.
     */
    virtual bool canSmelt(ItemStack &stack) = 0;

    /**
     * @brief Get the stack resulting from smelting the input stack.
     * 
     * This is only called if `canSmelt()` returned true on `input`!
     * 
     * @param input The input stack.
     * @return The resulting stack from smelting.
     */
    virtual ItemStack getSmeltingResult(ItemStack &input) = 0;
};

#endif