Fixing model

This commit is contained in:
Luca Frosini 2021-03-02 15:06:08 +01:00
parent 5b22075c11
commit 0118d0c73d
2 changed files with 3 additions and 5 deletions

View File

@ -4,15 +4,14 @@
package org.gcube.resourcemanagement.model.reference.entities.resources;
import org.gcube.com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import org.gcube.informationsystem.types.annotations.RelatedResourcesEntry;
import org.gcube.informationsystem.types.annotations.ResourceSchema;
import org.gcube.informationsystem.types.annotations.ResourceSchemaEntry;
import org.gcube.informationsystem.types.annotations.RelatedResourcesEntry;
import org.gcube.informationsystem.types.reference.Change;
import org.gcube.informationsystem.types.reference.TypeMetadata;
import org.gcube.informationsystem.utils.TypeVersion;
import org.gcube.resourcemanagement.model.impl.entities.resources.ConfigurationTemplateImpl;
import org.gcube.resourcemanagement.model.reference.entities.facets.IdentifierFacet;
import org.gcube.resourcemanagement.model.reference.entities.facets.SimplePropertyFacet;
import org.gcube.resourcemanagement.model.reference.relations.consistsof.IsIdentifiedBy;
import org.gcube.resourcemanagement.model.reference.relations.isrelatedto.IsConfiguredBy;
import org.gcube.resourcemanagement.model.reference.relations.isrelatedto.IsCustomizedBy;
@ -30,8 +29,7 @@ import org.gcube.resourcemanagement.model.reference.relations.isrelatedto.IsDeri
@JsonDeserialize(as=ConfigurationTemplateImpl.class)
@ResourceSchema(
facets={
@ResourceSchemaEntry(relation=IsIdentifiedBy.class, facet=IdentifierFacet.class, min=1),
@ResourceSchemaEntry(facet=SimplePropertyFacet.class, min=1)
@ResourceSchemaEntry(relation=IsIdentifiedBy.class, facet=IdentifierFacet.class, min=1)
},
resources = {
@RelatedResourcesEntry(source=Configuration.class, relation=IsDerivationOf.class, target=ConfigurationTemplate.class),

View File

@ -24,7 +24,7 @@ import org.gcube.resourcemanagement.model.reference.relations.consistsof.IsIdent
@JsonDeserialize(as=GCubeResourceImpl.class)
@ResourceSchema(
facets={
@ResourceSchemaEntry(relation=IsIdentifiedBy.class, min=1, description=" Any Resource has at least one Facet which in some way allow to identify the Resource per se.")
@ResourceSchemaEntry(relation=IsIdentifiedBy.class, min=1, max=1, description=" Any Resource has at least one Facet which in some way allow to identify the Resource per se.")
}
)
@TypeMetadata(