Details
Description
Proposed Syntax
{ $_internalSchemaCond:
|
[
|
<conditionMatchExpression>,
|
<thenBranchMatchExpression>,
|
<elseBranchMatchExpression>
|
]
|
}
|
Proposed Semantics
A document is matched against the condition MatchExpression. If it matches, it is then matched against the thenBranch expression; otherwise, it is matched against the elseBranch expression. The document matches the entire $_internalSchemaCond expression based on whether or not it matches the thenBranch or elseBranch.
$_internalSchemaCond can be used to constrain a subobject if it is wrapped in an $_internalSchemaObjectMatch.