package org.fao.fenix.commons.msd.dto.full;

import com.fasterxml.jackson.annotation.JsonProperty;
import org.fao.fenix.commons.annotations.Description;
import org.fao.fenix.commons.annotations.Format;
import org.fao.fenix.commons.annotations.Label;
import org.fao.fenix.commons.annotations.Order;
import org.fao.fenix.commons.msd.dto.JSONEntity;

import javax.persistence.Embedded;
import java.io.Serializable;
import java.util.Date;
import java.util.Map;

public class SeReleasePolicy extends JSONEntity implements Serializable {

    @JsonProperty
    @Label(en="Release calendar")
    @Description(en= "Policy regarding the release of the resource in accordance with the pre-announced schedule. It also provides information on the availability of the release calendar.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private Map<String, String> releaseCalendar;

    @JsonProperty
    @Label(en="Access to the release calendar")
    @Description(en= "Link or references to the release calendar.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private String releaseCalendarAccess;

    @JsonProperty
    @Label(en="Dissemination periodicity")
    @Description(en= "Frequency of data dissemination (e.g. daily, monthly, quarterly, yearly).")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private OjCodeList disseminationPeriodicity;

    @JsonProperty
    @Label(en="Embargo time")
    @Description(en= "Time span between the completion of the production process of statistical data and their publication.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private OjPeriod embargoTime;


    public Map<String, String> getReleaseCalendar() {
        return releaseCalendar;
    }

    public void setReleaseCalendar(Map<String, String> releaseCalendar) {
        this.releaseCalendar = releaseCalendar;
    }

    public String getReleaseCalendarAccess() {
        return releaseCalendarAccess;
    }

    public void setReleaseCalendarAccess(String releaseCalendarAccess) {
        this.releaseCalendarAccess = releaseCalendarAccess;
    }

    public OjCodeList getDisseminationPeriodicity() {
        return disseminationPeriodicity;
    }
    @Embedded
    public void setDisseminationPeriodicity(OjCodeList disseminationPeriodicity) {
        this.disseminationPeriodicity = disseminationPeriodicity;
    }

    public OjPeriod getEmbargoTime() {
        return embargoTime;
    }
    @Embedded
    public void setEmbargoTime(OjPeriod embargoTime) {
        this.embargoTime = embargoTime;
    }
}

@@ -771,36 +771,35 @@
 r.%22)%0A    @Order(
--
 1)%0A
+
     @Format(Form
@@ -1003,34 +1003,33 @@
 r.%22)%0A    @Order(
--1
+2
 )%0A    @Format(Fo
@@ -1253,34 +1253,33 @@
 ).%22)%0A    @Order(
--1
+3
 )%0A    @Format(Fo
@@ -1537,10 +1537,9 @@
 der(
--1
+4
 )%0A  

Update SeReleasePolicy.java