diff --git a/CHANGELOG.md b/CHANGELOG.md
index fbab38a..2d69f82 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,10 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
# Changelog for Information System Model
+## [v7.1.0-SNAPSHOT]
+
+- Improved support for model knowledge [#25922]
+
## [v7.0.0]
- Reorganized E/R format [#24992]
diff --git a/pom.xml b/pom.xml
index a234795..b4f9fae 100644
--- a/pom.xml
+++ b/pom.xml
@@ -10,7 +10,7 @@
org.gcube.information-system
information-system-model
- 7.0.0
+ 7.1.0-SNAPSHOT
Information System Model
Information System Model is the reference model of the gCube Information System
jar
diff --git a/src/main/java/org/gcube/informationsystem/discovery/knowledge/ClassInformation.java b/src/main/java/org/gcube/informationsystem/discovery/knowledge/ClassInformation.java
index 04b32f3..22fb4c9 100644
--- a/src/main/java/org/gcube/informationsystem/discovery/knowledge/ClassInformation.java
+++ b/src/main/java/org/gcube/informationsystem/discovery/knowledge/ClassInformation.java
@@ -3,6 +3,7 @@ package org.gcube.informationsystem.discovery.knowledge;
import java.util.LinkedHashSet;
import java.util.Set;
+import org.gcube.informationsystem.base.reference.AccessType;
import org.gcube.informationsystem.base.reference.Element;
import org.gcube.informationsystem.tree.NodeInformation;
import org.gcube.informationsystem.types.TypeMapper;
@@ -35,4 +36,14 @@ public class ClassInformation implements NodeInformation> {
return ret;
}
+ @Override
+ public AccessType getAccessType(Class clz) {
+ return AccessType.getAccessType(clz);
+ }
+
+ @Override
+ public Class getRoot(AccessType accessType) {
+ return accessType.getTypeClass();
+ }
+
}
diff --git a/src/main/java/org/gcube/informationsystem/knowledge/ModelKnowledge.java b/src/main/java/org/gcube/informationsystem/knowledge/ModelKnowledge.java
new file mode 100644
index 0000000..1f75afb
--- /dev/null
+++ b/src/main/java/org/gcube/informationsystem/knowledge/ModelKnowledge.java
@@ -0,0 +1,147 @@
+package org.gcube.informationsystem.knowledge;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
+
+import org.gcube.informationsystem.base.reference.AccessType;
+import org.gcube.informationsystem.tree.NodeInformation;
+import org.gcube.informationsystem.tree.Tree;
+import org.gcube.informationsystem.types.reference.entities.FacetType;
+import org.gcube.informationsystem.types.reference.entities.ResourceType;
+import org.gcube.informationsystem.types.reference.properties.LinkedEntity;
+import org.gcube.informationsystem.types.reference.properties.PropertyDefinition;
+import org.gcube.informationsystem.types.reference.relations.ConsistsOfType;
+import org.gcube.informationsystem.types.reference.relations.IsRelatedToType;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author Luca Frosini (ISTI - CNR)
+ */
+public class ModelKnowledge> {
+
+ private static final Logger logger = LoggerFactory.getLogger(ModelKnowledge.class);
+
+ protected NI nodeInformation;
+ protected Map> trees;
+ protected Map> usageKnowledges;
+
+ public ModelKnowledge() {
+ reset();
+ }
+
+ private void reset() {
+
+ this.trees = new HashMap<>();
+ this.usageKnowledges = new HashMap<>();
+
+ AccessType[] modelTypes = AccessType.getModelTypes();
+ for(AccessType accessType : modelTypes) {
+ T t = nodeInformation.getRoot(accessType);
+
+ Tree tree = new Tree<>(t, nodeInformation);
+ trees.put(accessType, tree);
+
+ UsageKnowledge> usageKnowledge;
+ if(accessType == AccessType.PROPERTY) {
+ /*
+ * In this case we get the type which uses such a property
+ * and the property definition.
+ * In this way we have a complete overview of the usege of the
+ * property type
+ */
+ usageKnowledge = new UsageKnowledge