forked from oasis-tcs/odata-openapi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.xml
152 lines (152 loc) · 8.38 KB
/
example.xml
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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="4.0" xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx">
<edmx:DataServices>
<Schema Namespace="ODataDemo" xmlns="http://docs.oasis-open.org/odata/ns/edm">
<EntityType Name="Product">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Int32" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<Property Name="Description" Type="Edm.String" />
<Property Name="ReleaseDate" Type="Edm.DateTimeOffset" Nullable="false" />
<Property Name="DiscontinuedDate" Type="Edm.DateTimeOffset" />
<Property Name="Rating" Type="Edm.Int16" Nullable="false" />
<Property Name="Price" Type="Edm.Double" Nullable="false" />
<NavigationProperty Name="Categories" Type="Collection(ODataDemo.Category)" Partner="Products" />
<NavigationProperty Name="Supplier" Type="ODataDemo.Supplier" Partner="Products" />
<NavigationProperty Name="ProductDetail" Type="ODataDemo.ProductDetail" Partner="Product" />
</EntityType>
<EntityType Name="FeaturedProduct" BaseType="ODataDemo.Product">
<NavigationProperty Name="Advertisement" Type="ODataDemo.Advertisement" Partner="FeaturedProduct" />
</EntityType>
<EntityType Name="ProductDetail">
<Key>
<PropertyRef Name="ProductID" />
</Key>
<Property Name="ProductID" Type="Edm.Int32" Nullable="false" />
<Property Name="Details" Type="Edm.String" />
<NavigationProperty Name="Product" Type="ODataDemo.Product" Partner="ProductDetail" />
</EntityType>
<EntityType Name="Category" OpenType="true">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Int32" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<NavigationProperty Name="Products" Type="Collection(ODataDemo.Product)" Partner="Categories" />
</EntityType>
<EntityType Name="Supplier">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Int32" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<Property Name="Address" Type="ODataDemo.Address" />
<Property Name="Location" Type="Edm.GeographyPoint" SRID="variable" />
<Property Name="Concurrency" Type="Edm.Int32" Nullable="false" />
<NavigationProperty Name="Products" Type="Collection(ODataDemo.Product)" Partner="Supplier" />
</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="Country" Type="Edm.String" />
</ComplexType>
<EntityType Name="Person">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Int32" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<NavigationProperty Name="PersonDetail" Type="ODataDemo.PersonDetail" Partner="Person" />
</EntityType>
<EntityType Name="Customer" BaseType="ODataDemo.Person">
<Property Name="TotalExpense" Type="Edm.Decimal" Nullable="false" />
</EntityType>
<EntityType Name="Employee" BaseType="ODataDemo.Person">
<Property Name="EmployeeID" Type="Edm.Int64" Nullable="false" />
<Property Name="HireDate" Type="Edm.DateTimeOffset" Nullable="false" />
<Property Name="Salary" Type="Edm.Single" Nullable="false" />
</EntityType>
<EntityType Name="PersonDetail">
<Key>
<PropertyRef Name="PersonID" />
</Key>
<Property Name="PersonID" Type="Edm.Int32" Nullable="false" />
<Property Name="Age" Type="Edm.Byte" Nullable="false" />
<Property Name="Gender" Type="Edm.Boolean" Nullable="false" />
<Property Name="Phone" Type="Edm.String" />
<Property Name="Address" Type="ODataDemo.Address" />
<Property Name="Photo" Type="Edm.Stream" Nullable="false" />
<NavigationProperty Name="Person" Type="ODataDemo.Person" Partner="PersonDetail" />
</EntityType>
<EntityType Name="Advertisement" HasStream="true">
<Key>
<PropertyRef Name="ID" />
</Key>
<Property Name="ID" Type="Edm.Guid" Nullable="false" />
<Property Name="Name" Type="Edm.String" />
<Property Name="AirDate" Type="Edm.DateTimeOffset" Nullable="false" />
<NavigationProperty Name="FeaturedProduct" Type="ODataDemo.FeaturedProduct" Partner="Advertisement" />
</EntityType>
<Action Name="Discount" IsBound="true">
<Parameter Name="product" Type="ODataDemo.Product" />
<Parameter Name="discountPercentage" Type="Edm.Int32" Nullable="false" />
<ReturnType Type="Edm.Double" Nullable="false" />
</Action>
<Action Name="IncreaseSalaries">
<Parameter Name="percentage" Type="Edm.Decimal" Scale="variable" Nullable="false" />
</Action>
<EntityContainer Name="DemoService">
<EntitySet Name="Products" EntityType="ODataDemo.Product">
<NavigationPropertyBinding Path="ODataDemo.FeaturedProduct/Advertisement" Target="Advertisements" />
<NavigationPropertyBinding Path="Categories" Target="Categories" />
<NavigationPropertyBinding Path="Supplier" Target="Suppliers" />
<NavigationPropertyBinding Path="ProductDetail" Target="ProductDetails" />
</EntitySet>
<EntitySet Name="ProductDetails" EntityType="ODataDemo.ProductDetail">
<NavigationPropertyBinding Path="Product" Target="Products" />
</EntitySet>
<EntitySet Name="Categories" EntityType="ODataDemo.Category">
<NavigationPropertyBinding Path="Products" Target="Products" />
</EntitySet>
<EntitySet Name="Suppliers" EntityType="ODataDemo.Supplier">
<NavigationPropertyBinding Path="Products" Target="Products" />
</EntitySet>
<EntitySet Name="Persons" EntityType="ODataDemo.Person">
<NavigationPropertyBinding Path="PersonDetail" Target="PersonDetails" />
</EntitySet>
<EntitySet Name="PersonDetails" EntityType="ODataDemo.PersonDetail">
<NavigationPropertyBinding Path="Person" Target="Persons" />
</EntitySet>
<EntitySet Name="Advertisements" EntityType="ODataDemo.Advertisement">
<NavigationPropertyBinding Path="FeaturedProduct" Target="Products" />
</EntitySet>
<ActionImport Name="IncreaseSalaries" Action="ODataDemo.IncreaseSalaries" />
</EntityContainer>
<Annotations Target="ODataDemo.DemoService">
<Annotation Term="Org.OData.Display.V1.Description" String="This is a sample OData service with vocabularies" />
</Annotations>
<Annotations Target="ODataDemo.Product">
<Annotation Term="Org.OData.Display.V1.Description" String="All Products available in the online store" />
</Annotations>
<Annotations Target="ODataDemo.Product/Name">
<Annotation Term="Org.OData.Display.V1.DisplayName" String="Product Name" />
</Annotations>
<Annotations Target="ODataDemo.DemoService/Suppliers">
<Annotation Term="Org.OData.Publication.V1.PublisherName" String="Microsoft Corp." />
<Annotation Term="Org.OData.Publication.V1.PublisherId" String="MSFT" />
<Annotation Term="Org.OData.Publication.V1.Keywords" String="Inventory, Supplier, Advertisers, Sales, Finance" />
<Annotation Term="Org.OData.Publication.V1.AttributionUrl" String="http://www.odata.org/" />
<Annotation Term="Org.OData.Publication.V1.AttributionDescription" String="All rights reserved" />
<Annotation Term="Org.OData.Publication.V1.DocumentationUrl " String="http://www.odata.org/" />
<Annotation Term="Org.OData.Publication.V1.TermsOfUseUrl" String="All rights reserved" />
<Annotation Term="Org.OData.Publication.V1.PrivacyPolicyUrl" String="http://www.odata.org/" />
<Annotation Term="Org.OData.Publication.V1.LastModified" String="4/2/2013" />
<Annotation Term="Org.OData.Publication.V1.ImageUrl " String="http://www.odata.org/" />
</Annotations>
</Schema>
</edmx:DataServices>
</edmx:Edmx>