AccessionIdDTO.java

/*
 * Copyright 2025 Global Crop Diversity Trust
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.genesys.server.model.elastic;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Getter;
import lombok.Setter;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.util.List;
import java.util.Set;
import java.util.UUID;

@Getter
@Setter
public class AccessionIdDTO {

	private UUID uuid;

	@Field(type = FieldType.Keyword)
	private Set<UUID> lists;

	@Field(type = FieldType.Integer)
	private Set<Integer> storage;

	@Field(type = FieldType.Keyword)
	private Set<String> duplSite;

	@Field(type = FieldType.Object)
	private AccessionCollectInfo coll;

	@Field(type = FieldType.Nested)
	private List<AccessionAliasInfo> aliases;

	@Field(type = FieldType.Nested)
	private List<AccessionRemarkInfo> remarks;

	@Field(type = FieldType.Keyword)
	private Set<String> breederCode;

	@Field(type = FieldType.Text)
	private Set<String> breederName;

	private int imageCount;

	private long subsetCount;

	private long datasetCount;

	// Geo
	@Field(store = true)
	private Double longitude;

	@Field(store = true)
	private Double latitude;

	private Double elevation;

	private Double coordinateUncertainty;

	private String coordinateDatum;

	private String georeferenceMethod;

	private Long tileIndex;

	private Integer tileIndex3min;

	@JsonInclude(JsonInclude.Include.NON_EMPTY)
	@Field(type = FieldType.Object)
	private TileClimateInfo climate;

	private AccessionGeoInfo geo;
}