com.huaweicloud.sdk.imagesearch.v2.model.ItemSource Maven / Gradle / Ivy
package com.huaweicloud.sdk.imagesearch.v2.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.function.Consumer;
/**
* 数据的元信息,不同数据包含的字段可能不同。
*/
public class ItemSource {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "desc")
private String desc;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "custom_tags")
private Map customTags = null;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "custom_num_tags")
private Map customNumTags = null;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "keywords")
private List keywords = null;
public ItemSource withDesc(String desc) {
this.desc = desc;
return this;
}
/**
* 数据描述信息。
* @return desc
*/
public String getDesc() {
return desc;
}
public void setDesc(String desc) {
this.desc = desc;
}
public ItemSource withCustomTags(Map customTags) {
this.customTags = customTags;
return this;
}
public ItemSource putCustomTagsItem(String key, String customTagsItem) {
if (this.customTags == null) {
this.customTags = new HashMap<>();
}
this.customTags.put(key, customTagsItem);
return this;
}
public ItemSource withCustomTags(Consumer