package ch.dissem.yaep.domain

class GameCell<C : ItemClass<C>>(
    var selection: Item<C>?,
    val solution: Item<C>,
    val options: MutableList<Item<C>>
)
//{
//    val options = options.toMutableStateList()
//    var selection by mutableStateOf(selection)
//}

fun <C : ItemClass<C>> GameCell<C>?.mayBe(item: Item<C>) =
    this != null && (selection == item || (selection == null && options.contains(item)))
