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

78 lines
2.8 KiB
Java
Raw Normal View History

2020-07-08 00:06:57 +02:00
package de.twomartens.oparlservice.entity;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
2020-07-08 00:06:57 +02:00
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.time.ZonedDateTime;
2020-07-08 00:06:57 +02:00
import java.util.List;
@Builder
2020-07-08 00:06:57 +02:00
@Getter
@ToString
@EqualsAndHashCode
2020-07-08 00:06:57 +02:00
@AllArgsConstructor(access = AccessLevel.PRIVATE)
@NoArgsConstructor(force = true, access = AccessLevel.PRIVATE)
@JsonInclude(JsonInclude.Include.NON_NULL)
public class System {
@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
@JsonFormat(shape = JsonFormat.Shape.STRING)
@Schema(required = true, description = "Date and time of the creation of the object")
private final ZonedDateTime created;
@NonNull
@JsonFormat(shape = JsonFormat.Shape.STRING)
@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;
2020-07-08 00:06:57 +02:00
@NonNull
@Schema(required = true, description = "URL to the OParl specification supported by this service")
private final String oparlVersion;
@Schema(description = "Contains a list of URLs to System objects supporting another Oparl version", nullable = true)
2020-07-08 00:06:57 +02:00
private final List<String> otherOparlVersions;
@NonNull
@Schema(required = true, description = "URL to the list of all bodies existing in this system")
private final String body;
@Schema(description = "User friendly name for this system", nullable = true)
2020-07-08 00:06:57 +02:00
private final String name;
@Schema(description = "E-Mail-Address for requests related to the OParl-API", nullable = true)
2020-07-08 00:06:57 +02:00
private final String contactEmail;
@Schema(description = "Name of the contact person who can be reached by contactEmail", nullable = true)
2020-07-08 00:06:57 +02:00
private final String contactName;
@Schema(description = "URL of the website of the parliamentary information system", nullable = true)
2020-07-08 00:06:57 +02:00
private final String website;
@Schema(description = "URL to the website of the software creator of the OParl server software", nullable = true)
2020-07-08 00:06:57 +02:00
private final String vendor;
@Schema(description = "URL to information about the OParl server software utilized by this system", nullable = true)
2020-07-08 00:06:57 +02:00
private final String product;
}