General properties

Within AFD 2.0 and the API-framework, SIVI provides a function for exchanging data in a tabular structure.This enables parties to distribute content (such as tables of data or a codelist) which can be used in for example a drop-down list presented on screen. Fetching a table is part of the preparation or maintenance that is carried out for the initial load and periodical update of an environment/application. Thereby it eliminates the need to store and maintain data like code lists by duplicating it in another environment, by simply fetching it with the retrieveAfsTable function.

The data are displayed in a structure that represents a tabular form. For example a table with the header row formed by a number of AFD attributes, with the corresponding values on each row. The following example is a multi-layered table of professions, filled with AFD attributes occupation (codelist CBSBER), occupationDescription (string), elaborationOnOccupation (string), maximumEndAgeAov (decimal) and occupationalClassification (integer). Note that attributes within a afsTable entity/table do not necessarily have to be attributes from the AFD. Take for example the professionSynonyms attribute in the example below, which does not appear in the AFD.

occupation occupationDescription elaborationOnOccupation maximumEndAgeAov occupationalClassification professionSynonyms
0100 Scheikundigen Scheikundigen, natuurkundigen, verwante technici 68 1 Chemici
0200 Architecten Architecten, ingenieurs en verwante technici, tekenaars 67 3 Bouwkundigen

Mandatory components

The table below contains all mandatory entities and attributes of the masterDataStructure. Please note: these are only the mandatory components; in this case only the presence of a afsTable entity of entityType customTable and one or more rows as (an array of) tableRow entityTypes. See later in this section for a more detailed example.

Name Occur. Type Description
afsTableStructure 1..1 entity Structure of exchanging data.
afsTable 1..1 entity Entity for grouping data as data in itself.
entityType 1..1 string Set to ‘customTable’.
tableName 1..1 string Identifying name for the table.
afsTable 0..* entity Entity for grouping data as data in itself.
entityType 1..1 string Set to ‘tableRow’.

JSON example

Below is an example of a afsTableStructure, corresponding with the example table above of a profession table. Note that at the top level within JSON, the afsTableStructure entity is not explicitly mentioned. When the afsTableStructure is nested within other structures, the afsTableStructure is given an explicit tag. In XML, the structure is always explicitly defined at the highest level as well.

{
	"commonFunctional": [ {
		"entityType": "default",
		"dataCatalogVersion": "36E",
		"porCompany": "C103"
	} ],
	"afsTable": [ {
		"entityType": "customTable",
		"tableName": "Profession table",
		"afsTable": [ {
				"entityType": "tableRow",
				"occupation": "0100",
				"occupationDescription": "Scheikundigen",
				"elaborationOnOccupation": "Scheikundigen, natuurkundigen, verwante technici",
				"maximumEndAgeAov": 68,
				"occupationalClassification": 1,
				"professionSynonyms": ["Chemici"]
			},
			{
				"entityType": "tableRow",
				"occupation": "0200",
				"occupationDescription": "Architecten",
				"elaborationOnOccupation": "Architecten, ingenieurs en verwante technici, tekenaars",
				"maximumEndAgeAov": 67,
				"occupationalClassification": 3,
				"professionSynonyms": ["Bouwkundigen"]
			}
		]
	} ]
}

Feedback

Thanks for your feedback.

Post your comment on this topic.

Post Comment