Warning, /pim/akonadi/src/server/storage/schema.xsl is written in an unsupported language. File is not indexed.

0001 <!--
0002     SPDX-FileCopyrightText: 2013 Volker Krause <vkrause@kde.org>
0003 
0004     SPDX-License-Identifier: LGPL-2.0-or-later
0005 -->
0006 
0007 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
0008                 version="1.0">
0009 <xsl:output method="text" encoding="utf-8"/>
0010 
0011 <xsl:include href="schema-header.xsl"/>
0012 <xsl:include href="schema-source.xsl"/>
0013 
0014 <!-- select whether to generate header or implementation code. -->
0015 <xsl:param name="code">header</xsl:param>
0016 <!-- name of the generated schema class -->
0017 <xsl:param name="className">MySchema</xsl:param>
0018 <!-- name of the generated file -->
0019 <xsl:param name="fileName">schema</xsl:param>
0020 
0021 <xsl:template name="indexes">
0022   <xsl:param name="var"/>
0023   <xsl:value-of select="$var"></xsl:value-of>.indexes.reserve(<xsl:value-of select="count(index)"/>);
0024   <xsl:for-each select="index">
0025     {
0026       IndexDescription idx;
0027       idx.name = QStringLiteral("<xsl:value-of select="@name"/>");
0028       idx.columns = QStringLiteral("<xsl:value-of select="@columns"/>").split(QLatin1Char( ',' ), Qt::SkipEmptyParts);
0029       <xsl:if test="@unique">
0030       idx.isUnique = <xsl:value-of select="@unique"/>;
0031       </xsl:if>
0032       <xsl:if test="@sort">
0033       idx.sort = QStringLiteral("<xsl:value-of select="@sort"/>");
0034       </xsl:if>
0035 
0036       <xsl:value-of select="$var"></xsl:value-of>.indexes.push_back(idx);
0037     }
0038   </xsl:for-each>
0039 </xsl:template>
0040 
0041 
0042 
0043 <xsl:template match="/">
0044 /*
0045  * This is an auto-generated file.
0046  * Do not edit! All changes made to it will be lost.
0047  */
0048 
0049 <!-- header generation -->
0050 <xsl:if test="$code='header'">
0051 <xsl:call-template name="schema-header"/>
0052 </xsl:if>
0053 
0054 <!-- cpp generation -->
0055 <xsl:if test="$code='source'">
0056 <xsl:call-template name="schema-source"/>
0057 </xsl:if>
0058 
0059 </xsl:template>
0060 </xsl:stylesheet>
0061