package com.yidianling.home.constract

import com.ydl.ydlcommon.mvp.base.IView
import com.yidianling.home.model.bean.*

/**
 * @author <a href="https://www.jianshu.com/u/c1e5310dd724">xujian</a>
 * @描述: 壹点灵首页约束类
 * @Copyright Copyright (c) 2019
 * @Company 壹点灵
 * @date 2019/02/13
 */
class IHomeContract {

    interface View : IView {
        /**
         * 首页数据回调接口
         */
        fun homeDataResponse(list: MutableList<HomePagerDataBean>)

        /**
         * 头部数据回调
         */
        fun homeHeadResponse(homeHeaderBean: HomeHeaderBean)

        /**
         * 首页数据请求失败接口
         */
        fun homeDataFail(msg: String)

        /**
         * 获取倾述数据回调
         */
        fun confideDataResponse(data: HomeConfideBean, selectPosition: Int)

        /**
         * 获取咨询数据回调
         */
        fun consultDataResponse(data: HomeConsultBean, selectPosition: Int)

        /**
         * 问答模块数据回调
         */
        fun askDataResponse(data: HomeAskBean, position: Int)

        /**
         * 首页问答 - 点赞
         */
        fun askZan(position: Int, index: Int, id: String)

        /**
         * 首页问答 - 关注
         */
        fun askFocus(position: Int, id: String)

        /**
         * 获取倾述列表数据
         * @param type 倾述类型
         * @param selectPosition 选中的position
         */
        fun getConfideData(type: String, selectPosition: Int)

        /**
         * 获取咨询列表数据
         */
        fun getConsultData(type: String, selectPosition: Int)

        fun showHomeProgress()

        fun showRefreshLayout()

        fun dismissHomeProgress()

        fun startAnim()

        fun endAnim()

        fun resetModuleTabPosition()

        fun getSearchContent() : String

    }
}