[Zope3-dev] Extending a top-level ZConfig schema
Fred L. Drake, Jr.
fred@zope.com
Thu, 10 Jul 2003 10:17:49 -0400
Phillip J. Eby writes:
> There doesn't seem to be any way to extend a top-level ZConfig schema (as
> opposed to a schema component); are there any plans to change that?
I'm not sure which of two different things you're trying to do:
- modify the top level of a schema from something it <import/>s, or
- create a new schema that adds to an existing schema.
(If it's not one of these, please elaborate!)
If what you want is the later, I could see adding support for it using
syntax like this:
<schema extends='src'>
<!-- only the new stuff here -->
</schema>
where src is similar to the src attribute of <import/>, but
everything is retained (essentially doing the same thing as <import
src='...'/> plus a <sectiontype extends='that-other-schema'/>).
> I thought that using <import src=""> would do it, but that only seems to
> import section *types*, not key or section definitions.
That's correct. This was done this way since so the difference
between <import src='...'/> and <import package='...'/> wasn't too
confusing.
-Fred
--
Fred L. Drake, Jr. <fred at zope.com>
PythonLabs at Zope Corporation