Type definition in XML page with XML Schema

Discussion in 'XML' started by chobin, Dec 10, 2003.

  1. chobin

    chobin Guest

    Hi all.
    I've a terrible question.
    I've to build one XML page (based on a xml schema) that implements a
    dynamic database. In particular, I would declare something like this:

    <?xml version="1.0" encoding="UTF-8"?>
    <virtuose xmlns="http://www.virtuose.it/ns/virtuose"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.virtuose.it/ns/virtuose
    F:\Tesi\virtuose_1.1.xsd">

    <conferenza allowedMessagesTypes="t1" cid="c1" system="true">
    <nome>tipimsg</nome>
    <hook></hook>
    <messages>
    <message mid="t1" uid="u1" type="t1"></message>
    <message mid="t2" uid="u1" type="t1">
    <t2:schema>
    <t2:element name="utente">
    <t2:complexType>
    <t2:sequence>
    <t2:element name="autenticazione">
    <t2:complexType>
    <t2:sequence>
    <t2:element name="login" type="string"/>
    <t2:element name="password" type="string"/>
    <t2:element name="configurazione" type="stringa"/>
    </t2:sequence>
    </t2:complexType>
    </t2:element>
    <t2:element name="anagrafica">
    <t2:complexType>
    <t2:sequence>
    <t2:element name="nome" type="string"/>
    <t2:element name="cognome" type="string"/>
    <t2:element name="codfisc" type="string"/>
    <t2:element name="via" type="string"/>
    <t2:element name="comune" type="string"/>
    <t2:element name="provincia" type="string"/>
    <t2:element name="cap" type="string"/>
    <t2:element name="telefono" type="string"/>
    <t2:element name="fax" type="string"/>
    <t2:element name="cellulare" type="string"/>
    <t2:element name="email" type="string"/>
    </t2:sequence>
    </t2:complexType>
    </t2:element>
    <t2:element name="profili">
    <t2:attribute name="pids" type="IDREF" use="required"/>
    </t2:element>
    </t2:sequence>
    </t2:complexType>
    </t2:element>
    </t2:schema>
    </message>
    </messages>
    </conferenza>
    <conferenza allowedMessagesTypes="t2" cid="c2" system="true">
    <nome>utenti</nome>
    <hook></hook>
    <messages>
    <message mid="u1" uid="u1" type="t2">
    <t2:utente>
    <t2:login>ciccio</t2:login>
    <t2:profili></t2:profili>
    </t2:utente>
    </message>
    </messages>
    </conferenza>
    </virtuose>


    So, I've to declare on section <message mid="t2" uid="u1" type="t1">
    the type of section

    <message mid="u1" uid="u1" type="t2">
    <t2:utente>
    <t2:login>ciccio</t2:login>
    <t2:profili></t2:profili>
    </t2:utente>
    </message>

    but I haven't found in witch way I could include in a XML page a type
    declaration made with schema.

    I hope my message is not too difficult to read...
    I'm sorry but I'm an italian student.

    Thank you very much
    Cheers

    Chobin
     
    chobin, Dec 10, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Markus
    Replies:
    1
    Views:
    1,614
    Markus
    Nov 23, 2005
  2. Abhinav
    Replies:
    6
    Views:
    1,107
    Abhinav
    Aug 16, 2004
  3. Stanimir Stamenkov
    Replies:
    3
    Views:
    1,296
    Stanimir Stamenkov
    Apr 25, 2005
  4. Stanimir Stamenkov
    Replies:
    2
    Views:
    764
    Stanimir Stamenkov
    Oct 25, 2005
  5. Pierre Yves
    Replies:
    2
    Views:
    500
    Pierre Yves
    Jan 10, 2008
Loading...

Share This Page