diff options
author | Thorsten Behrens <tbehrens@novell.com> | 2010-06-04 15:07:34 +0200 |
---|---|---|
committer | Thorsten Behrens <tbehrens@novell.com> | 2010-06-04 15:07:34 +0200 |
commit | 634e86f61dfb73a2900f32fc3d819e9c25365a49 (patch) | |
tree | 70f39bac42723700e36584a084bd48edcbc13360 /pyxb/xmlschema/structures.py | |
parent | f92e5cfba3f386cdcf2cd4899e2210a0fdfd2ea3 (diff) | |
parent | eb5ceb49c01322ec09b4b57e6a789fe700ddbd7e (diff) |
Diffstat (limited to 'pyxb/xmlschema/structures.py')
-rw-r--r-- | pyxb/xmlschema/structures.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/pyxb/xmlschema/structures.py b/pyxb/xmlschema/structures.py index 6bca3a8..8506686 100644 --- a/pyxb/xmlschema/structures.py +++ b/pyxb/xmlschema/structures.py @@ -161,10 +161,12 @@ class _SchemaComponent_mixin (pyxb.namespace._ComponentDependency_mixin, self.__namespaceContext = pyxb.namespace.resolution.NamespaceContext.GetNodeContext(node) if self.__namespaceContext is None: raise pyxb.LogicError('No namespace_context for schema component') + + super(_SchemaComponent_mixin, self).__init__(*args, **kw) + if isinstance(node, pyxb.utils.utility.Locatable_mixin): - self._setLocation(node.location) + self._setLocation(node._location()) - super(_SchemaComponent_mixin, self).__init__(*args, **kw) self._namespaceContext().targetNamespace()._associateComponent(self) self._setOwner(kw.get('owner')) @@ -4820,7 +4822,7 @@ class Schema (_SchemaComponent_mixin): @keyword absolute_schema_location: A file path or URI. This value is not normalized, and supersedes C{schema_location}. """ - schema_location = kw.pop('absolute_schema_location', pyxb.utils.utility.NormalizeLocation(kw.get('schema_location'), kw.get('parent_uri'))) + schema_location = kw.pop('absolute_schema_location', pyxb.utils.utility.NormalizeLocation(kw.get('schema_location'), kw.get('parent_uri'), kw.get('prefix_map'))) kw['location_base'] = kw['schema_location'] = schema_location assert isinstance(schema_location, basestring), 'Unexpected value %s type %s for schema_location' % (schema_location, type(schema_location)) uri_content_archive_directory = kw.get('uri_content_archive_directory') |