Fized code and regenerated documentation

This commit is contained in:
Luca Frosini 2023-05-03 09:20:58 +02:00
parent 9cc8d11196
commit 6b505c059a
4 changed files with 85 additions and 87 deletions

View File

@ -291,23 +291,23 @@ DescriptiveMetadataFacet captures information on descriptive metadata to be asso
.. table:: **DescriptiveMetadataFacet** ``extends`` **Facet**
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Properties |
+=================+==============+========================================================+=================================================================================+=======================================================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| metadata | ValueSchema | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | A metadata record representing the descriptive metadata according to the schema |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| **Known Usage** |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| **Source** | **Relation** | **Multiplicity** | **Target** | **Description** |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Dataset | ConsistsOf | 0..n | DescriptiveMetadataFacet | Any descriptive information associated with the dataset, e.g. for discovery purposes. |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Schema | ConsistsOf | 0..n | DescriptiveMetadataFacet | |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Service | ConsistsOf | 0..n | DescriptiveMetadataFacet | Any descriptive information associated with the service, e.g. for discovery purposes. |
+-----------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Properties |
+=====================+==============+========================================================+=================================================================================+=======================================================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| descriptiveMetadata | ValueSchema | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | A metadata record representing the descriptive metadata according to the schema |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| **Known Usage** |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| **Source** | **Relation** | **Multiplicity** | **Target** | **Description** |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Dataset | ConsistsOf | 0..n | DescriptiveMetadataFacet | Any descriptive information associated with the dataset, e.g. for discovery purposes. |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Schema | ConsistsOf | 0..n | DescriptiveMetadataFacet | |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
| Service | ConsistsOf | 0..n | DescriptiveMetadataFacet | Any descriptive information associated with the service, e.g. for discovery purposes. |
+---------------------+--------------+--------------------------------------------------------+---------------------------------------------------------------------------------+---------------------------------------------------------------------------------------+
The **DescriptiveMetadataFacet** current version is 1.0.0.
@ -368,7 +368,7 @@ IdentifierFacet captures information on identifiers (other than the ones automat
+=======================+================+======================================================================================================+=========================================================+==============================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+-----------------------+----------------+------------------------------------------------------------------------------------------------------+---------------------------------------------------------+--------------------------------------------------------------+
| type | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` ``Regex:^(URI|DOI|IRI|URL|URN|UUID|STRING)$`` | The typology of identifier |
| identificationType | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` ``Regex:^(URI|DOI|IRI|URL|URN|UUID|STRING)$`` | The typology of identifier |
+-----------------------+----------------+------------------------------------------------------------------------------------------------------+---------------------------------------------------------+--------------------------------------------------------------+
| value | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | The identifier |
+-----------------------+----------------+------------------------------------------------------------------------------------------------------+---------------------------------------------------------+--------------------------------------------------------------+
@ -553,23 +553,21 @@ ProvenanceFacet captures information on provenance/lineage of the entire resourc
.. table:: **ProvenanceFacet** ``extends`` **Facet**
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| Properties |
+=================+==============+=======================================================================================================================================================+======================================================================+====================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| relationship | String | ``Mandatory:false`` ``ReadOnly:false`` ``NotNull:false`` ``Regex:^(wasDerivedFrom|wasGeneratedBy)$`` | Relationship with the resource indicated by UUID. |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| reference | String | ``Mandatory:false`` ``ReadOnly:false`` ``NotNull:false`` ``Regex:^([a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}){1}$`` | UUID of the referenced resource. |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| document | ValueSchema | ``Mandatory:false`` ``ReadOnly:false`` ``NotNull:false`` | Provenance Document, e.g., an XML according to the reference schema. |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| **Known Usage** |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| **Source** | **Relation** | **Multiplicity** | **Target** | **Description** |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| Dataset | ConsistsOf | 0..n | ProvenanceFacet | Any provenance record associated with the dataset. |
+-----------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| Properties |
+=================+==============+======================================================================================================+======================================================================+====================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| relationship | String | ``Mandatory:false`` ``ReadOnly:false`` ``NotNull:false`` ``Regex:^(wasDerivedFrom|wasGeneratedBy)$`` | Relationship with the resource indicated by ID. |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| document | ValueSchema | ``Mandatory:false`` ``ReadOnly:false`` ``NotNull:false`` | Provenance Document, e.g., an XML according to the reference schema. |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| **Known Usage** |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| **Source** | **Relation** | **Multiplicity** | **Target** | **Description** |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
| Dataset | ConsistsOf | 0..n | ProvenanceFacet | Any provenance record associated with the dataset. |
+-----------------+--------------+------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+----------------------------------------------------+
The **ProvenanceFacet** current version is 1.0.0.

View File

@ -21,30 +21,50 @@ Changelog:
* **1.0.0**: First Version.
Header
------
Encrypted
---------
This type is used to properly manage values must be stored safely (e.g. encrypted) in the IS.
.. table:: **Encrypted** ``extends`` **Property**
+-------+--------+--------------------------------------------------------+-------------------------------------+
| Name | Type | Attributes | Description |
+=======+========+========================================================+=====================================+
| value | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | The value to store safely in the IS |
+-------+--------+--------------------------------------------------------+-------------------------------------+
The **Encrypted** current version is 1.0.0.
Changelog:
* **1.0.0**: First Version.
Metadata
--------
This type provides metadata per every IdentifiableElement
.. table:: **Header** ``extends`` **Property**
.. table:: **Metadata** ``extends`` **Property**
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| Name | Type | Attributes | Description |
+================+========+====================================================================================================================================================+=========================================================================================================================================+
| createdBy | String | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` | The user that created the Entity or the Relation. It is initialized at Creation Time. |
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| creationTime | Date | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` | Creation time. It is represented in the format yyyy-MM-dd HH:mm:ss.SSS Z. |
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| lastUpdateBy | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | The user that made the last update to the Entity or the Relation. At Creation Time, it assumes the same value of createdBy. |
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| lastUpdateTime | Date | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | Last Update time. At creation time it assumes the same value of creationTime. It is represented in the format yyyy-MM-dd HH:mm:ss.SSS Z |
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| uuid | String | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` ``Regex:^([a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}){1}$`` | This UUID is be used to identify the Entity or the Relation univocally. |
+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
+----------------+--------+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| Name | Type | Attributes | Description |
+================+========+========================================================+=========================================================================================================================================+
| createdBy | String | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` | The user that created the Entity or the Relation. It is initialized at Creation Time. |
+----------------+--------+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| creationTime | Date | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` | Creation time. It is represented in the format yyyy-MM-dd HH:mm:ss.SSS Z. |
+----------------+--------+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| lastUpdateBy | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | The user that made the last update to the Entity or the Relation. At Creation Time, it assumes the same value of createdBy. |
+----------------+--------+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
| lastUpdateTime | Date | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | Last Update time. At creation time it assumes the same value of creationTime. It is represented in the format yyyy-MM-dd HH:mm:ss.SSS Z |
+----------------+--------+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
The **Header** current version is 1.0.0.
The **Metadata** current version is 1.0.0.
Changelog:
@ -78,28 +98,6 @@ Changelog:
* **1.0.0**: First Version;
Vault
-----
This type is used to properly manage values must be stored safely (e.g. encrypted) in the IS.
.. table:: **Vault** ``extends`` **Property**
+-------+--------+--------------------------------------------------------+-------------------------------------+
| Name | Type | Attributes | Description |
+=======+========+========================================================+=====================================+
| value | String | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | The value to store safely in the IS |
+-------+--------+--------------------------------------------------------+-------------------------------------+
The **Vault** current version is 1.0.0.
Changelog:
* **1.0.0**: First Version.
Entity
======
@ -108,13 +106,15 @@ This is the base type for any Entity
.. table:: **Entity**
+------------+----------+--------------------------------------------------------+--------------------------------------------------------------------------------------------+
| Properties |
+============+==========+========================================================+============================================================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+------------+----------+--------------------------------------------------------+--------------------------------------------------------------------------------------------+
| header | Header | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | Metadata associated with the instance that is automatically created/updated by the system. |
+------------+----------+--------------------------------------------------------+--------------------------------------------------------------------------------------------+
+------------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+
| Properties |
+============+==========+====================================================================================================================================================+============================================================================================+
| **Name** | **Type** | **Attributes** | **Description** |
+------------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+
| id | String | ``Mandatory:true`` ``ReadOnly:true`` ``NotNull:true`` ``Regex:^([a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}){1}$`` | This UUID is be used to identify the instance univocally. |
+------------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+
| metadata | Metadata | ``Mandatory:true`` ``ReadOnly:false`` ``NotNull:true`` | Metadata associated with the instance that is automatically created/updated by the system. |
+------------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------+
The **Entity** current version is 1.0.0.

View File

@ -28,7 +28,7 @@
<dependency>
<groupId>org.gcube.distribution</groupId>
<artifactId>gcube-bom</artifactId>
<version>2.2.0-SNAPSHOT</version>
<version>2.4.0-SNAPSHOT</version>
<type>pom</type>
<scope>import</scope>
</dependency>

View File

@ -278,7 +278,7 @@ public abstract class Documentation {
name.setText(propertyDefinition.getName());
row.appendCell(name);
Cell type = new Cell();
type.setText(propertyDefinition.getType());
type.setText(propertyDefinition.getPropertyType());
row.appendCell(type);
Cell attributes = new Cell();
attributes.setText(getPropertyAttributes(propertyDefinition));
@ -346,14 +346,14 @@ public abstract class Documentation {
stringBuffer.append("**");
stringBuffer.append(type.getName());
stringBuffer.append("**");
Set<String> superClasses = type.getSuperClasses();
Set<String> superTypes = type.getTypeSuperTypes();
if(superClassToBeExcluded!=null) {
superClasses.remove(superClassToBeExcluded);
superTypes.remove(superClassToBeExcluded);
}
if(superClasses.size()>0){
if(superTypes.size()>0){
stringBuffer.append(" ``extends`` ");
boolean first = true;
for(String superClass : superClasses) {
for(String superClass : superTypes) {
if(!first) {
stringBuffer.append(", ");
}else {