Skip to content

Commit 8ac2a81

Browse files
authored
Update dictionary.md
1 parent 641a29e commit 8ac2a81

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

graph/patterns/dictionary.md

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,18 @@ For more information, see the [OData reference](https://github.com/oasis-tcs/oda
4141
The following example demonstrates defining a dictionary that can contain string values.
4242

4343
```xml
44-
<ComplexType Name="stringDictionary" BaseType="graph.Dictionary">
45-
<Annotation Term="Org.OData.Validation.V1.OpenPropertyTypeConstraint">
46-
<Collection>
47-
<String>Edm.String</String>
48-
</Collection>
49-
</Annotation>
50-
</ComplexType>
44+
<Schema Namespace="WorkloadNamespace">
45+
<ComplexType Name="Dictionary" OpenType="true">
46+
<Annotation Term="Core.Description" String="A dictionary of name-value pairs. Names must be valid property names, values may be restricted to a list of types via an annotation with term `Validation.OpenPropertyTypeConstraint`." />
47+
</ComplexType>
48+
<ComplexType Name="stringDictionary" BaseType="WorkloadNamespace.Dictionary">
49+
<Annotation Term="Org.OData.Validation.V1.OpenPropertyTypeConstraint">
50+
<Collection>
51+
<String>Edm.String</String>
52+
</Collection>
53+
</Annotation>
54+
</ComplexType>
55+
</Schema>
5156
```
5257

5358
### Defining a dictionary property

0 commit comments

Comments
 (0)