package com.gh.gamecenter.common.entity

import android.os.Parcelable
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize

@Parcelize
open class LinkEntity(
    var name: String? = "", // tag
    var title: String? = "",
    var image: String? = "",
    @SerializedName("target", alternate = ["link", "link_id"])
    var link: String? = "",
    @SerializedName("type", alternate = ["link_type"])
    var type: String? = "",
    var icon: String = "",
    @SerializedName("game_icon")
    var gameIcon: String? = "",
    @SerializedName("game_icon_subscript")
    var gameIconSubscript: String? = "",
    var text: String? = "",
    @SerializedName("link_text")
    var linkText: String? = "",//游戏详情弹窗，link_type兼容旧版本用
    var value: String? = "",
    @SerializedName("community_id")
    var communityId: String? = "",
    @SerializedName("link_community", alternate = ["community"])
    var community: CommunityEntity? = CommunityEntity(),
    var display: Display? = null, // 板块
    @SerializedName("close_button")
    var closeButton: String = "open",//用户判断h5游戏关闭按钮是否显示，hide(隐藏)、open(开启)
    @SerializedName("button_link")
    var buttonLink: Boolean = false,
    var toolkit: ToolBoxEntity? = ToolBoxEntity(),
    @SerializedName("activity_id")
    var activityId: String = "",
    var style: String = "",
    @SerializedName("game_id")
    var gameId: String = "",

    //本地字段 (埋点用)
    var blockId: String = "",
    var blockName: String = "",
    // 本地字段 (关联的曝光)
//    var exposureEvent: ExposureEvent? = null
) : Parcelable {

    @Parcelize
    data class LinkToolBoxEntity(
        var url: String? = null
    ) : Parcelable
}