package de.twomartens.oparlservice.entity; import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.v3.oas.annotations.media.Schema; import lombok.*; import lombok.experimental.SuperBuilder; import java.time.LocalDate; import java.util.List; @SuperBuilder @Getter @ToString @EqualsAndHashCode(callSuper = true) @AllArgsConstructor(access = AccessLevel.PRIVATE) @NoArgsConstructor(force = true, access = AccessLevel.PRIVATE) @Schema(allOf = CommonFields.class) public class Organization extends CommonFields { @Schema(description = "URL to body this legislative term belongs to", nullable = true) private final String body; @Schema(description = "official long name of the organization", nullable = true) private final String name; @Schema(description = "short name of the organization", nullable = true) private final String shortName; @Schema(description = "List of URLs to memberships", nullable = true) private final List membership; @Schema(description = "URL to list of meetings of this organization", nullable = true) private final String meeting; @Schema(description = "URL to list of consultations of this organization", nullable = true) private final String consultation; @Schema(description = "List of positions available in this organization", nullable = true) private final List post; @Schema(description = "URL to a parent organization", nullable = true) private final String subOrganizationOf; @Schema(description = "rough categorization of the organization", nullable = true, allowableValues = "Gremium, Partei, Fraktion, Verwaltungsbereich, externes Gremium, Institution, Sonstiges") private final String organizationType; @JsonFormat(shape = JsonFormat.Shape.STRING) @Schema(description = "founding date of the organization", nullable = true) private final LocalDate startDate; @JsonFormat(shape = JsonFormat.Shape.STRING) @Schema(description = "date of the last day of existance of the organization", nullable = true) private final LocalDate endDate; @Schema(description = "URL to the website of the organization", nullable = true) private final String website; @Schema(description = "location of the organization", nullable = true) private final Location location; @Schema(description = "URL to external OParl body describing this organization", nullable = true) private final String externalBody; }