46 lines
1.9 KiB
Java
46 lines
1.9 KiB
Java
package org.gcube.informationsystem.types.reference.entities;
|
|
|
|
import java.util.Set;
|
|
|
|
import org.gcube.informationsystem.base.reference.entities.BaseEntity;
|
|
import org.gcube.informationsystem.types.annotations.ISProperty;
|
|
import org.gcube.informationsystem.types.impl.entities.EntityTypeDefinitionImpl;
|
|
import org.gcube.informationsystem.types.reference.TypeDefinition;
|
|
import org.gcube.informationsystem.types.reference.properties.PropertyDefinition;
|
|
|
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
|
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
|
|
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
|
@JsonDeserialize(as = EntityTypeDefinitionImpl.class)
|
|
public interface EntityTypeDefinition<E extends BaseEntity> extends TypeDefinition, BaseEntity {
|
|
|
|
public static final String NAME = "EntityTypeDefinition"; //EntityTypeDefinition.class.getSimpleName();
|
|
|
|
/* TypeDefinition is just a Java useful class. The type is not created in the IS. Hence the fields must be redefined */
|
|
|
|
@Override
|
|
@ISProperty(name = TypeDefinition.NAME_PROPERTY, readonly = true, mandatory = true, nullable = false)
|
|
public String getName();
|
|
|
|
@Override
|
|
@ISProperty(name = TypeDefinition.DESCRIPTION_PROPERTY, readonly = false, mandatory = true, nullable = false)
|
|
public String getDescription();
|
|
|
|
@Override
|
|
@ISProperty(name = TypeDefinition.ABSTRACT_PROPERTY, readonly = true, mandatory = true, nullable = false)
|
|
public boolean isAbstract();
|
|
|
|
@Override
|
|
@ISProperty(name = TypeDefinition.TYPE_SUPERCLASSES_PROPERTY, readonly = true, mandatory = true, nullable = false)
|
|
public Set<String> getSuperClasses();
|
|
|
|
@Override
|
|
@ISProperty(name = TypeDefinition.PROPERTIES_PROPERTY, readonly = false, mandatory = true, nullable = false)
|
|
public Set<PropertyDefinition> getProperties();
|
|
|
|
/* TypeDefinition is just a Java useful class. The type is not created in the IS. Hence the fields must be redefined */
|
|
|
|
|
|
}
|