Re: Adding XSD 1.1 assertions to a complex type

2014-07-17 Thread Mukul Gandhi
On 15 July 2014 21:38, sshanmug  wrote:

>  If I have more than one complex types extending from abstract-comp-type,
> how do I add validation to check if all the sub types have an element named
> element1?
>
> 


I think, this can be simply accomplished by having following assertion
within your type abstract-comp-type,



This will work for your requirement, because asserts are derived all the
way down the type hierarchy.




--
Regards,
Mukul Gandhi


Re: Adding XSD 1.1 assertions to a complex type

2014-07-17 Thread sshanmug
Thanks for the response. I added the assert and it's working.
Basically I added the following assert




--
View this message in context: 
http://apache-xml-project.6118.n7.nabble.com/Adding-XSD-1-1-assertions-to-a-complex-type-tp41267p41274.html
Sent from the Xerces - J - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: j-users-unsubscr...@xerces.apache.org
For additional commands, e-mail: j-users-h...@xerces.apache.org



Re: Adding XSD 1.1 assertions to a complex type

2014-07-17 Thread Mukul Gandhi
On 17 July 2014 21:19, sshanmug  wrote:

> Thanks for the response. I added the assert and it's working.
> Basically I added the following assert
> 
>

That shall also work. Its upto you. If you wish to save few keystrokes, you
can opt for the  I mentioned.



--
Regards,
Mukul Gandhi