Skip to content

Domain Model

René Reitmann edited this page Jun 10, 2021 · 188 revisions

Overview

The following picture models the relationships and attributes of the domain objects which are managed by our system. Domain Model

Validation

Before saving an object of the domain model it is validated by our backend. The fields of each object and their validation rules are described here.

In addition to the validation per object there will be a DataAcquisitionProject (Post-)Validation which checks the consistency of the data of the entire project.

DataAcquisitionProject (Post-)Validation

This section describes the validation rules which are applied in order to ensure consistency of the entire DataAcquisitionProject.

Post-Validation performs checks which cannot be performed during the import of a single domain object. These checks are automatically executed before a project will be released.

The following checks are implemented.

DataSet

  • dataSet.surveyIds: there must be a survey with that id

Variable

  • variable.surveyIds: there must be a survey with that id and the surveyIds must be a subset of the surveyIds of the corresponding dataSet
  • variable.relatedQuestions[*].questionId: there must be a question with that id
  • variable.dataSetId: there must be a data set with that id
  • variable.relatedVariables: Check for variable ids
  • variable.codingSchemeId: there must be a coding scheme with that id

Question

  • question.instrumentId: there must be an instrument with that id
  • question.successors: there must be a question with that id
  • Check for a depending question image

Instrument

  • instrument.surveyIds: there must be a survey with that id