This repository has been archived by the owner on Jan 18, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Context Validation
bruth edited this page Mar 2, 2013
·
7 revisions
This is an extension to the core validation spec.
-
operator
- The operator to be used for the condition
-
value
- The value to be used for the condition
-
nulls
- A boolean denoting whether to include/exclude
NULL
values if they are allowed for the field.
- A boolean denoting whether to include/exclude
Branch nodes act as containers for nesting relationship between nodes and are not associated to specific Field or Concept instances. Therefore only the two attributes below are required.
-
children
- A list of of nodes (condition or branch)
-
type
- The logical relationship between the nodes in the
children
list, eitheror
orand
.
- The logical relationship between the nodes in the
-
VALUE_OUT_OF_RANGE
- Applies to numerical values that are greater than the max or less than the min
-
VALUE_NOT_A_CHOICE
- Applies to enumerable or key-based data where the value is not in the set
-
VALUE_NOT_NULLABLE
- Applies to all fields. If a value does not allow
NULL
values to be stored, but the query is filtering by them, no data will be returned.
- Applies to all fields. If a value does not allow
-
SINGLE_NODE_BRANCH
- Applies to branch nodes that only contain a single node which deems the branch unnecessary. The client should replace the branch node with the single condition.
-
EMPTY_BRANCH
- Applies when a branch contains no child nodes
-
INVALID_VALUE
- The value is of the wrong type or format
-
INVALID_OPERATOR
- The operator supplied is not valid for the field
-
INVALID_OPERATOR_FOR_VALUE
- The combination of operator and value are invalid, e.g. a range query with a single value
{
'concept': 4,
'field': 39,
'value': 54,
'operator': 'gt',
'nulls': False,
'language': 'Pure Tone Average (PTA) is greater than 54',
'enabled': False,
'errors': ('Value out of range',)
}
{
'type': 'or',
'children': [{ ... }, { ... }]
}
Contents
- Introduction
- Installation & Setup
- Getting Started
- What Next?
Guides
- Managing your metadata
- Persisting sets of objects
- Writing a custom Interface
- Writing a custom Formatter
- Cookbook
APIs
Proposals
Reference
Developers