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.Map;

public class MeMaintenance extends JSONEntity implements Serializable {

    @JsonProperty
    @Label(en="Maintenance agency")
    @Description(en= "Organization or other expert body that maintains the resource.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private Map<String, String> maintenanceAgency;

    @JsonProperty
    @Label(en="Update")
    @Description(en= "This section involves maintenance operations concerning the periodic update of the resource.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private SeUpdate seUpdate;

    @JsonProperty
    @Label(en="MAINTENANCE")
    @Description(en= "This section involves maintenance operations concerning the periodic update of metadata to ensure that the resource is properly described.")
    @Order(-1)
    @Format(Format.FORMAT.string)
    private SeMetadataMaintenance seMetadataMaintenance;


    public Map<String, String> getMaintenanceAgency() {
        return maintenanceAgency;
    }

    public void setMaintenanceAgency(Map<String, String> maintenanceAgency) {
        this.maintenanceAgency = maintenanceAgency;
    }

    public SeUpdate getSeUpdate() {
        return seUpdate;
    }
    @Embedded
    public void setSeUpdate(SeUpdate seUpdate) {
        this.seUpdate = seUpdate;
    }

    public SeMetadataMaintenance getSeMetadataMaintenance() {
        return seMetadataMaintenance;
    }
    @Embedded
    public void setSeMetadataMaintenance(SeMetadataMaintenance seMetadataMaintenance) {
        this.seMetadataMaintenance = seMetadataMaintenance;
    }
}

@@ -645,36 +645,35 @@
 e.%22)%0A    @Order(
--
 1)%0A
+
     @Format(Form
@@ -904,34 +904,33 @@
 e.%22)%0A    @Order(
--1
+2
 )%0A    @Format(Fo
@@ -1019,18 +1019,27 @@
 n=%22M
-AINTENANCE
+etadata Maintenance
 %22)%0A 
@@ -1215,10 +1215,9 @@
 der(
--1
+3
 )%0A  

Update MeMaintenance.java