Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

XML Schema entweder keins oder zwei Attribut

Empfohlene Antworten

Hallo,

Ich habe eine herrausforderung ein XML-Schema betreffend. Ich will zwei Attribute in einem Element haben, welche entweder zusammen oder gar nicht angegeben werden sollen:


<subparam name="art" nullable="false" type="[…].business.transfer.UrlaubArt" />

<subparam name="zeitraumStart" nullable="false" [COLOR="Red"]relation="le" relationAttr="zeitraumEnde"[/COLOR] type="java.util.Date" />

Mein Schema sieht bis jetzt so aus:

  <xsd:complexType name="subparamType">

    <xsd:sequence>

   	<xsd:element name="subparam" type="subparamType" maxOccurs="unbounded" minOccurs="0"></xsd:element>

    </xsd:sequence>

    <xsd:attributeGroup ref="nameAttr"></xsd:attributeGroup>

    <xsd:attributeGroup ref="paramAttr"></xsd:attributeGroup>

    <xsd:attributeGroup ref="subparamAttr"></xsd:attributeGroup>

  </xsd:complexType>


[…]


  <xsd:attributeGroup name="subparamAttr">

    <xsd:attribute  name="relationAttr" use="required" type="xsd:string"></xsd:attribute>

    <xsd:attribute  name="relation" use="required" type="vergleich"></xsd:attribute>

  </xsd:attributeGroup>


  <xsd:simpleType name="vergleich">

    <xsd:restriction base="xsd:string">

      <xsd:enumeration value="e"/>

      <xsd:enumeration value="g"/>

      <xsd:enumeration value="l"/>

      <xsd:enumeration value="ge"/>

      <xsd:enumeration value="le"/>

    </xsd:restriction>

  </xsd:simpleType>

1. Gibt es eine Möglichkeit dieses Problem zu lösen?

2. Gibt es eine Möglichkeit zu definieren, dass der Wert des relationAttr-Attributs eine gültige ID innerhalb des Dokuments ist?

Danke und Gruss

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Konto

Navigation

Suchen

Suchen

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.