package com.uas.search.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * 品牌简要信息，只用于索引的创建与查询
 * 
 * @author sunyj
 * @since 2016年7月7日 下午5:48:32
 */
@Entity
@Table(name = "product$brand")
public class Brand implements Serializable {

	/**
	 * 序列号
	 */
	private static final long serialVersionUID = 1L;

	/**
	 * id
	 */
	@Id
	@Column(name = "br_id")
	private Long id;

	/**
	 * uuid
	 */
	@Column(name = "br_uuid", unique = true)
	private String uuid;

	/**
	 * 品牌中文名称
	 */
	@Column(name = "br_name_cn")
	private String nameCn;

	/**
	 * 品牌英文名称
	 */
	@Column(name = "br_name_en")
	private String nameEn;

	/**
	 * 访问量
	 */
	@Column(name = "br_visit_count")
	private Long visitCount;

	/**
	 * 搜索次数
	 */
	@Column(name = "br_search_count")
	private Long searchCount;

	/**
	 * 权重
	 */
	@Column(name = "br_weight")
	private Double weight;

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getUuid() {
		return uuid;
	}

	public void setUuid(String uuid) {
		this.uuid = uuid;
	}

	public String getNameCn() {
		return nameCn;
	}

	public void setNameCn(String nameCn) {
		this.nameCn = nameCn;
	}

	public String getNameEn() {
		return nameEn;
	}

	public void setNameEn(String nameEn) {
		this.nameEn = nameEn;
	}

	public Long getVisitCount() {
		return visitCount;
	}

	public void setVisitCount(Long visitCount) {
		this.visitCount = visitCount;
	}

	public Long getSearchCount() {
		return searchCount;
	}

	public void setSearchCount(Long searchCount) {
		this.searchCount = searchCount;
	}

	public Double getWeight() {
		return weight;
	}

	public void setWeight(Double weight) {
		this.weight = weight;
	}

	@Override
	public String toString() {
		return "Brand{" +
				"id=" + id +
				", uuid='" + uuid + '\'' +
				", nameCn='" + nameCn + '\'' +
				", nameEn='" + nameEn + '\'' +
				", visitCount=" + visitCount +
				", searchCount=" + searchCount +
				", weight=" + weight +
				'}';
	}
}
