package com.house.wallpapers.mybean;

import androidx.annotation.Nullable;

import java.io.Serializable;

import io.objectbox.annotation.Entity;
import io.objectbox.annotation.Id;

@Entity
public class Data implements Serializable {

    @Id
    private long id;

    private String categoryName;

    private String imId;

    private String description;

    private String fullUrl;

    private String previewUrl1080;
    private String previewUrl400;
    private String previewUrl200;

    private String authorName;

    private String authorHeader;

    private String authorHtml;

    private boolean isLike;

    private boolean isDownload;

    public boolean isLike() {
        return isLike;
    }

    public void setLike(boolean like) {
        isLike = like;
    }

    public boolean isDownload() {
        return isDownload;
    }

    public void setDownload(boolean download) {
        isDownload = download;
    }

    public long getId() {
        return id;
    }

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

    public String getImId() {
        return imId;
    }

    public void setImId(String imId) {
        this.imId = imId;
    }

    public String getCategoryName() {
        return categoryName;
    }

    public void setCategoryName(String categoryName) {
        this.categoryName = categoryName;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getFullUrl() {
        return fullUrl;
    }

    public void setFullUrl(String fullUrl) {
        this.fullUrl = fullUrl;
    }

    public String getPreviewUrl1080() {
        return previewUrl1080;
    }

    public void setPreviewUrl1080(String previewUrl1080) {
        this.previewUrl1080 = previewUrl1080;
    }

    public String getPreviewUrl400() {
        return previewUrl400;
    }

    public void setPreviewUrl400(String previewUrl400) {
        this.previewUrl400 = previewUrl400;
    }

    public String getPreviewUrl200() {
        return previewUrl200;
    }

    public void setPreviewUrl200(String previewUrl200) {
        this.previewUrl200 = previewUrl200;
    }

    public String getAuthorName() {
        return authorName;
    }

    public void setAuthorName(String authorName) {
        this.authorName = authorName;
    }

    public String getAuthorHeader() {
        return authorHeader;
    }

    public void setAuthorHeader(String authorHeader) {
        this.authorHeader = authorHeader;
    }

    public String getAuthorHtml() {
        return authorHtml;
    }

    public void setAuthorHtml(String authorHtml) {
        this.authorHtml = authorHtml;
    }

    @Override
    public boolean equals(@Nullable Object obj) {
        if (obj instanceof Data) {
            Data obj1 = (Data) obj;
            return obj1.getImId() != null && obj1.getImId().equals(imId);
        }
        return false;
    }
}