Book a Demo

Author Topic: Newbie needs help  (Read 2206 times)

petergsimmon

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Newbie needs help
« on: May 09, 2014, 06:10:37 am »
i am trying to get a structure imported to Sparx EA.  i have an XSD that describes the meta structure or base classes. now i need to import the different members of the classes. i.e. <?xml version="1.0" encoding="utf-8"?>

<xs:schema targetNamespace="http://tempuri.org/XMLSchema.xsd"
    xmlns="http://tempuri.org/XMLSchema.xsd"
    xmlns:mstns="http://tempuri.org/XMLSchema.xsd"
    xmlns:xs="http://www.w3.org/2001/XMLSchema"
            elementFormDefault='qualified'>

  <xs:element name='PadisTTYSegmentList' type='SegmentListType' />

  <xs:complexType name='SegmentListType'>
    <xs:sequence>
      <xs:element name="SegmentItem" type="SegmentItemType" minOccurs="1" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name='SegmentItemType'>
    <xs:sequence>
      <xs:element name="PadisID" type="xs:string" />
      <xs:element name="PadisVersion" type="xs:string" />
      <xs:element name="Description" type="xs:string" />
      <xs:element name="CompositeItems" type="CompositeListType" />
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="CompositeListType">
    <xs:sequence>
      <xs:element name="CompositeItem" type="CompositeItemType" minOccurs="1" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name='CompositeItemType'>
    <xs:sequence>
      <xs:element name="PadisID" type="xs:string" />
      <xs:element name="PadisVersion" type="xs:string" />
      <xs:element name="Description" type="xs:string" />
      <xs:element name="ElementItems" type="ElementListType" />
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="ElementListType">
    <xs:sequence>
      <xs:element name="ElementItem" type="ElementItemType" minOccurs="1" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name='ElementItemType'>
    <xs:sequence>
      <xs:element name="PadisID" type="xs:string" />
      <xs:element name="PadisVersion" type="xs:string" />
      <xs:element name="Description" type="xs:string" />
      <xs:element name="PadisType" type="xs:string" />
    </xs:sequence>
  </xs:complexType>
</xs:schema>

this imports into EA fine. but for SEGMENT there are specific instances like abc and 123 and i am trying to figure out how to describe them so that EA will understand them.  

I could be doing this all wrong, and if so please say so. this is my first go with EA.

  

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Newbie needs help
« Reply #1 on: May 09, 2014, 09:12:14 am »
You better give your thread a meaningful title like "XSD import problem"

There are some guys that might be able to help. My contact with XSD is too long ago.

q.