Commit d68167c2 authored by "Sylvain ext:(%22)'s avatar "Sylvain ext:(%22)
Browse files

new "includefinal" optional argument to ESchema.relation_definitions

parent 086e7fd3699b
ChangeLog for yams
------------------
2006-11-14 -- 0.9.2
* new "includefinal" optional argument to ESchema.relation_definitions
2006-11-14 -- 0.9.1
* fix (well, hack) pickling problem
......
......@@ -21,7 +21,7 @@
modname = 'yams'
# release version
numversion = (0, 9, 1)
numversion = (0, 9, 2)
version = '.'.join([str(num) for num in numversion])
# license and copyright
......
yams (0.9.2-1) unstable; urgency=low
* new upstream release
--
yams (0.9.1-1) unstable; urgency=low
* new upstream release
......
......@@ -307,7 +307,7 @@ class EntitySchema(ERSchema):
desttype = rschema.objects(self)[0]
return rschema.rproperties(self, desttype)
def relation_definitions(self):
def relation_definitions(self, includefinal=False):
"""return an iterator on "real" relation definitions
"real" relations are a subset of subject relations where the
......@@ -318,7 +318,7 @@ class EntitySchema(ERSchema):
* schema of the destination entity type
"""
for rschema in self.ordered_relations():
if not rschema.is_final():
if includefinal or not rschema.is_final():
yield rschema, rschema.objects(self), 'subject'
for rschema in self.object_relations():
yield rschema, rschema.subjects(self), 'object'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment