oparl-service/oparl-server/src/main/java/de/twomartens/oparlservice/entity/CommonFields.java

45 lines
1.4 KiB
Java

package de.twomartens.oparlservice.entity;
import io.swagger.v3.oas.annotations.OpenAPIDefinition;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import lombok.experimental.SuperBuilder;
import java.time.ZonedDateTime;
@SuperBuilder
@Getter
@ToString
@EqualsAndHashCode
@AllArgsConstructor(access = AccessLevel.PROTECTED)
@NoArgsConstructor(force = true, access = AccessLevel.PROTECTED)
public class CommonFields {
@NonNull
@Schema(required = true, description = "The unique identifier of the object")
private final String id;
@NonNull
@Schema(required = true, description = "Namespace URL to the object type schema")
private final String type;
@NonNull
@Schema(required = true, description = "Date and time of the creation of the object")
private final ZonedDateTime created;
@NonNull
@Schema(required = true, description = "Date and time of the last update of the object")
private final ZonedDateTime modified;
@Schema(description = "URL to the license", nullable = true)
private String license;
@Schema(description = "Categorization of the object", nullable = true)
private String keyword;
@Schema(description = "URL of a website that presents the object in the browser", nullable = true)
private String web;
@Schema(description = "True, if the object was deleted")
private final boolean deleted;
}