I want to know what is difference between this 2 ELEMENT tag :
<!ELEMENT bank (account*, customer*, depositor*)>
and
<!ELEMENT bank (account | customer | depositor )*>
thanks.
I want to know what is difference between this 2 ELEMENT tag :
<!ELEMENT bank (account*, customer*, depositor*)>
and
<!ELEMENT bank (account | customer | depositor )*>
thanks.
In a nutshell, the first ELEMENT declaration is saying the child elements have to be in a specific order. The second ELEMENT declaration is saying the child elements can be in any order.
The following means: a
bank
element containing zero or moreaccount
elements, followed by zero or morecustomer
elements, followed by zero or moredepositor
elements. (In that specific order.)The following means: a
bank
element containing zero or moreaccount
orcustomer
ordepositor
elements (in any order).The '
,
' means "followed by" and the '|
' means "or". The '*
' means zero or more. Also, a '+
' means one or more (at least one).