1 | <?xml version="1.0" encoding="iso-8859-1"?> |
---|
2 | <xsl:stylesheet |
---|
3 | version="1.0" |
---|
4 | xmlns:d="http://docbook.org/ns/docbook" |
---|
5 | xmlns:xl="http://www.w3.org/1999/xlink" |
---|
6 | xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> |
---|
7 | |
---|
8 | <!-- |
---|
9 | module : |
---|
10 | produce a DocBook 5 with bibliograhy references sorted by years |
---|
11 | |
---|
12 | update : |
---|
13 | $Id$ |
---|
14 | fplod 2008-04-30T10:32:48Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
15 | language inherited from biblio.xml |
---|
16 | fplod 2008-04-29T15:23:51Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
17 | chgt for dbk5 in ++ |
---|
18 | fplod 2008-04-29T07:46:20Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
19 | chgt for dbk5 out |
---|
20 | fplod 2007-10-17T08:01:14Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
21 | improve authors sort (diacriticals) |
---|
22 | fplod 2007-06-08T08:36:48Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
23 | add total nb of publications in one cell. quite interesting usage of |
---|
24 | XPATH to determine mininum and maximum value of a element ! |
---|
25 | fplod 2007-05-21T14:06:53Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
26 | ajout de plot nbpub/years |
---|
27 | fplod 2007-05-04T08:02:29Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
28 | externalisation de biblioentry |
---|
29 | passage de itemizedlist à sect1 pour homogénéisation sur présentation par auteur(et parce que je préfère) |
---|
30 | fplod 2007-04-02T08:53:30Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
31 | journal dans biblioset |
---|
32 | fplod 2007-03-30T12:38:34Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
33 | creation |
---|
34 | --> |
---|
35 | |
---|
36 | <xsl:output |
---|
37 | method="xml" |
---|
38 | indent="yes" |
---|
39 | omit-xml-declaration="no"/> |
---|
40 | |
---|
41 | <xsl:include href="biblioentry_xml.xsl"/> |
---|
42 | <xsl:include href="message_lang.xsl"/> |
---|
43 | |
---|
44 | <xsl:variable name="list_years" select="///d:pubdate[not( self::node() = following::d:pubdate )]"/> |
---|
45 | |
---|
46 | <xsl:template name="years"> |
---|
47 | <!-- |
---|
48 | creation of an informatable of nb years |
---|
49 | each entry of the table is a link #year_xxxx |
---|
50 | --> |
---|
51 | <xsl:element name="informaltable"> |
---|
52 | <xsl:attribute name="xml:id">years</xsl:attribute> |
---|
53 | <xsl:attribute name="summary">years of publications</xsl:attribute> |
---|
54 | <xsl:element name="tgroup"> |
---|
55 | <xsl:variable name="nb_cols" select="count($list_years)"/> |
---|
56 | <xsl:attribute name="cols"><xsl:value-of select="$nb_cols"/></xsl:attribute> |
---|
57 | <xsl:attribute name="align">center</xsl:attribute> |
---|
58 | <xsl:attribute name="colsep">1</xsl:attribute> |
---|
59 | <xsl:attribute name="rowsep">1</xsl:attribute> |
---|
60 | <xsl:for-each select="///d:pubdate[not( self::node() = following::d:pubdate )]"> |
---|
61 | <xsl:sort order="descending" data-type="number" select="."/> |
---|
62 | <xsl:element name="colspec"> |
---|
63 | <xsl:attribute name="colname">year_<xsl:value-of select="."/></xsl:attribute> |
---|
64 | </xsl:element> |
---|
65 | </xsl:for-each> |
---|
66 | <xsl:element name="tbody"> |
---|
67 | <xsl:element name="row"> |
---|
68 | <xsl:for-each select="///d:pubdate[not( self::node() = following::d:pubdate )]"> |
---|
69 | <xsl:sort order="descending" data-type="number" select="."/> |
---|
70 | <xsl:element name="entry"> |
---|
71 | <xsl:attribute name="colname"><xsl:text>year_</xsl:text><xsl:value-of select="."/></xsl:attribute> |
---|
72 | <xsl:element name="link"> |
---|
73 | <xsl:attribute name="xl:href"><xsl:text>#year_</xsl:text><xsl:value-of select="."/></xsl:attribute> |
---|
74 | <xsl:value-of select="."/> |
---|
75 | </xsl:element> |
---|
76 | </xsl:element> |
---|
77 | </xsl:for-each> |
---|
78 | </xsl:element> |
---|
79 | <xsl:element name="row"> |
---|
80 | <xsl:for-each select="///d:pubdate[not( self::node() = following::d:pubdate )]"> |
---|
81 | <xsl:sort order="descending" data-type="number" select="."/> |
---|
82 | <xsl:element name="entry"> |
---|
83 | <xsl:attribute name="colname"><xsl:text>year_</xsl:text><xsl:value-of select="."/></xsl:attribute> |
---|
84 | <xsl:element name="emphasis"> |
---|
85 | <xsl:attribute name="role">bold</xsl:attribute> |
---|
86 | <xsl:variable name="nb_current"> |
---|
87 | <xsl:variable name="current_year"><xsl:value-of select="."/></xsl:variable> |
---|
88 | <xsl:value-of select="count(/descendant::d:biblioentry[child::d:biblioset[child::d:pubdate=$current_year]])"/> |
---|
89 | </xsl:variable> |
---|
90 | <xsl:value-of select="$nb_current"/> |
---|
91 | </xsl:element> |
---|
92 | </xsl:element> |
---|
93 | </xsl:for-each> |
---|
94 | </xsl:element> |
---|
95 | <xsl:variable name="year_min"> |
---|
96 | <xsl:value-of select="///d:pubdate[not(. > ///d:pubdate)]"/> |
---|
97 | </xsl:variable> |
---|
98 | <xsl:variable name="year_max"> |
---|
99 | <xsl:value-of select="///d:pubdate[not(. < ///d:pubdate)]"/> |
---|
100 | </xsl:variable> |
---|
101 | <xsl:element name="row"> |
---|
102 | <xsl:element name="entry"> |
---|
103 | <xsl:attribute name="namest"><xsl:value-of select="concat('year_',$year_max)"/></xsl:attribute> |
---|
104 | <xsl:attribute name="nameend"><xsl:value-of select="concat('year_',$year_min)"/></xsl:attribute> |
---|
105 | <xsl:element name="emphasis"> |
---|
106 | <xsl:attribute name="role">bold</xsl:attribute> |
---|
107 | <xsl:value-of select="count(/descendant::d:biblioentry)"/> |
---|
108 | </xsl:element> |
---|
109 | </xsl:element> |
---|
110 | </xsl:element> |
---|
111 | </xsl:element> |
---|
112 | </xsl:element> |
---|
113 | </xsl:element> |
---|
114 | </xsl:template> |
---|
115 | |
---|
116 | <xsl:template match="d:bibliography"> |
---|
117 | |
---|
118 | <xsl:element name="article"> |
---|
119 | <xsl:attribute name="version">5.0</xsl:attribute> |
---|
120 | <xsl:attribute name="xmlns">http://docbook.org/ns/docbook</xsl:attribute> |
---|
121 | <xsl:attribute name="xml:lang"><xsl:value-of select="@xml:lang"/></xsl:attribute> |
---|
122 | <title>NEMO - Publications - Papers by years</title> |
---|
123 | <info> |
---|
124 | <authorgroup> |
---|
125 | <author><personname><firstname>Sébastien</firstname> <surname>Masson</surname></personname></author> |
---|
126 | <author><personname><firstname>Françoise</firstname> <surname>Pinsard</surname></personname></author> |
---|
127 | <!--++--> |
---|
128 | </authorgroup> |
---|
129 | <keywordset> |
---|
130 | <keyword>NEMO</keyword> |
---|
131 | </keywordset> |
---|
132 | <!-- ++ date --> |
---|
133 | </info> |
---|
134 | <para xml:id="top"> |
---|
135 | This page intents to provide an exhaustive list of the papers that have used |
---|
136 | NEMO or OPA and/or results from them. |
---|
137 | Obvioulsy many papers are missing. |
---|
138 | If you find omissions or mistakes please ask some modification via |
---|
139 | <xsl:element name="link"> |
---|
140 | <xsl:attribute name="xl:href"> |
---|
141 | <xsl:value-of select="'./main.php'"/> |
---|
142 | </xsl:attribute> |
---|
143 | <xsl:text>Nemo Survey main page</xsl:text> |
---|
144 | </xsl:element>. |
---|
145 | </para> |
---|
146 | <para> |
---|
147 | You can also see <quote>NEMO - Publications - Papers</quote> sorted by |
---|
148 | authors in |
---|
149 | <xsl:element name="link"> |
---|
150 | <xsl:attribute name="xl:href"> |
---|
151 | <xsl:value-of select="'./superbib02.html'"/> |
---|
152 | </xsl:attribute> |
---|
153 | <xsl:text>one big document </xsl:text> |
---|
154 | </xsl:element> |
---|
155 | <xsl:text> or in </xsl:text> |
---|
156 | <xsl:element name="link"> |
---|
157 | <xsl:attribute name="xl:href"> |
---|
158 | <xsl:value-of select="'../many/superbib01/index.html'"/> |
---|
159 | </xsl:attribute> |
---|
160 | <xsl:text>several </xsl:text> |
---|
161 | </xsl:element> <xsl:text> (one by author)</xsl:text>. |
---|
162 | </para> |
---|
163 | |
---|
164 | <xsl:call-template name="para_lastupdate_bib"> |
---|
165 | <xsl:with-param name="language" select="@xml:lang"/> |
---|
166 | <xsl:with-param name="date" select="d:info/d:date"/> |
---|
167 | </xsl:call-template> |
---|
168 | |
---|
169 | <xsl:call-template name="years"/> |
---|
170 | |
---|
171 | <figure xml:id="fig_pubbyyears"><title>Nb of publications by years</title> |
---|
172 | <mediaobject> |
---|
173 | <imageobject> |
---|
174 | <imagedata fileref="../../images/years.png" format="PNG"/> |
---|
175 | </imageobject> |
---|
176 | <textobject><phrase>[years.png]</phrase></textobject> |
---|
177 | </mediaobject> |
---|
178 | </figure> |
---|
179 | |
---|
180 | <sect1 xml:id="intro"> |
---|
181 | <title>Introduction</title> |
---|
182 | <para> |
---|
183 | This document provide bibliography sorted by year. |
---|
184 | </para> |
---|
185 | </sect1> |
---|
186 | |
---|
187 | <!-- loop on years --> |
---|
188 | <xsl:for-each select="$list_years"> |
---|
189 | <xsl:sort order="descending" data-type="number" select="."/> |
---|
190 | <xsl:call-template name="one_year"> |
---|
191 | <xsl:with-param name="year" select="."/> |
---|
192 | </xsl:call-template> |
---|
193 | </xsl:for-each> |
---|
194 | </xsl:element> |
---|
195 | </xsl:template> |
---|
196 | |
---|
197 | <xsl:template match="d:info/d:date"/> |
---|
198 | <xsl:template match="d:bibliography/d:title"/> |
---|
199 | |
---|
200 | <xsl:template name="one_year"> |
---|
201 | <xsl:param name="year"/> |
---|
202 | <!-- |
---|
203 | <xsl:message>call template avec <xsl:value-of select="$year"/></xsl:message> |
---|
204 | <xsl:message>noeud courant <xsl:value-of select="name(.)"/></xsl:message> |
---|
205 | <xsl:message> |
---|
206 | year_<xsl:value-of select="$year"/> : <xsl:value-of select="count(/descendant::d:biblioentry[child::d:biblioset[child::d:pubdate=$year]]) + count(/descendant::d:biblioentry[child::d:date=$year])"/> |
---|
207 | </xsl:message> |
---|
208 | --> |
---|
209 | <xsl:element name="sect1"> |
---|
210 | <xsl:attribute name="xml:id"><xsl:value-of select="concat('year_',$year)"/></xsl:attribute> |
---|
211 | <xsl:element name="title"> |
---|
212 | <xsl:value-of select="$year"/> |
---|
213 | <xsl:element name="link"> |
---|
214 | <xsl:attribute name="xl:href"><xsl:text>#top</xsl:text></xsl:attribute> |
---|
215 | <xsl:element name="inlinemediaobject"> |
---|
216 | <xsl:element name="imageobject"> |
---|
217 | <xsl:element name="imagedata"> |
---|
218 | <xsl:attribute name="fileref">../../images/globalicondl11x10_up.gif</xsl:attribute> |
---|
219 | </xsl:element> |
---|
220 | </xsl:element> |
---|
221 | <xsl:element name="textobject"> |
---|
222 | <xsl:element name="phrase"> |
---|
223 | <xsl:text>top</xsl:text> |
---|
224 | </xsl:element> |
---|
225 | </xsl:element> |
---|
226 | </xsl:element> |
---|
227 | </xsl:element> |
---|
228 | </xsl:element> |
---|
229 | <orderedlist> |
---|
230 | <xsl:for-each select="/descendant::d:biblioentry[child::d:biblioset[child::d:pubdate=$year]]|/descendant::d:biblioentry[child::d:date=$year]"> |
---|
231 | <xsl:sort order="ascending" data-type="text" select="translate(./authorgroup/author/personname,'abcdefghijklmnopqrstuvwxyz éèçàùëöñó','ABCDEFGHIJKLMNOPQRSTUVWXYZ_EECAUEONO')"/> |
---|
232 | <xsl:call-template name="one_biblioentry"> |
---|
233 | <xsl:with-param name="visu_modif" select="'visu'"/> |
---|
234 | <xsl:with-param name="my_biblioentry" select="."/> |
---|
235 | </xsl:call-template> |
---|
236 | </xsl:for-each> |
---|
237 | </orderedlist> |
---|
238 | </xsl:element> |
---|
239 | </xsl:template> |
---|
240 | |
---|
241 | </xsl:stylesheet> |
---|