|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: extend two elements?
Amy,
You do
not give the definition of your "student" type.
Let me
make a few assumptions:
1.
Your "student" type is sufficiently complex that it is worth doing this as an
extension, rather than just a separate definition (the easy
way).
2.
Your "student" already contains an address, and you want to replace this with
the "grad_address".
You
already have a reply from Jack Lindsey making different
assumptions.
If my
assumptions are correct, you have a slight problem as an extension cannot
replace the "address" type with the "grad_address" type. I would create a
new type and derive both "student" and "grad_student" from this. Let's call the
abstract type "student_base", with a definition that is the same as student but
without the address. Then "student" extends this by adding the "address" and
"grad_student" extends it by adding the "grad_address" and the appropriate
attributes.
Note
that you can make it impossible to create an element based on the "student_base"
type directly if you like, but this is not strictly
necessary.
Regards
Paul
Spencer
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] |
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Cast Your Vote
We need your help – Vote for DataDirect XML Products!
Winners and finalists announced at SOA World Conference in November. Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||







