1 | <?xml version="1.0"?> |
---|
2 | <xs:schema xmlns:xs='http://www.w3.org/2000/10/XMLSchema'> |
---|
3 | |
---|
4 | <!--rst |
---|
5 | |
---|
6 | DESCRIPTION |
---|
7 | =========== |
---|
8 | |
---|
9 | Definition of authorized tags of :file:`userlocean.xml` |
---|
10 | |
---|
11 | EXAMPLES |
---|
12 | ======== |
---|
13 | |
---|
14 | From test files on repository |
---|
15 | |
---|
16 | To generate python API:: |
---|
17 | |
---|
18 | ln -s ${PROJECT}/../branches/bibliolocean/data/userlocean.xsd ${PROJECT_ID}/users.xsd |
---|
19 | |
---|
20 | with no dict:: |
---|
21 | |
---|
22 | generateDS.py -o users_api.py -s users_appl1.py \-\-super=users_api \-\-external-encoding=iso-8859-1 ${PROJECT_ID}/users.xsd |
---|
23 | |
---|
24 | with dict:: |
---|
25 | |
---|
26 | generateDS.py -o users_api.py -s users_appl1.py \-\-super=users_api \-\-member-specs=dict -m \-\-external-encoding=iso-8859-1 ${PROJECT_ID}/users.xsd |
---|
27 | |
---|
28 | To test this API:: |
---|
29 | |
---|
30 | ln -s ${PROJECT}/../branches/bibliolocean/data/userlocean.xml ${PROJECT_ID}/users.xml |
---|
31 | python users_api.py ${PROJECT_ID}/users.xml |
---|
32 | |
---|
33 | |
---|
34 | SEE ALSO |
---|
35 | ======== |
---|
36 | |
---|
37 | TODO |
---|
38 | ==== |
---|
39 | |
---|
40 | ++ path python dans l'exemple |
---|
41 | |
---|
42 | ++ annotation |
---|
43 | |
---|
44 | ++ utilisation de docbook.xsd pour surname, etc. |
---|
45 | |
---|
46 | EVOLUTIONS |
---|
47 | ========== |
---|
48 | |
---|
49 | $Id$ |
---|
50 | |
---|
51 | $URL$ |
---|
52 | |
---|
53 | - fplod 20121004T161942Z cratos.locean-ipsl.upmc.fr (Linux) |
---|
54 | |
---|
55 | * creation from usernemo.dtd |
---|
56 | |
---|
57 | --> |
---|
58 | |
---|
59 | <xs:element name='users' type="usersType"> |
---|
60 | <xs:annotation><xs:documentation> |
---|
61 | List of authors of LOCEAN |
---|
62 | </xs:documentation></xs:annotation> |
---|
63 | </xs:element> |
---|
64 | <xs:complexType name="usersType"> |
---|
65 | <xs:sequence> |
---|
66 | <xs:element name='date' type="xs:datetime"/> |
---|
67 | <xs:element name='user' maxOccurs='unbounded' type="userType"/> |
---|
68 | </xs:sequence> |
---|
69 | </xs:complexType> |
---|
70 | |
---|
71 | <xs:element name='date'> |
---|
72 | <xs:complexType mixed='true'> |
---|
73 | </xs:complexType> |
---|
74 | </xs:element> |
---|
75 | |
---|
76 | <xs:element name='user' type='userType'> |
---|
77 | <xs:annotation><xs:documentation> |
---|
78 | A generic author |
---|
79 | </xs:documentation></xs:annotation> |
---|
80 | </xs:element> |
---|
81 | |
---|
82 | <xs:complexType name="userType"> |
---|
83 | <xs:sequence> |
---|
84 | <xs:element ref='userid'/> |
---|
85 | <xs:element name='personname' type='personnameType'/> |
---|
86 | </xs:sequence> |
---|
87 | </xs:complexType> |
---|
88 | |
---|
89 | <xs:element name='userid'> |
---|
90 | <xs:complexType mixed='true'> |
---|
91 | </xs:complexType> |
---|
92 | </xs:element> |
---|
93 | |
---|
94 | <xs:element name='personname' type='personnameType'> |
---|
95 | </xs:element> |
---|
96 | <xs:complexType name='personnameType'> |
---|
97 | <xs:sequence> |
---|
98 | <xs:element name='surname' type="xs:string"/> |
---|
99 | <xs:element name='firstname' type="xs:string"/> |
---|
100 | <xs:element ref='othername'/> |
---|
101 | </xs:sequence> |
---|
102 | </xs:complexType> |
---|
103 | |
---|
104 | <xs:element name='othername'> |
---|
105 | <xs:complexType mixed='true'> |
---|
106 | <xs:attribute name='role' type='string' use='optional'/> |
---|
107 | </xs:complexType> |
---|
108 | </xs:element> |
---|
109 | |
---|
110 | <xs:element name='email'> |
---|
111 | <xs:complexType mixed='true'> |
---|
112 | </xs:complexType> |
---|
113 | </xs:element> |
---|
114 | |
---|
115 | </xs:schema> |
---|