package `in`.techware.carrefour.model

/**
 * Created by Jemsheer K D on 23 June, 2018.
 * Package `in`.techware.carrefour.model
 * Project Carrefour
 */
class MenuListBean {

    var menus: ArrayList<MenuBean> = arrayListOf()

    fun getMenuFromCode(code: String): MenuBean? {

        for (bean in menus) {
            if (bean.code == code) {
                return bean
            }
        }
        return null
    }

    fun getMenuFromID(id: String): MenuBean? {

        for (bean in menus) {
            if (bean.id == id) {
                return bean
            }
        }
        return null
    }

}