1 package de.dlr.shepard.neo4Core.io;
2
3 import de.dlr.shepard.neo4Core.entities.BasicReference;
4 import lombok.Data;
5 import lombok.EqualsAndHashCode;
6 import lombok.NoArgsConstructor;
7 import org.eclipse.microprofile.openapi.annotations.media.Schema;
8
9 @Data
10 @EqualsAndHashCode(callSuper = true)
11 @NoArgsConstructor
12 @Schema(name = "BasicReference")
13 public class BasicReferenceIO extends BasicEntityIO {
14
15 @Schema(readOnly = true)
16 private long dataObjectId;
17
18 @Schema(readOnly = true)
19 private String type;
20
21 public BasicReferenceIO(BasicReference ref) {
22 super(ref);
23 this.type = ref.getType();
24 this.dataObjectId = ref.getDataObject().getShepardId();
25 }
26 }