عنصر notation في نموذج XML
التعريف والاستخدام
يصف العنصر notation نموذج XML للبيانات غير XML.
معلومات العنصر
مرة واحدة أو أكثر | غير محدود |
العنصر الأب | النموذج |
المحتوى | التعليق |
النحو
<notation id=ID name=NCName public=anyURI system=anyURI خصائص أي > (التعليق?) </notation>
(?) يتم التعبير عن هذا العنصر في وحدة notation يمكن أن يظهر صفر مرة أو مرة واحدة.
خصائص | الوصف |
---|---|
id | اختياري. تحديد ID فريد للعنصر. |
name | مطلوب. تحديد اسم العنصر. |
public | مطلوب. المرجع إلى URI المتناسب مع معرف public. |
system | المرجع إلى URI المتناسب مع معرف system. |
خصائص أي | اختياري. تحديد أي خصائص أخرى بلا نطاق النموذج. |
مثال
مثال 1
السطر التالي يعرض أمثلة باستخدام تطبيق عرض view.exe لعرض النوتات بتنسيقات gif وjpeg:
<?xml version="1.0"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:notation name="gif" public="image/gif" system="view.exe"/> <xs:notation name="jpeg" public="image/jpeg" system="view.exe"/> <xs:element name="image"> <xs:complexType> <xs:simpleContent> <xs:attribute name="type"> <xs:simpleType> <xs:restriction base="xs:NOTATION"> <xs:enumeration value="gif"/> <xs:enumeration value="jpeg"/> <xs:restriction> </xs:simpleType> </xs:attribute> </xs:simpleContent> </xs:complexType> </xs:element> </xs:schema>
عنصر "image" في الوثيقة هو كالتالي:
<image type="gif"></image>