File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed
Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -198,6 +198,25 @@ entity sets are pointing to existing elements.
198198The most often problem that we had to deal with was an invalid ValueList annotion
199199pointing to a non-existing property.
200200
201+ To enable verification of service definition, the client instance of the class
202+ ` Service ` publishes the property ` schema ` which returns an instance of the
203+ class ` Schema ` from the module [ pyodata.v2.model] ( pyodata/v2/model.py ) and it
204+ contains parsed ` $metadata ` .
205+
206+ ### List of the defined EntitySets
207+
208+ If you need to iterate over all EntitySets:
209+
210+ ``` python
211+ for es in service.schema.entity_sets:
212+ print (es.name)
213+ ```
214+
215+ or if you just need the list of EntitySet names:
216+
217+ ``` python
218+ entity_set_names = [es.name for es in service.schema.entity_sets]
219+ ```
201220
202221### Property has this label
203222
You can’t perform that action at this time.
0 commit comments