forked from oasis-tcs/odata-openapi
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcsdl-16.1.xml
More file actions
102 lines (101 loc) · 4.91 KB
/
csdl-16.1.xml
File metadata and controls
102 lines (101 loc) · 4.91 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx" xmlns="http://docs.oasis-open.org/odata/ns/edm" Version="4.01">
<edmx:Reference Uri="https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.xml">
<edmx:Include Namespace="Org.OData.Core.V1" Alias="Core">
<Annotation Term="Core.DefaultNamespace" />
</edmx:Include>
</edmx:Reference>
<edmx:Reference Uri="https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Measures.V1.xml">
<edmx:Include Namespace="Org.OData.Measures.V1" />
</edmx:Reference>
<edmx:DataServices>
<Schema Namespace="ODataDemo">
<Annotation Term="Core.DefaultNamespace" />
<EntityType Name="Product">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.String" Nullable="false" />
<Property Name="Description" Type="Edm.String">
<Annotation Term="Core.IsLanguageDependent" />
</Property>
<Property Name="ReleaseDate" Type="Edm.Date" />
<Property Name="DiscontinuedDate" Type="Edm.Date" />
<Property Name="Rating" Type="Edm.Int32" />
<Property Name="Price" Type="Edm.Decimal">
<Annotation Term="Org.OData.Measures.V1.ISOCurrency" Path="Currency" />
</Property>
<Property Name="Currency" Type="Edm.String" MaxLength="3" />
<NavigationProperty Name="Category" Type="ODataDemo.Category" Nullable="false" Partner="Products" />
<NavigationProperty Name="Supplier" Type="ODataDemo.Supplier" Partner="Products" />
</EntityType>
<EntityType Name="Category">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Int32" Nullable="false" />
<Property Name="Name" Type="Edm.String" Nullable="false">
<Annotation Term="Core.IsLanguageDependent" />
</Property>
<NavigationProperty Name="Products" Partner="Category" Type="Collection(ODataDemo.Product)">
<OnDelete Action="Cascade" />
</NavigationProperty>
</EntityType>
<EntityType Name="Supplier">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.String" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<Property Name="Address" Type="ODataDemo.Address" Nullable="false" />
<Property Name="Concurrency" Type="Edm.Int32" Nullable="false" />
<NavigationProperty Name="Products" Partner="Supplier" Type="Collection(ODataDemo.Product)" />
</EntityType>
<EntityType Name="Country">
<Key>
<PropertyRef Name="Code" />
</Key>
<Property Name="Code" Type="Edm.String" MaxLength="2" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
</EntityType>
<ComplexType Name="Address">
<Property Name="Street" Type="Edm.String" />
<Property Name="City" Type="Edm.String" />
<Property Name="State" Type="Edm.String" />
<Property Name="ZipCode" Type="Edm.String" />
<Property Name="CountryName" Type="Edm.String" />
<NavigationProperty Name="Country" Type="ODataDemo.Country">
<ReferentialConstraint Property="CountryName" ReferencedProperty="Name" />
</NavigationProperty>
</ComplexType>
<Function Name="ProductsByRating">
<Parameter Name="Rating" Type="Edm.Int32" />
<ReturnType Type="Collection(ODataDemo.Product)" />
</Function>
<EntityContainer Name="DemoService">
<EntitySet Name="Products" EntityType="ODataDemo.Product">
<NavigationPropertyBinding Path="Category" Target="Categories" />
</EntitySet>
<EntitySet Name="Categories" EntityType="ODataDemo.Category">
<Annotation Term="Core.Description" String="Product Categories" />
<NavigationPropertyBinding Path="Products" Target="Products" />
</EntitySet>
<EntitySet Name="Suppliers" EntityType="ODataDemo.Supplier">
<NavigationPropertyBinding Path="Products" Target="Products" />
<NavigationPropertyBinding Path="Address/Country" Target="Countries" />
<Annotation Term="Core.OptimisticConcurrency">
<Collection>
<PropertyPath>Concurrency</PropertyPath>
</Collection>
</Annotation>
</EntitySet>
<Singleton Name="MainSupplier" Type="ODataDemo.Supplier">
<Annotation Term="Core.Description" String="Primary Supplier" />
<NavigationPropertyBinding Path="Products" Target="Products" />
</Singleton>
<EntitySet Name="Countries" EntityType="ODataDemo.Country" />
<FunctionImport Name="ProductsByRating" EntitySet="Products" Function="ODataDemo.ProductsByRating" />
</EntityContainer>
</Schema>
</edmx:DataServices>
</edmx:Edmx>