ConsultantRamImpl.kt 618 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
package com.yidianling.consultant.data

import com.yidianling.router.consultant.Keyworks

class ConsultantRamImpl private constructor(): ConsultantRam {

    override fun setHotSearch(hotSearch: MutableList<Keyworks>) {
        this.hotSearch = hotSearch!!
    }

    companion object {
        fun getInstance(): ConsultantRamImpl {
            return Holder.INSTANCE
        }
    }

    private var hotSearch: MutableList<Keyworks> = ArrayList()

    override fun getHotSearch(): MutableList<Keyworks> {
        return hotSearch
    }


    private object Holder {
        val INSTANCE = ConsultantRamImpl()
    }
}