-
Notifications
You must be signed in to change notification settings - Fork 6
lfs:Answer specifications
OrdiNeu edited this page Feb 5, 2020
·
1 revision
The base nodetype for structured answers.
Answers will be used as child nodes of a record, one node per answer.
This means that for a given question, the answer may either:
- not exist, if the question isn't answered yet
- have a single child node referencing that question, if the question expects a single choice
- have multiple child nodes referencing that question, if it allows more than one choice, one node for each answer
- have multiple child nodes referencing that question AND an identifier for the question instance, if the question can be repeated, for example a question that must be answered for each relative, or for each occurrence of an event
The name of each answer node is not relevant and will be automatically generated, only the reference to the question matters.
The meaning of an answer is defined by the question, so most of the display properties are defined in the question, not in the answer.
In other words, an Answer node is just simple storage.
-
question
A reference to the question being answered. -
questionInstanceLabel
An optional additional identifier for the question being answered, in case of questions allowing more than one answer. -
value
The value (answer) to the linked question
-
lfs:BooleanAnswer
Yes/no questions -
lfs:TextAnswer
Text questions -
lfs:LongAnswer
Long questions -
lfs:DoubleAnswer
Real numbers, stored as lossy "double" values. Should not be used to store values where precision is paramount, use lfs:DecimalAnswer instead. -
lfs:DecimalAnswer
Decimal numbers, guaranteed to store the exact value entered. -
lfs:DateAnswer
Date and DateTime -
lfs:PedigreeAnswer
Pedigree, stored mainly as a JSON representation, but also as a cached SVG image.- The
value
property will have the data as a JSON - This has an
image
property, with the image of the pedigree as an SVG file
- The
-
lfs:VocabularyAnswer
Vocabulary identifiers, stored as their ID (e.g.HP:0003324
).