Latest wadl-tools xsls

This commit is contained in:
dcramer 2012-02-07 08:31:29 -06:00
parent 9f66b847fc
commit 274e4134b0
12 changed files with 4571 additions and 0 deletions

10
clouddocs-plugin.xpr Normal file
View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="13.2">
<meta>
<filters directoryPatterns="" filePatterns="" positiveFilePatterns="" showHiddenFiles="false"/>
<options/>
</meta>
<projectTree name="clouddocs-plugin.xpr">
<folder path="src/"/>
</projectTree>
</project>

468
pom.xml.real Normal file
View File

@ -0,0 +1,468 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.rackspace.cloud.api</groupId>
<artifactId>clouddocs-maven-plugin</artifactId>
<name>Cloud API Docs Plugin</name>
<version>1.0.10-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<properties>
<wadl.tools.version>1.0.0</wadl.tools.version>
</properties>
<description>
Generates a XHTML and API documents.
</description>
<repositories>
<repository>
<id>public.maven.research.rackspace.com</id>
<name>Rackspace Research</name>
<url>http://maven.research.rackspacecloud.com/content/groups/aggregate</url>
</repository>
<repository>
<id>releases.maven.research.rackspace.com</id>
<name>Rackspace Research Releases</name>
<url>http://maven.research.rackspacecloud.com/content/repositories/releases</url>
</repository>
<repository>
<id>trancecode.org</id>
<name>Trance Code Release Repo</name>
<url>http://maven.trancecode.org/releases/</url>
</repository>
<repository>
<id>snapshots.trancecode.org</id>
<name>Trance Code Snapshot Repo</name>
<url>http://maven.trancecode.org/snapshots/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>com.agilejava.docbkx</groupId>
<artifactId>docbkx-maven-plugin</artifactId>
<version>2.0.13</version>
</dependency>
<dependency>
<groupId>com.rackspace.papi.components</groupId>
<artifactId>translation</artifactId>
<version>1.0.6</version>
</dependency>
<dependency>
<groupId>com.xmlcalabash</groupId>
<artifactId>calabash</artifactId>
<version>0.9.38</version>
</dependency>
<dependency>
<groupId>net.sf.saxon</groupId>
<artifactId>saxon</artifactId>
<version>9.3</version>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.0-alpha4</version>
</dependency>
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging-api</artifactId>
<version>1.1</version>
</dependency>
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>1.5</version>
</dependency>
<dependency>
<groupId>com.thaiopensource</groupId>
<artifactId>jing</artifactId>
<version>20091111</version>
</dependency>
<dependency>
<groupId>org.ccil.cowan.tagsoup</groupId>
<artifactId>tagsoup</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.3</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-all</artifactId>
<version>1.8.5</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>net.sf.docbook</groupId>
<artifactId>docbook-xsl</artifactId>
<version>1.76.1</version>
<type>zip</type>
<classifier>ns-resources</classifier>
</dependency>
<dependency>
<groupId>xerces</groupId>
<artifactId>xercesImpl</artifactId>
<version>2.8.0</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>xerces</groupId>
<artifactId>xmlParserAPIs</artifactId>
<version>2.6.2</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.avalon.framework</groupId>
<artifactId>avalon-framework-impl</artifactId>
<version>4.3.1</version>
</dependency>
<dependency>
<groupId>xalan</groupId>
<artifactId>xalan</artifactId>
<version>2.7.0</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>com.agilejava.docbkx</groupId>
<artifactId>docbkx-maven-base</artifactId>
<version>2.0.13</version>
</dependency>
<dependency>
<groupId>net.sf.xslthl</groupId>
<artifactId>xslthl</artifactId>
<version>2.0.1</version>
</dependency>
<dependency>
<groupId>net.sf.docbook</groupId>
<artifactId>docbook-xsl-saxon</artifactId>
<version>1.0.0</version>
</dependency>
<dependency>
<groupId>org.apache.xmlgraphics</groupId>
<artifactId>fop</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>xml-apis</groupId>
<artifactId>xml-apis-ext</artifactId>
<version>1.3.04</version>
</dependency>
<dependency>
<groupId>xml-apis</groupId>
<artifactId>xml-apis</artifactId>
<version>1.3.04</version>
</dependency>
<dependency>
<groupId>batik</groupId>
<artifactId>batik-rasterizer</artifactId>
<version>1.6</version>
</dependency>
<dependency>
<groupId>batik</groupId>
<artifactId>batik-swing</artifactId>
<version>1.6</version>
</dependency>
<dependency>
<groupId>org.apache.maven.shared</groupId>
<artifactId>maven-plugin-testing-harness</artifactId>
<version>1.0-beta-1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.rackspace.cloud.api</groupId>
<artifactId>wadl-tools</artifactId>
<version>${wadl.tools.version}</version>
<scope>provided</scope>
</dependency>
</dependencies>
<scm>
<connection>scm:git:ssh://git@git-n01.rcloudtech.rackspacecloud.com/rc-maven-cloud-docs.git</connection>
</scm>
<distributionManagement>
<repository>
<id>releases.maven.research.rackspacecloud.com</id>
<name>Rackspace Cloud Research Releases</name>
<url>http://maven.research.rackspacecloud.com/content/repositories/releases/</url>
</repository>
<snapshotRepository>
<id>snapshots.maven.research.rackspacecloud.com</id>
<name>Rackspace Cloud Research Snapshots</name>
<url>http://maven.research.rackspacecloud.com/content/repositories/snapshots/</url>
</snapshotRepository>
</distributionManagement>
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
<resource>
<directory>target/generated-resources</directory>
</resource>
</resources>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<id>copy</id>
<phase>generate-sources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>net.sf.docbook</groupId>
<artifactId>docbook-xsl</artifactId>
<version>1.76.1</version>
<type>zip</type>
<classifier>ns-resources</classifier>
<outputDirectory>target</outputDirectory>
<includes>docbook/template/*</includes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
<execution>
<id>unpack</id>
<phase>initialize</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>com.rackspace.cloud.api</groupId>
<artifactId>wadl-tools</artifactId>
<version>${wadl.tools.version}</version>
<type>jar</type>
<overWrite>true</overWrite>
<outputDirectory>target/classes/cloud/normalizeWadl</outputDirectory>
<destFileName></destFileName>
<includes>
**/normalizeWadl1.xsl,
**/normalizeWadl2.xsl,
**/normalizeWadl3.xsl,
**/normalizeWadl4.xsl
</includes>
<excludes>**/*.xml,**/*.xsd,**/*.dtd,**/*.sch,**/*.class,**/*.properties,**/*.MF</excludes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xml-maven-plugin</artifactId>
<version>1.0</version>
<executions>
<execution>
<goals>
<goal>transform</goal>
</goals>
</execution>
</executions>
<configuration>
<transformationSets>
<transformationSet>
<dir>src/main/resources/cloud/fo/titlepage</dir>
<stylesheet>target/docbook/template/titlepage.xsl</stylesheet>
<outputDir>target/generated-resources/cloud/fo</outputDir>
<fileMappers>
<fileMapper
implementation="org.codehaus.plexus.components.io.filemappers.FileExtensionMapper">
<targetExtension>.xsl</targetExtension>
</fileMapper>
</fileMappers>
</transformationSet>
<transformationSet>
<dir>src/main/resources/cloud/webhelp/titlepage</dir>
<stylesheet>target/docbook/template/titlepage.xsl</stylesheet>
<outputDir>target/generated-resources/cloud/webhelp</outputDir>
<fileMappers>
<fileMapper
implementation="org.codehaus.plexus.components.io.filemappers.FileExtensionMapper">
<targetExtension>.xsl</targetExtension>
</fileMapper>
</fileMappers>
</transformationSet>
</transformationSets>
</configuration>
</plugin>
<plugin>
<groupId>com.agilejava.docbkx</groupId>
<artifactId>docbkx-builder-maven-plugin</artifactId>
<version>2.0.13</version>
<executions>
<execution>
<id>generate-xhtml</id>
<goals>
<goal>build</goal>
</goals>
<configuration>
<type>xhtml</type>
<superClassName>com.rackspace.cloud.api.docs.HTMLMojo</superClassName>
<excludedProperties>${excluded.properties},root.filename,base.dir</excludedProperties>
</configuration>
</execution>
<execution>
<id>generate-pdf</id>
<goals>
<goal>build</goal>
</goals>
<configuration>
<type>fo</type>
<superClassName>com.rackspace.cloud.api.docs.PDFMojo</superClassName>
<className>DocbkxPdfMojo</className>
<pluginSuffix>pdf</pluginSuffix>
<excludedProperties>${excluded.properties}</excludedProperties>
</configuration>
</execution>
<execution>
<id>generate-webhelp</id>
<goals>
<goal>build</goal>
</goals>
<configuration>
<type>webhelp</type>
<stylesheetPath>webhelp/xsl/webhelp.xsl</stylesheetPath>
<superClassName>com.rackspace.cloud.api.docs.WebHelpMojo</superClassName>
<excludedProperties>
${excluded.properties},root.filename,base.dir,webhelp.base.dir,manifest.in.base.dir
</excludedProperties>
<useStandardOutput>false</useStandardOutput>
</configuration>
</execution>
<execution>
<id>generate-eclipse</id>
<goals>
<goal>build</goal>
</goals>
<configuration>
<type>eclipse</type>
<stylesheetPath>eclipse/eclipse.xsl</stylesheetPath>
<superClassName>com.rackspace.cloud.api.docs.EclipseMojo</superClassName>
<excludedProperties>${excluded.properties},root.filename,base.dir,manifest.in.base.dir
</excludedProperties>
<useStandardOutput>false</useStandardOutput>
</configuration>
</execution>
<execution>
<id>generate-epub</id>
<goals>
<goal>build</goal>
</goals>
<configuration>
<type>epub</type>
<superClassName>com.rackspace.cloud.api.docs.EpubMojo</superClassName>
<excludedProperties>
${excluded.properties},root.filename,base.dir,epub.oebps.dir,epub.metainf.dir,manifest.in.base.dir,epub.opf.filename
</excludedProperties>
<useStandardOutput>false</useStandardOutput>
</configuration>
</execution>
</executions>
<configuration>
<packageName>com.agilejava.docbkx.maven</packageName>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
</plugins>
</build>
</project>

View File

@ -0,0 +1,345 @@
package com.rackspace.cloud.api.docs;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.net.URL;
import java.security.CodeSource;
import java.util.*;
import java.util.zip.ZipInputStream;
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerConfigurationException;
import javax.xml.transform.TransformerException;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.stream.StreamSource;
import javax.xml.transform.stream.StreamResult;
import javax.xml.transform.Source;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import org.w3c.dom.Document;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult;
import org.xml.sax.EntityResolver;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import java.io.StringReader;
import org.apache.maven.plugin.MojoExecutionException;
import com.agilejava.docbkx.maven.AbstractWebhelpMojo;
import com.agilejava.docbkx.maven.TransformerBuilder;
<<<<<<< HEAD
=======
import com.agilejava.docbkx.maven.PreprocessingFilter;
>>>>>>> Run Calabash pipeline on Webhelp.
import javax.xml.transform.URIResolver;
import com.rackspace.cloud.api.docs.DocBookResolver;
import com.agilejava.docbkx.maven.Parameter;
import com.agilejava.docbkx.maven.FileUtils;
public abstract class WebHelpMojo extends AbstractWebhelpMojo {
/**
* Sets the URI for the glossary.
*
* @parameter expression="${glossary.uri}" default-value=""
*/
private String glossaryUri;
private File sourceDirectory;
private File sourceDocBook;
private File atomFeed;
private File atomFeedClean;
private static final String COPY_XSL = "cloud/webhelp/copy.xsl";
/**
* @parameter expression="${project.build.directory}"
*/
private String projectBuildDirectory;
/**
* Controls whether output is colorized based on revisionflag attributes.
*
* @parameter expression="${generate-webhelp.show.changebars}"
*/
private String showChangebars;
/**
* Controls whether output is colorized based on revisionflag attributes.
*
* @parameter expression="${generate-webhelp.meta.robots}"
*/
private String metaRobots;
/**
* Controls whether the version string is used as part of the Disqus identifier.
*
* @parameter expression="${generate-webhelp.use.version.for.disqus}" default-value="0"
*/
private String useVersionForDisqus;
/**
* Controls whether the disqus identifier is used.
*
* @parameter expression="${generate-webhelp.use.disqus.id}" default-value="1"
*/
private String useDisqusId;
/**
* Controls the branding of the output.
*
* @parameter expression="${generate-webhelp.branding}" default-value="rackspace"
*/
private String branding;
/**
* Controls whether Disqus comments appear at the bottom of each page.
*
* @parameter expression="${generate-webhelp.enable.disqus}" default-value="0"
*/
private String enableDisqus;
/**
* A parameter used by the Disqus comments.
*
* @parameter expression="${generate-webhelp.disqus.shortname}" default-value=""
*/
private String disqusShortname;
/**
* A parameter used to control whether to include Google Analytics goo.
*
* @parameter expression="${generate-webhelp.enable.google.analytics}" default-value=""
*/
private String enableGoogleAnalytics;
/**
* A parameter used to control whether to include Google Analytics goo.
*
* @parameter expression="${generate-webhelp.google.analytics.id}" default-value=""
*/
private String googleAnalyticsId;
/**
* A parameter used to specify the path to the pdf for download in webhelp.
*
* @parameter expression="${generate-webhelp.pdf.url}" default-value=""
*/
private String pdfUrl;
/**
* A parameter used to specify the path to the pdf for download in webhelp.
*
* @parameter expression="${generate-webhelp.canonical.url.base}" default-value=""
*/
private String canonicalUrlBase;
/**
* A parameter used to specify the security level (external, internal, reviewer, writeronly) of the document.
*
* @parameter expression="${generate-webhelp.security}" default-value=""
*/
private String security;
/**
* A parameter used to configure how many elements to trim from the URI in the documentation for a wadl method.
*
* @parameter expression="${generate-webhelp.trim.wadl.uri.count}" default-value=""
*/
private String trimWadlUriCount;
/**
* Controls how the path to the wadl is calculated. If 0 or not set, then
* The xslts look for the normalized wadl in /generated-resources/xml/xslt/.
* Otherwise, in /generated-resources/xml/xslt/path/to/docbook-src, e.g.
* /generated-resources/xml/xslt/src/docbkx/foo.wadl
*
* @parameter expression="${generate-webhelp.compute.wadl.path.from.docbook.path}" default-value="0"
*/
private String computeWadlPathFromDocbookPath;
/**
* Sets the email for TildeHash (internal) comments. Note that this
* doesn't affect Disqus comments.
*
* @parameter expression="${generate-webhelp.feedback.email}" default-value=""
*/
private String feedbackEmail;
/**
* Controls whether or not the social icons are displayed.
*
* @parameter expression="${generate-webhelp.social.icons}" default-value="0"
*/
private String socialIcons;
/**
* DOCUMENT ME!
*
* @param transformer DOCUMENT ME!
* @param sourceFilename DOCUMENT ME!
* @param targetFile DOCUMENT ME!
*/
public void adjustTransformer(Transformer transformer, String sourceFilename, File targetFile) {
super.adjustTransformer(transformer, sourceFilename, targetFile);
if(glossaryUri != null){
transformer.setParameter("glossary.uri", glossaryUri);
}
if(feedbackEmail != null){
transformer.setParameter("feedback.email", feedbackEmail);
}
if(useDisqusId != null){
transformer.setParameter("use.disqus.id", useDisqusId);
}
if (useVersionForDisqus != null) {
transformer.setParameter("use.version.for.disqus", useVersionForDisqus);
}
transformer.setParameter("project.build.directory", projectBuildDirectory);
transformer.setParameter("branding", branding);
transformer.setParameter("enable.disqus", enableDisqus);
if (disqusShortname != null) {
transformer.setParameter("disqus.shortname", disqusShortname);
}
if (enableGoogleAnalytics != null) {
transformer.setParameter("enable.google.analytics", enableGoogleAnalytics);
}
if (googleAnalyticsId != null) {
transformer.setParameter("google.analytics.id", googleAnalyticsId);
}
if (pdfUrl != null) {
transformer.setParameter("pdf.url", pdfUrl);
}
if(canonicalUrlBase != null){
transformer.setParameter("canonical.url.base",canonicalUrlBase);
}
if(security != null){
transformer.setParameter("security",security);
}
if(showChangebars != null){
transformer.setParameter("show.changebars",showChangebars);
}
if(metaRobots != null){
transformer.setParameter("meta.robots",metaRobots);
}
if(trimWadlUriCount != null){
transformer.setParameter("trim.wadl.uri.count",trimWadlUriCount);
}
transformer.setParameter("social.icons",socialIcons);
sourceDocBook = new File(sourceFilename);
sourceDirectory = sourceDocBook.getParentFile();
transformer.setParameter("docbook.infile",sourceDocBook.getAbsolutePath());
transformer.setParameter("source.directory",sourceDirectory);
transformer.setParameter("compute.wadl.path.from.docbook.path",computeWadlPathFromDocbookPath);
}
protected TransformerBuilder createTransformerBuilder(URIResolver resolver) {
return super.createTransformerBuilder(new DocBookResolver(resolver, getType()));
}
//Note for this to work, you need to have the customization layer in place.
protected String getNonDefaultStylesheetLocation() {
return "cloud/webhelp/profile-webhelp.xsl";
}
public void postProcessResult(File result) throws MojoExecutionException {
super.postProcessResult(result);
copyTemplate(result);
transformFeed(result);
}
protected void copyTemplate(File result) throws MojoExecutionException {
final File targetDirectory = result.getParentFile();
com.rackspace.cloud.api.docs.FileUtils.extractJaredDirectory("content", WebHelpMojo.class, targetDirectory);
com.rackspace.cloud.api.docs.FileUtils.extractJaredDirectory("common", WebHelpMojo.class, targetDirectory);
com.agilejava.docbkx.maven.FileUtils.copyFile(new File(targetDirectory, "common/images/favicon-" + branding + ".ico"), new File(targetDirectory, "favicon.ico"));
com.agilejava.docbkx.maven.FileUtils.copyFile(new File(targetDirectory, "common/css/positioning-" + branding + ".css"), new File(targetDirectory, "common/css/positioning.css"));
com.agilejava.docbkx.maven.FileUtils.copyFile(new File(targetDirectory, "common/main-" + branding + ".js"), new File(targetDirectory, "common/main.js"));
}
protected void transformFeed(File result) throws MojoExecutionException {
try {
atomFeed = new File (result.getParentFile(),"atom-doctype.xml");
atomFeedClean = new File (result.getParentFile(),"atom.xml");
if(!atomFeed.isFile()){
return;
}
ClassLoader classLoader = Thread.currentThread()
.getContextClassLoader();
TransformerFactory factory = TransformerFactory.newInstance();
Transformer transformer = factory.newTransformer(new StreamSource(classLoader.getResourceAsStream(COPY_XSL)));
atomFeedClean = new File(result.getParentFile(), "atom.xml");
DocumentBuilderFactory dbfactory = DocumentBuilderFactory.newInstance();
dbfactory.setValidating(false);
DocumentBuilder builder = dbfactory.newDocumentBuilder();
builder.setEntityResolver(new EntityResolver() {
@Override
public InputSource resolveEntity(String publicId, String systemId)
throws SAXException, IOException {
return new InputSource(new StringReader(""));
}
});
atomFeed = new File(result.getParentFile(), "atom-doctype.xml");
Document xmlDocument = builder.parse(atomFeed);
DOMSource source = new DOMSource(xmlDocument);
transformer.transform(source, new StreamResult(atomFeedClean));
atomFeed.deleteOnExit();
} catch (TransformerConfigurationException e) {
throw new MojoExecutionException("Failed to load JAXP configuration", e);
} catch (javax.xml.parsers.ParserConfigurationException e) {
throw new MojoExecutionException("Failed to configure parser", e);
} catch (org.xml.sax.SAXException e) {
throw new MojoExecutionException("Sax exception", e);
} catch (java.io.IOException e) {
throw new MojoExecutionException("IO Exception", e);
} catch (TransformerException e) {
throw new MojoExecutionException("Failed to transform to atom feed", e);
}
}
@Override
protected Source createSource(String inputFilename, File sourceFile, PreprocessingFilter filter)
throws MojoExecutionException {
String pathToPipelineFile = "classpath:/test.xpl"; //use "classpath:/path" for this to work
Source source = super.createSource(inputFilename, sourceFile, filter);
return CalabashHelper.createSource(source, pathToPipelineFile);
}
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,299 @@
<?xml version="1.1" encoding="UTF-8"?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:exslt="http://exslt.org/common"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:d="http://docbook.org/ns/docbook"
xmlns:wadl="http://wadl.dev.java.net/2009/02"
xmlns:rax="http://docs.rackspace.com/api"
xmlns="http://www.w3.org/1999/xhtml"
version="1.0"
exclude-result-prefixes="exslt">
<!-- First import the non-chunking templates that format elements
within each chunk file. In a customization, you should
create a separate non-chunking customization layer such
as mydocbook.xsl that imports the original docbook.xsl and
customizes any presentation templates. Then your chunking
customization should import mydocbook.xsl instead of
docbook.xsl. -->
<xsl:import href="docbook.xsl"/>
<!-- chunk-common.xsl contains all the named templates for chunking.
In a customization file, you import chunk-common.xsl, then
add any customized chunking templates of the same name.
They will have import precedence over the original
chunking templates in chunk-common.xsl. -->
<xsl:import href="urn:docbkx:stylesheet-base/xhtml-1_1/chunk-common.xsl"/>
<!-- The manifest.xsl module is no longer imported because its
templates were moved into chunk-common and chunk-code -->
<!-- chunk-code.xsl contains all the chunking templates that use
a match attribute. In a customization it should be referenced
using <xsl:include> instead of <xsl:import>, and then add
any customized chunking templates with match attributes. But be sure
to add a priority="1" to such customized templates to resolve
its conflict with the original, since they have the
same import precedence.
Using xsl:include prevents adding another layer
of import precedence, which would cause any
customizations that use xsl:apply-imports to wrongly
apply the chunking version instead of the original
non-chunking version to format an element. -->
<xsl:include href="urn:docbkx:stylesheet-base/xhtml-1_1/profile-chunk-code.xsl" />
<xsl:include href="../process-embedded-wadl.xsl"/>
<!-- ======================================== -->
<xsl:variable name="preprocessed-nodes">
<xsl:apply-templates select="exslt:node-set($profiled-nodes)" mode="preprocess"/>
</xsl:variable>
<xsl:template match="d:legalnotice" mode="preprocess">
<xsl:message>
########################################
Processing legalnotice: <xsl:value-of select="@role"/>
########################################
</xsl:message>
<d:legalnotice>
<xsl:apply-templates select="@*" mode="preprocess"/>
<xsl:choose>
<xsl:when test="starts-with(string(@role),'cc-')">
<xsl:call-template name="CCLegalNotice" />
</xsl:when>
<xsl:when test="@role = 'rs-api'">
<xsl:call-template name="RSAPILegalNotice"/>
</xsl:when>
<xsl:when test="@role = 'apache2'">
<xsl:call-template name="Apache2LegalNotice"/>
</xsl:when>
</xsl:choose>
</d:legalnotice>
</xsl:template>
<!--
The abstract is supressed if the rs-api legal notice is used, as
it's incorporated into the document in this case.
-->
<xsl:template match="d:abstract" mode="preprocess">
<xsl:choose>
<xsl:when test="/*//d:legalnotice[@role = 'rs-api']" />
<xsl:otherwise>
<xsl:copy>
<xsl:apply-templates select="@*|node()" mode="preprocess"/>
</xsl:copy>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="Apache2LegalNotice">
<xsl:variable name="a2Link" select="'http://www.apache.org/licenses/LICENSE-2.0'"/>
<xsl:if test="@role = 'apache2'">
<d:para>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
</d:para>
<d:para>
<xsl:element name="d:link">
<xsl:attribute name="xlink:href">
<xsl:value-of select="$a2Link"/>
</xsl:attribute>
<xsl:value-of select="$a2Link"/>
</xsl:element>
</d:para>
<d:para>
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
</d:para>
</xsl:if>
</xsl:template>
<xsl:template name="RSAPILegalNotice">
<xsl:if test="@role = 'rs-api'">
<d:para>
<xsl:value-of select="/*/d:info/d:abstract"/>
The document is for informational purposes only and is
provided “AS IS.”
</d:para>
<d:para>
RACKSPACE MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY
KIND, EXPRESS OR IMPLIED, AS TO THE ACCURACY OR
COMPLETENESS OF THE CONTENTS OF THIS DOCUMENT AND
RESERVES THE RIGHT TO MAKE CHANGES TO SPECIFICATIONS AND
PRODUCT/SERVICES DESCRIPTION AT ANY TIME WITHOUT NOTICE.
RACKSPACE SERVICES OFFERINGS ARE SUBJECT TO CHANGE
WITHOUT NOTICE. USERS MUST TAKE FULL RESPONSIBILITY FOR
APPLICATION OF ANY SERVICES MENTIONED HEREIN. EXCEPT AS
SET FORTH IN RACKSPACE GENERAL TERMS AND CONDITIONS
AND/OR CLOUD TERMS OF SERVICE, RACKSPACE ASSUMES NO
LIABILITY WHATSOEVER, AND DISCLAIMS ANY EXPRESS OR
IMPLIED WARRANTY, RELATING TO ITS SERVICES INCLUDING,
BUT NOT LIMITED TO, THE IMPLIED WARRANTY OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND
NONINFRINGEMENT.
</d:para>
<d:para>
Except as expressly provided in any written license
agreement from Rackspace, the furnishing of this
document does not give you any license to patents,
trademarks, copyrights, or other intellectual property.
</d:para>
<d:para>
Rackspace®, Rackspace logo and Fanatical Support® are
registered service marks of Rackspace US,
Inc. All other product names and trademarks
used in this document are for identification purposes
only and are property of their respective owners.
</d:para>
</xsl:if>
</xsl:template>
<xsl:template name="CCLegalNotice">
<xsl:if test="starts-with(string(@role),'cc-')">
<xsl:variable name="ccid"><xsl:value-of select="substring-after(string(@role),'cc-')"/></xsl:variable>
<xsl:variable name="ccidURL">http://creativecommons.org/licenses/<xsl:value-of select="$ccid"/>/3.0/legalcode</xsl:variable>
<d:informaltable frame="void">
<d:col width="10%"/>
<d:col width="90%"/>
<d:tbody>
<d:tr>
<d:td>
<d:link xlink:href="{$ccidURL}">
<d:informalfigure>
<d:mediaobject>
<d:imageobject>
<d:imagedata
fileref="../common/images/cc/{$ccid}.png"
align="center"
valign="middle"/>
</d:imageobject>
</d:mediaobject>
</d:informalfigure>
</d:link>
</d:td>
<d:td>
<d:para>Except where otherwise noted, this document is licensed under
<xsl:element name="d:link">
<xsl:attribute name="xlink:href">
<xsl:value-of select="$ccidURL"/>
</xsl:attribute>
<d:emphasis role="bold">
Creative Commons Attribution
<xsl:choose>
<xsl:when test="$ccid = 'by'" />
<xsl:when test="$ccid = 'by-sa'">
<xsl:text>ShareAlike</xsl:text>
</xsl:when>
<xsl:when test="$ccid = 'by-nd'">
<xsl:text>NoDerivatives</xsl:text>
</xsl:when>
<xsl:when test="$ccid = 'by-nc'">
<xsl:text>NonCommercial</xsl:text>
</xsl:when>
<xsl:when test="$ccid = 'by-nc-sa'">
<xsl:text>NonCommercial ShareAlike</xsl:text>
</xsl:when>
<xsl:when test="$ccid = 'by-nc-nd'">
<xsl:text>NonCommercial NoDerivatives</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:message terminate="yes">
I don't understand licence <xsl:value-of select="$ccid"/>
</xsl:message>
</xsl:otherwise>
</xsl:choose>
3.0 License
</d:emphasis>
</xsl:element>
</d:para>
<d:para>
<d:link xlink:href="{$ccidURL}">
<xsl:value-of select="$ccidURL"/>
</d:link>
</d:para>
</d:td>
</d:tr>
</d:tbody>
</d:informaltable>
</xsl:if>
</xsl:template>
<xsl:template match="/" priority="1">
<!-- * Get a title for current doc so that we let the user -->
<!-- * know what document we are processing at this point. -->
<xsl:variable name="doc.title">
<xsl:call-template name="get.doc.title"/>
</xsl:variable>
<xsl:choose>
<xsl:when test="false()"/>
<!-- Can't process unless namespace removed -->
<xsl:when test="false()"/>
<xsl:otherwise>
<xsl:choose>
<xsl:when test="$rootid != ''">
<xsl:choose>
<xsl:when test="count($preprocessed-nodes//*[@id=$rootid]) = 0">
<xsl:message terminate="yes">
<xsl:text>ID '</xsl:text>
<xsl:value-of select="$rootid"/>
<xsl:text>' not found in document.</xsl:text>
</xsl:message>
</xsl:when>
<xsl:otherwise>
<xsl:if test="$collect.xref.targets = 'yes' or $collect.xref.targets = 'only'">
<xsl:apply-templates select="key('id', $rootid)" mode="collect.targets"/>
</xsl:if>
<xsl:if test="$collect.xref.targets != 'only'">
<xsl:apply-templates select="exslt:node-set($preprocessed-nodes//*[@id=$rootid])" mode="process.root"/>
<xsl:if test="$tex.math.in.alt != ''">
<xsl:apply-templates select="exslt:node-set($preprocessed-nodes//*[@id=$rootid])" mode="collect.tex.math"/>
</xsl:if>
<xsl:if test="$generate.manifest != 0">
<xsl:call-template name="generate.manifest">
<xsl:with-param name="node" select="key('id',$rootid)"/>
</xsl:call-template>
</xsl:if>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:if test="$collect.xref.targets = 'yes' or $collect.xref.targets = 'only'">
<xsl:apply-templates select="exslt:node-set($preprocessed-nodes)" mode="collect.targets"/>
</xsl:if>
<xsl:if test="$collect.xref.targets != 'only'">
<xsl:apply-templates select="exslt:node-set($preprocessed-nodes)" mode="process.root"/>
<xsl:if test="$tex.math.in.alt != ''">
<xsl:apply-templates select="exslt:node-set($preprocessed-nodes)" mode="collect.tex.math"/>
</xsl:if>
<xsl:if test="$generate.manifest != 0">
<xsl:call-template name="generate.manifest">
<xsl:with-param name="node" select="exslt:node-set($preprocessed-nodes)"/>
</xsl:call-template>
</xsl:if>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
<xsl:call-template name="revhistory2atom"/>
</xsl:template>
<xsl:template match="d:releaseinfo" mode="rackspace-title">
&#160;-&#160;<xsl:value-of select="normalize-space(.)"/>
</xsl:template>
</xsl:stylesheet>

View File

@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:wadl="http://wadl.dev.java.net/2009/02"
xmlns:rax="http://docs.rackspace.com/api"
version="1.0">
<xsl:template match="/">
<xsl:message>
0="<xsl:value-of select="0"/>"
</xsl:message>
</xsl:template>
<xsl:variable name="types">
<rax:types>
<xsl:apply-templates select="//wadl:param" mode="types"/>
</rax:types>
</xsl:variable>
<xsl:template match="wadl:param" mode="types">
<rax:type
type="{@type}"
namespace-prefix="{substring-before(@type,':')}"
namespace-uri=""
/>
</xsl:template>
</xsl:stylesheet>

View File

@ -0,0 +1,731 @@
<?xml version="1.0"?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY lowercase "'abcdefghijklmnopqrstuvwxyz'">
<!ENTITY uppercase "'ABCDEFGHIJKLMNOPQRSTUVWXYZ'">
]>
<xsl:stylesheet exclude-result-prefixes="d"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:d="http://docbook.org/ns/docbook"
xmlns:exsl="http://exslt.org/common"
xmlns:ng="http://docbook.org/docbook-ng"
xmlns:db="http://docbook.org/ns/docbook"
version="1.0" xmlns="http://www.w3.org/1999/xhtml">
<!-- <xsl:import href="../../xhtml/chunk.xsl"/> -->
<xsl:import href="urn:docbkx:stylesheet-base/xhtml/docbook.xsl" />
<xsl:output
method="html"
encoding="utf-8"
cdata-section-elements=""/>
<xsl:param name="meta.robots"/>
<xsl:param name="meta.robots.calculated">
<xsl:choose>
<xsl:when test="$meta.robots = '1'">NOINDEX, NOFOLLOW</xsl:when>
<xsl:when test="$meta.robots = '0' or $meta.robots = ''"/>
<xsl:otherwise><xsl:value-of select="$meta.robots"/></xsl:otherwise>
</xsl:choose>
</xsl:param>
<xsl:variable name="default.topic">
<xsl:choose>
<xsl:when test="$webhelp.default.topic != ''">
<xsl:value-of select="$webhelp.default.topic"/>
</xsl:when>
<xsl:when test="$htmlhelp.default.topic != ''">
<xsl:value-of select="$htmlhelp.default.topic"/>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="make-relative-filename">
<xsl:with-param name="base.dir"/>
<xsl:with-param name="base.name">
<xsl:choose>
<xsl:when test="$rootid != ''">
<xsl:apply-templates select="key('id',$rootid)" mode="chunk-filename"/>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates
select="*/*[self::d:preface|self::d:glossary|self::d:chapter|self::d:appendix|self::d:part|self::d:section][1]"
mode="chunk-filename"/>
</xsl:otherwise>
</xsl:choose>
</xsl:with-param>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<!-- webhelp-specific params! -->
<!-- To be added to normal params file someday -->
<xsl:param name="webhelp.include.search.tab">true</xsl:param>
<xsl:param name="webhelp.start.filename">index.html</xsl:param>
<xsl:param name="webhelp.base.dir">docs</xsl:param>
<xsl:param name="webhelp.tree.cookie.id" select="concat( 'treeview-', count(//node()) )"/>
<xsl:param name="webhelp.indexer.language">en</xsl:param>
<xsl:param name="webhelp.default.topic"/>
<xsl:param name="webhelp.autolabel">0</xsl:param>
<!-- webhelp-specific params! -->
<!-- Set some reasonable defaults for webhelp output -->
<xsl:param name="chunker.output.indent">no</xsl:param>
<xsl:param name="navig.showtitles">0</xsl:param>
<xsl:param name="manifest.in.base.dir" select="0"/>
<xsl:param name="base.dir" select="concat($webhelp.base.dir,'/content/')"/>
<xsl:param name="suppress.navigation">0</xsl:param>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="inherit.keywords" select="'0'"/>
<xsl:param name="local.l10n.xml" select="document('')"/>
<xsl:param name="para.propagates.style" select="1"/>
<xsl:param name="phrase.propagates.style" select="1"/>
<xsl:param name="chunk.first.sections" select="1"/>
<xsl:param name="chunk.section.depth" select="100"/>
<xsl:param name="chapter.autolabel" select="1"/>
<xsl:param name="section.autolabel" select="0"/>
<xsl:param name="generate.section.toc.level" select="5"/>
<i18n xmlns="http://docbook.sourceforge.net/xmlns/l10n/1.0">
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="en">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="TableofContents" text="Contents"/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<!-- The fallback mechansim doesn't seem to work for local l10n stuff -->
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="ja">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="de">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="fr">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="zh">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
</i18n>
<xsl:template name="system.head.content">
<xsl:param name="node" select="."/>
<xsl:text>
</xsl:text>
<!--
This avoids two problems in IE 8. We should someday figure out why this is happening and tweak the JavaScript so this <meta/> tag is not necessary:
1. When you perform a search and click the Toggle Highlight button, IE 8 adds a line break before the highlighted word.
2. If you click the show/hide toc button, the tab crashes.
These problems go away when you add this IE=7 mode meta tag.
-->
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<xsl:text>
</xsl:text>
</xsl:template>
<xsl:template name="user.head.content">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<!-- <xsl:message>
webhelp.tree.cookie.id = <xsl:value-of select="$webhelp.tree.cookie.id"/> +++ <xsl:value-of select="count(//node())"/>
$webhelp.indexer.language = <xsl:value-of select="$webhelp.indexer.language"/> +++ <xsl:value-of select="count(//node())"/>
</xsl:message>-->
<xsl:if test="$meta.robots.calculated != ''">
<<<<<<< HEAD
<meta name="robots" content="{$meta.robots.calculated}"/>
=======
<meta name="robots" value="{$meta.robots.calculated}"/>
>>>>>>> 566e94d2f8dbc6bfc4d6ae40eb40733093f03467
</xsl:if>
<script type="text/javascript">
//The id for tree cookie
var treeCookieId = "<xsl:value-of select="$webhelp.tree.cookie.id"/>";
var language = "<xsl:value-of select="$webhelp.indexer.language"/>";
var w = new Object();
//Localization
txt_filesfound = '<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_filesfound'"/>
</xsl:call-template>';
txt_enter_at_least_1_char = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_enter_at_least_1_char'"/>
</xsl:call-template>";
txt_browser_not_supported = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_browser_not_supported'"/>
</xsl:call-template>";
txt_please_wait = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_please_wait'"/>
</xsl:call-template>";
txt_results_for = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_results_for'"/>
</xsl:call-template>";
</script>
<style type="text/css">
input {
margin-bottom: 5px;
margin-top: 2px;
}
.folder {
display: block;
height: 22px;
padding-left: 20px;
background: transparent url(../common/jquery/treeview/images/folder.gif) 0 0px no-repeat;
}
<!--[if IE]>
input {
margin-bottom: 5px;
margin-top: 2px;
}
<![endif]-->
</style>
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon"/>
<link rel="stylesheet" type="text/css" href="../common/css/positioning.css"/>
<link rel="stylesheet" type="text/css" href="../common/css/custom.css"/>
<xsl:if test="//d:revhistory/d:revision and $canonical.url.base != ''">
<link href="../atom.xml" type="application/atom+xml" rel="alternate" title="Document ATOM Feed" />
</xsl:if>
<xsl:if test="$canonical.url.base != ''">
<link rel="canonical" >
<xsl:attribute name="href"><xsl:value-of select="$canonical.url.base"/>/<xsl:apply-templates select="." mode="chunk-filename"/></xsl:attribute>
</link>
</xsl:if>
<xsl:comment><xsl:text>[if IE]>
&lt;link rel="stylesheet" type="text/css" href="../common/css/ie.css"/>
&lt;![endif]</xsl:text></xsl:comment>
<link rel="stylesheet" type="text/css" href="../common/jquery/theme-redmond/jquery-ui-1.8.2.custom.css"/>
<link rel="stylesheet" type="text/css" href="../common/jquery/treeview/jquery.treeview.css"/>
<script type="text/javascript" src="../common/jquery/jquery-1.4.3.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery-ui-1.8.2.custom.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery.cookie.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/treeview/jquery.treeview.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery.qtip-1.0.0-rc3/jquery.qtip-1.0.0-rc3.min.js">
<xsl:comment>jQuery plugin for glossary popups. </xsl:comment>
</script>
<!--Scripts/css stylesheets for Search-->
<script type="text/javascript" src="search/htmlFileList.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/htmlFileInfoList.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/nwSearchFnt.js">
<xsl:comment> </xsl:comment>
</script>
<!--script type="text/javascript" src="search/addition.js">
<xsl:comment></xsl:comment>
</script>
<script type="text/javascript" src="search/indexLoader.js">
<xsl:comment></xsl:comment>
</script-->
<!--
NOTE: Stemmer javascript files should be in format <language>_stemmer.js.
For example, for English(en), source should be: "search/stemmers/en_stemmer.js"
For country codes, see: http://www.uspto.gov/patft/help/helpctry.htm
-->
<!--<xsl:message><xsl:value-of select="concat('search/stemmers/',$webhelp.indexer.language,'_stemmer.js')"/></xsl:message>-->
<script type="text/javascript" src="{concat('search/stemmers/',$webhelp.indexer.language,'_stemmer.js')}">
<xsl:comment>//make this scalable to other languages as well.</xsl:comment>
</script>
<!--Index Files:
Index is broken in to three equal sized(number of index items) files. This is to help parallel downloading
of files to make it faster.-->
<script type="text/javascript" src="search/index-1.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/index-2.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/index-3.js">
<xsl:comment> </xsl:comment>
</script>
<!--End of index files -->
<xsl:if test="$enable.google.analytics = '1' and not($google.analytics.id = '')">
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', '<xsl:value-of select="$google.analytics.id"/>']);
</script>
<script type="text/javascript" src="../common/ga.js">
<xsl:comment></xsl:comment>
</script>
<!-- Google Analytics Social Button Tracking -->
<script type="text/javascript" src="http://www.tabpress.com/_js/ga_social_tracking.js">
<xsl:comment></xsl:comment>
</script>
<!-- Load Twitter JS-API asynchronously -->
<script>
(function(){var twitterWidgets = document.createElement('script');
twitterWidgets.type = 'text/javascript';
twitterWidgets.async = true;
twitterWidgets.src = 'http://platform.twitter.com/widgets.js';
// Setup a callback to track once the script loads.
twitterWidgets.onload = _ga.trackTwitter;
document.getElementsByTagName('head')[0].appendChild(twitterWidgets);
})();
</script>
</xsl:if>
</xsl:template>
<xsl:template name="user.header.navigation">
<xsl:param name="prev"/>
<xsl:param name="next"/>
<xsl:param name="nav.context"/>
<xsl:call-template name="webhelpheader">
<xsl:with-param name="prev" select="$prev"/>
<xsl:with-param name="next" select="$next"/>
<xsl:with-param name="nav.context" select="$nav.context"/>
</xsl:call-template>
<!--xsl:call-template name="webhelptoc"/-->
<!--testing toc in the content page>
<xsl:call-template name="webhelptoctoc"/>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<xsl:call-template name="search"/>
</xsl:if-->
</xsl:template>
<xsl:param name="rackspace.status.pi">
<xsl:call-template name="pi-attribute">
<xsl:with-param name="pis" select="/*/processing-instruction('rax')"/>
<xsl:with-param name="attribute" select="'status.bar.text'"/>
</xsl:call-template>
</xsl:param>
<xsl:param name="rackspace.status.text">
<xsl:if test="/*[contains(translate(@status,&lowercase;,&uppercase;),'DRAFT')]">DRAFT<xsl:text>&#160;-&#160;</xsl:text></xsl:if><xsl:choose>
<xsl:when test="$security = 'internal'">INTERNAL<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'reviewer'">REVIEW<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'writeronly'">WRITERONLY<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'external'"/>
</xsl:choose><xsl:if test="not(normalize-space($rackspace.status.pi) = '')"><xsl:value-of select="normalize-space($rackspace.status.pi)"/> -&#160;</xsl:if>
</xsl:param>
<xsl:template name="user.header.content">
<div class="statustext">
<xsl:choose>
<xsl:when test="not($rackspace.status.text = '')"> <!--TODO: Someday repeat this using javascript -->
<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
</div>
</xsl:template>
<xsl:template name="user.footer.navigation">
<xsl:call-template name="webhelptoc">
<xsl:with-param name="currentid" select="generate-id(.)"/>
</xsl:call-template>
</xsl:template>
<!-- The Header with the company logo -->
<xsl:template name="webhelpheader">
<xsl:param name="prev"/>
<xsl:param name="next"/>
<xsl:param name="nav.context"/>
<xsl:variable name="home" select="/*[1]"/>
<xsl:variable name="up" select="parent::*"/>
<div id="header">
<img style='margin-right: 2px; height: 59px; padding-right: 25px; padding-top: 8px' align="right"
src='../common/images/logo.png' alt="Company Logo"/>
<!-- Display the page title and the main heading(parent) of it-->
<h1 align="center">
<xsl:apply-templates select="." mode="object.title.markup"/>
<br/>
<xsl:choose>
<xsl:when
test="count($up) &gt; 0 and generate-id($up) != generate-id($home)">
<xsl:apply-templates select="$up" mode="object.title.markup"/>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
</h1>
<!-- Prev and Next links generation-->
<div id="navheader" align="right">
<xsl:comment>
<!-- KEEP this code. In case of neither prev nor next links are available, this will help to
keep the integrity of the DOM tree-->
</xsl:comment>
<!--xsl:with-param name="prev" select="$prev"/>
<xsl:with-param name="next" select="$next"/>
<xsl:with-param name="nav.context" select="$nav.context"/-->
<table>
<tr>
<td style="height: 28px; width: 16px;">
<a id="showHideButton" onclick="showHideToc();"
class="pointLeft" title="Hide TOC tree">.
</a>
</td>
<td>
<img src="../common/images/highlight-blue.gif" alt="H" height="25px"
onclick="toggleHighlight()" id="showHideHighlight" style="cursor:pointer">
<xsl:attribute name="title">
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'HighlightButton'"/>
</xsl:call-template>
</xsl:attribute>
</img>
</td>
<xsl:if test="count($prev) &gt; 0
or (count($up) &gt; 0
and generate-id($up) != generate-id($home)
and $navig.showtitles != 0)
or count($next) &gt; 0">
<td>
<xsl:if test="count($prev)>0">
<a accesskey="p">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$prev"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'prev'"/>
</xsl:call-template>
</a>
</xsl:if>
<!-- "Up" link-->
<xsl:choose>
<xsl:when test="count($up)&gt;0
and generate-id($up) != generate-id($home)">
|
<a accesskey="u">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$up"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'up'"/>
</xsl:call-template>
</a>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
<xsl:if test="count($next)>0">
|
<a accesskey="n">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$next"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'next'"/>
</xsl:call-template>
</a>
</xsl:if>
</td>
</xsl:if>
</tr>
</table>
</div>
</div>
</xsl:template>
<xsl:template name="webhelptoc">
<xsl:param name="currentid"/>
<xsl:choose>
<xsl:when test="$rootid != ''">
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="key('id',$rootid)" mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="key('id',$rootid)" mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="key('id',$rootid)"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir">
<xsl:with-param name="object" select="key('id',$rootid)"/>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="/*" mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="/*" mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="/"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir">
<xsl:with-param name="object" select="/"/>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<div>
<div id="leftnavigation" style="padding-top:3px; background-color:white;">
<div id="tabs">
<ul>
<li>
<a href="#treeDiv" tabindex="1">
<em>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'TableofContents'"/>
</xsl:call-template>
</em>
</a>
</li>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<li>
<a href="#searchDiv" tabindex="1">
<em>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'Search'"/>
</xsl:call-template>
</em>
</a>
</li>
</xsl:if>
</ul>
<div id="treeDiv">
<img src="../common/images/loading.gif" alt="loading table of contents..."
id="tocLoading" style="display:block;"/>
<div id="ulTreeDiv" style="display:none">
<ul id="tree" class="filetree">
<xsl:apply-templates select="/*/*" mode="webhelptoc">
<xsl:with-param name="currentid" select="$currentid"/>
</xsl:apply-templates>
</ul>
</div>
</div>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<div id="searchDiv">
<div id="search">
<form onsubmit="Verifie(ditaSearch_Form);return false"
name="ditaSearch_Form"
class="searchForm">
<fieldset class="searchFieldSet">
<legend>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'Search'"/>
</xsl:call-template>
</legend>
<center>
<input id="textToSearch" name="textToSearch" type="text"
class="searchText"/>
<xsl:text disable-output-escaping="yes"> <![CDATA[&nbsp;]]> </xsl:text>
<input onclick="Verifie(ditaSearch_Form)" type="button"
class="searchButton"
value="Go" id="doSearch"/>
</center>
</fieldset>
</form>
</div>
<div id="searchResults">
<center> </center>
</div>
</div>
</xsl:if>
</div>
</div>
</div>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template
match="d:book|d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv|d:index"
mode="webhelptoc">
<xsl:param name="currentid"/>
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="." mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="." mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target"/>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="id" select="generate-id(.)"/>
<!--xsl:message>
<xsl: select="name(ancestor-or-self::*) "/>
</xsl:message-->
<xsl:if test="not(self::d:index) or (self::d:index and not($generate.index = 0))">
<!--li style="white-space: pre; line-height: 0em;"-->
<li tabindex="2">
<xsl:if test="$id = $currentid">
<xsl:attribute name="id">webhelp-currentid</xsl:attribute>
</xsl:if>
<span class="file">
<a href="{substring-after($href,concat($webhelp.base.dir,'/content/'))}">
<xsl:value-of select="$title"/>
</a>
</span>
<xsl:if test="d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv">
<ul>
<xsl:apply-templates
select="d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv"
mode="webhelptoc">
<xsl:with-param name="currentid" select="$currentid"/>
</xsl:apply-templates>
</ul>
</xsl:if>
</li>
</xsl:if>
</xsl:template>
<xsl:template match="text()" mode="webhelptoc"/>
<xsl:template name="user.footer.content">
<script type="text/javascript" src="../common/main.js">
<xsl:comment></xsl:comment>
</script>
</xsl:template>
<xsl:template name="index.html">
<xsl:call-template name="write.chunk">
<xsl:with-param name="filename">
<!-- <xsl:if test="$manifest.in.base.dir != 0"> -->
<!-- <xsl:value-of select="$base.dir"/> -->
<!-- </xsl:if> -->
<xsl:choose>
<xsl:when test="$webhelp.start.filename">
<xsl:value-of select="concat($webhelp.base.dir,'/',$webhelp.start.filename)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="'index.html'"/>
</xsl:otherwise>
</xsl:choose>
</xsl:with-param>
<xsl:with-param name="method" select="'xml'"/>
<xsl:with-param name="encoding" select="'utf-8'"/>
<xsl:with-param name="indent" select="'yes'"/>
<xsl:with-param name="content">
<html>
<head>
<link rel="shortcut icon" href="favicon.ico"/>
<meta http-equiv="Refresh" content="1; URL=content/{$default.topic}"/>
<title><xsl:value-of select="//d:title[1]"/>&#160;</title>
</head>
<body>
If not automatically redirected, click here: <a href="content/{$default.topic}">content/<xsl:value-of select="$default.topic"/></a>
</body>
</html>
</xsl:with-param>
</xsl:call-template>
</xsl:template>
<xsl:include href="revhistory2atom.xsl"/>
</xsl:stylesheet>

View File

@ -0,0 +1,70 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg:svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.0"
width="13.895596"
height="6.3500013"
viewBox="0 0 13.895595 6.3500013"
id="svg2868"
xml:space="preserve"
inkscape:version="0.48.0 r9654"
sodipodi:docname="Arrow_east.svg"><svg:metadata
id="metadata3857"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></svg:metadata><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1131"
inkscape:window-height="740"
id="namedview3855"
showgrid="false"
inkscape:zoom="11.313708"
inkscape:cx="8.6182271"
inkscape:cy="-2.2709277"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="0"
inkscape:current-layer="svg2868"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0" /><svg:defs
id="defs2874" />
<namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
pageopacity="0.0"
pageshadow="2"
window-width="640"
window-height="541"
zoom="0.34493828"
cx="372.04722"
cy="256.66814"
window-x="75"
window-y="152"
current-layer="svg2033">
</namedview>
<svg:g
transform="matrix(-0.01540104,0,0,-0.01741068,13.895596,6.3500014)"
id="Ebene_1">
<svg:polygon
points="902.25049,222.98633 233.17773,222.98633 233.17773,364.71875 0,182.35938 233.17773,0 233.17773,141.73242 902.25049,141.73242 902.25049,222.98633 "
id="path2050" />
</svg:g>
</svg:svg>

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -0,0 +1,60 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="19.21315"
height="18.294994"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.45"
sodipodi:modified="true"
version="1.0">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
gridtolerance="10000"
guidetolerance="10"
objecttolerance="10"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="7.9195959"
inkscape:cx="17.757032"
inkscape:cy="7.298821"
inkscape:document-units="px"
inkscape:current-layer="layer1"
inkscape:window-width="984"
inkscape:window-height="852"
inkscape:window-x="148"
inkscape:window-y="66" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(-192.905,-516.02064)">
<path
style="fill:#000000"
d="M 197.67968,534.31563 C 197.40468,534.31208 196.21788,532.53719 195.04234,530.37143 L 192.905,526.43368 L 193.45901,525.87968 C 193.76371,525.57497 194.58269,525.32567 195.27896,525.32567 L 196.5449,525.32567 L 197.18129,527.33076 L 197.81768,529.33584 L 202.88215,523.79451 C 205.66761,520.74678 208.88522,517.75085 210.03239,517.13691 L 212.11815,516.02064 L 207.90871,520.80282 C 205.59351,523.43302 202.45735,527.55085 200.93947,529.95355 C 199.42159,532.35625 197.95468,534.31919 197.67968,534.31563 z "
id="path2223" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -0,0 +1,37 @@
<p:declare-step version='1.0' name="main"
xmlns:cx="http://xmlcalabash.com/ns/extensions"
xmlns:p="http://www.w3.org/ns/xproc"
xmlns:l="http://xproc.org/library"
xmlns:ex="http://xproc.org/ns/xproc/ex">
<p:input port="source"/>
<p:output port="result"/>
<p:import href="http://xproc.org/library/relax-ng-report.xpl"/>
<p:declare-step type="cx:report-errors">
<p:input port="source" primary="true"/>
<p:input port="report" sequence="true"/>
<p:output port="result"/>
<p:option name="code"/>
<p:option name="code-prefix"/>
<p:option name="code-namespace"/>
</p:declare-step>
<l:relax-ng-report name="validate">
<p:input port="schema">
<p:document href="http://docs-beta.rackspace.com/oxygen/13.1/mac/author/frameworks/rackbook/5.0/rng/rackbook.rng"/>
</p:input>
</l:relax-ng-report>
<cx:report-errors name="report-errors" >
<p:input port="source">
<p:pipe step="validate" port="result"/>
</p:input>
<p:input port="report">
<p:pipe step="validate" port="report"/>
</p:input>
</cx:report-errors>
</p:declare-step>

View File

@ -0,0 +1,117 @@
<?xml version="1.0" encoding="UTF-8"?>
<p:declare-step version="1.0"
xmlns:p="http://www.w3.org/ns/xproc"
name="main">
<p:input port="source" /> <!--sequence="false" primary="true"-->
<p:input port="schema" sequence="true" >
<p:document href="http://docs-beta.rackspace.com/oxygen/13.1/mac/author/frameworks/rackbook/5.0/rng/rackbook.rng"/> <!--http://docs-beta.rackspace.com/oxygen/13.1/mac/author/frameworks/rackbook/5.0/-->
</p:input>
<p:output port="result" primary="true">
<p:pipe step="programlisting-keep-together-xslt" port="result"/>
</p:output>
<p:output port="report" sequence="true">
<p:pipe step="tryvalidation" port="report"/>
</p:output>
<p:serialization port="report" indent="true"/>
<p:try name="tryvalidation">
<p:group>
<p:output port="result">
<p:pipe step="xmlvalidate" port="result"/>
</p:output>
<p:output port="report" sequence="true">
<p:empty/>
</p:output>
<p:validate-with-relax-ng name="xmlvalidate" assert-valid="true">
<p:input port="source">
<p:pipe step="main" port="source"/>
</p:input>
<p:input port="schema">
<p:pipe step="main" port="schema"/>
</p:input>
</p:validate-with-relax-ng>
</p:group>
<p:catch name="catch">
<p:output port="result">
<p:pipe step="main" port="source"/>
</p:output>
<p:output port="report">
<p:pipe step="id" port="result"/>
</p:output>
<p:error name="relaxng-validation-error" code="rax:E001" xmlns:rax="http://docs.rackspace.com/api">
<p:input port="source" >
<p:inline><message>This document is invalid. No docs for you!</message></p:inline>
</p:input>
</p:error>
<p:xslt name="id">
<p:input port="source">
<p:pipe step="catch" port="error"/>
</p:input>
<p:input port="stylesheet">
<p:inline>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0">
<xsl:param name="failonerror">yes</xsl:param>
<xsl:template match="node()|@*">
<xsl:message terminate="{$failonerror}">
<xsl:copy-of select="."/>
</xsl:message>
<xsl:copy>
<xsl:apply-templates select="node() | @*"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
</p:inline>
</p:input>
<p:input port="parameters" sequence="true">
<p:empty/>
</p:input>
</p:xslt>
</p:catch>
</p:try>
<p:xslt name="programlisting-keep-together-xslt">
<p:input port="source">
<p:pipe step="main" port="source"/>
</p:input>
<p:input port="stylesheet">
<p:inline>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:db="http://docbook.org/ns/docbook"
exclude-result-prefixes="xs" version="2.0">
<xsl:template match="node() | @*">
<xsl:copy>
<xsl:apply-templates select="node() | @*"/>
</xsl:copy>
</xsl:template>
<xsl:param name="max">8</xsl:param>
<xsl:template match="db:programlisting">
<xsl:copy>
<xsl:apply-templates select="@*"/>
<xsl:if test="count(tokenize(.,'&#xA;')) &gt; $max">
<xsl:processing-instruction name="dbfo">keep-together="always"</xsl:processing-instruction>
<xsl:comment>linefeeds: <xsl:value-of select="count(tokenize(.,'&#xA;'))"/></xsl:comment>
</xsl:if>
<xsl:apply-templates select="node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
</p:inline>
<!--<p:document href="cloud/code-listing-keep-together.xsl"/>-->
</p:input>
<p:input port="parameters" sequence="true">
<p:empty/>
</p:input>
</p:xslt>
</p:declare-step>

727
webhelp.xsl.real Normal file
View File

@ -0,0 +1,727 @@
<?xml version="1.0"?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY lowercase "'abcdefghijklmnopqrstuvwxyz'">
<!ENTITY uppercase "'ABCDEFGHIJKLMNOPQRSTUVWXYZ'">
]>
<xsl:stylesheet exclude-result-prefixes="d"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:d="http://docbook.org/ns/docbook"
xmlns:exsl="http://exslt.org/common"
xmlns:ng="http://docbook.org/docbook-ng"
xmlns:db="http://docbook.org/ns/docbook"
version="1.0" xmlns="http://www.w3.org/1999/xhtml">
<!-- <xsl:import href="../../xhtml/chunk.xsl"/> -->
<xsl:import href="urn:docbkx:stylesheet-base/xhtml/docbook.xsl" />
<xsl:output
method="html"
encoding="utf-8"
cdata-section-elements=""/>
<xsl:param name="meta.robots"/>
<xsl:param name="meta.robots.calculated">
<xsl:choose>
<xsl:when test="$meta.robots = '1'">NOINDEX, NOFOLLOW</xsl:when>
<xsl:when test="$meta.robots = '0' or $meta.robots = ''"/>
<xsl:otherwise><xsl:value-of select="$meta.robots"/></xsl:otherwise>
</xsl:choose>
</xsl:param>
<xsl:variable name="default.topic">
<xsl:choose>
<xsl:when test="$webhelp.default.topic != ''">
<xsl:value-of select="$webhelp.default.topic"/>
</xsl:when>
<xsl:when test="$htmlhelp.default.topic != ''">
<xsl:value-of select="$htmlhelp.default.topic"/>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="make-relative-filename">
<xsl:with-param name="base.dir"/>
<xsl:with-param name="base.name">
<xsl:choose>
<xsl:when test="$rootid != ''">
<xsl:apply-templates select="key('id',$rootid)" mode="chunk-filename"/>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates
select="*/*[self::d:preface|self::d:glossary|self::d:chapter|self::d:appendix|self::d:part|self::d:section][1]"
mode="chunk-filename"/>
</xsl:otherwise>
</xsl:choose>
</xsl:with-param>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<!-- webhelp-specific params! -->
<!-- To be added to normal params file someday -->
<xsl:param name="webhelp.include.search.tab">true</xsl:param>
<xsl:param name="webhelp.start.filename">index.html</xsl:param>
<xsl:param name="webhelp.base.dir">docs</xsl:param>
<xsl:param name="webhelp.tree.cookie.id" select="concat( 'treeview-', count(//node()) )"/>
<xsl:param name="webhelp.indexer.language">en</xsl:param>
<xsl:param name="webhelp.default.topic"/>
<xsl:param name="webhelp.autolabel">0</xsl:param>
<!-- webhelp-specific params! -->
<!-- Set some reasonable defaults for webhelp output -->
<xsl:param name="chunker.output.indent">no</xsl:param>
<xsl:param name="navig.showtitles">0</xsl:param>
<xsl:param name="manifest.in.base.dir" select="0"/>
<xsl:param name="base.dir" select="concat($webhelp.base.dir,'/content/')"/>
<xsl:param name="suppress.navigation">0</xsl:param>
<xsl:param name="generate.index" select="1"/>
<xsl:param name="inherit.keywords" select="'0'"/>
<xsl:param name="local.l10n.xml" select="document('')"/>
<xsl:param name="para.propagates.style" select="1"/>
<xsl:param name="phrase.propagates.style" select="1"/>
<xsl:param name="chunk.first.sections" select="1"/>
<xsl:param name="chunk.section.depth" select="100"/>
<xsl:param name="chapter.autolabel" select="1"/>
<xsl:param name="section.autolabel" select="0"/>
<xsl:param name="generate.section.toc.level" select="5"/>
<i18n xmlns="http://docbook.sourceforge.net/xmlns/l10n/1.0">
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="en">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="TableofContents" text="Contents"/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<!-- The fallback mechansim doesn't seem to work for local l10n stuff -->
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="ja">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="de">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="fr">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
<l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="zh">
<l:gentext key="Search" text="Search"/>
<l:gentext key="Enter_a_term_and_click" text="Enter a term and click "/>
<l:gentext key="Go" text="Go"/>
<l:gentext key="to_perform_a_search" text=" to perform a search."/>
<l:gentext key="txt_filesfound" text="Results"/>
<l:gentext key="txt_enter_at_least_1_char" text="You must enter at least one character."/>
<l:gentext key="txt_browser_not_supported"
text="Your browser is not supported. Use of Mozilla Firefox is recommended."/>
<l:gentext key="txt_please_wait" text="Please wait. Search in progress..."/>
<l:gentext key="txt_results_for" text="Results for: "/>
<l:gentext key="HighlightButton" text="Toggle search result highlighting"/>
</l10n>
</i18n>
<xsl:template name="system.head.content">
<xsl:param name="node" select="."/>
<xsl:text>
</xsl:text>
<!--
This avoids two problems in IE 8. We should someday figure out why this is happening and tweak the JavaScript so this <meta/> tag is not necessary:
1. When you perform a search and click the Toggle Highlight button, IE 8 adds a line break before the highlighted word.
2. If you click the show/hide toc button, the tab crashes.
These problems go away when you add this IE=7 mode meta tag.
-->
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<xsl:text>
</xsl:text>
</xsl:template>
<xsl:template name="user.head.content">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<!-- <xsl:message>
webhelp.tree.cookie.id = <xsl:value-of select="$webhelp.tree.cookie.id"/> +++ <xsl:value-of select="count(//node())"/>
$webhelp.indexer.language = <xsl:value-of select="$webhelp.indexer.language"/> +++ <xsl:value-of select="count(//node())"/>
</xsl:message>-->
<xsl:if test="$meta.robots.calculated != ''">
<meta name="robots" content="{$meta.robots.calculated}"/>
</xsl:if>
<script type="text/javascript">
//The id for tree cookie
var treeCookieId = "<xsl:value-of select="$webhelp.tree.cookie.id"/>";
var language = "<xsl:value-of select="$webhelp.indexer.language"/>";
var w = new Object();
//Localization
txt_filesfound = '<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_filesfound'"/>
</xsl:call-template>';
txt_enter_at_least_1_char = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_enter_at_least_1_char'"/>
</xsl:call-template>";
txt_browser_not_supported = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_browser_not_supported'"/>
</xsl:call-template>";
txt_please_wait = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_please_wait'"/>
</xsl:call-template>";
txt_results_for = "<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'txt_results_for'"/>
</xsl:call-template>";
</script>
<style type="text/css">
input {
margin-bottom: 5px;
margin-top: 2px;
}
.folder {
display: block;
height: 22px;
padding-left: 20px;
background: transparent url(../common/jquery/treeview/images/folder.gif) 0 0px no-repeat;
}
<!--[if IE]>
input {
margin-bottom: 5px;
margin-top: 2px;
}
<![endif]-->
</style>
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon"/>
<link rel="stylesheet" type="text/css" href="../common/css/positioning.css"/>
<link rel="stylesheet" type="text/css" href="../common/css/custom.css"/>
<xsl:if test="//d:revhistory/d:revision and $canonical.url.base != ''">
<link href="../atom.xml" type="application/atom+xml" rel="alternate" title="Document ATOM Feed" />
</xsl:if>
<xsl:if test="$canonical.url.base != ''">
<link rel="canonical" >
<xsl:attribute name="href"><xsl:value-of select="$canonical.url.base"/>/<xsl:apply-templates select="." mode="chunk-filename"/></xsl:attribute>
</link>
</xsl:if>
<xsl:comment><xsl:text>[if IE]>
&lt;link rel="stylesheet" type="text/css" href="../common/css/ie.css"/>
&lt;![endif]</xsl:text></xsl:comment>
<link rel="stylesheet" type="text/css" href="../common/jquery/theme-redmond/jquery-ui-1.8.2.custom.css"/>
<link rel="stylesheet" type="text/css" href="../common/jquery/treeview/jquery.treeview.css"/>
<script type="text/javascript" src="../common/jquery/jquery-1.4.3.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery-ui-1.8.2.custom.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery.cookie.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/treeview/jquery.treeview.min.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="../common/jquery/jquery.qtip-1.0.0-rc3/jquery.qtip-1.0.0-rc3.min.js">
<xsl:comment>jQuery plugin for glossary popups. </xsl:comment>
</script>
<!--Scripts/css stylesheets for Search-->
<script type="text/javascript" src="search/htmlFileList.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/htmlFileInfoList.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/nwSearchFnt.js">
<xsl:comment> </xsl:comment>
</script>
<!--script type="text/javascript" src="search/addition.js">
<xsl:comment></xsl:comment>
</script>
<script type="text/javascript" src="search/indexLoader.js">
<xsl:comment></xsl:comment>
</script-->
<!--
NOTE: Stemmer javascript files should be in format <language>_stemmer.js.
For example, for English(en), source should be: "search/stemmers/en_stemmer.js"
For country codes, see: http://www.uspto.gov/patft/help/helpctry.htm
-->
<!--<xsl:message><xsl:value-of select="concat('search/stemmers/',$webhelp.indexer.language,'_stemmer.js')"/></xsl:message>-->
<script type="text/javascript" src="{concat('search/stemmers/',$webhelp.indexer.language,'_stemmer.js')}">
<xsl:comment>//make this scalable to other languages as well.</xsl:comment>
</script>
<!--Index Files:
Index is broken in to three equal sized(number of index items) files. This is to help parallel downloading
of files to make it faster.-->
<script type="text/javascript" src="search/index-1.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/index-2.js">
<xsl:comment> </xsl:comment>
</script>
<script type="text/javascript" src="search/index-3.js">
<xsl:comment> </xsl:comment>
</script>
<!--End of index files -->
<xsl:if test="$enable.google.analytics = '1' and not($google.analytics.id = '')">
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', '<xsl:value-of select="$google.analytics.id"/>']);
</script>
<script type="text/javascript" src="../common/ga.js">
<xsl:comment></xsl:comment>
</script>
<!-- Google Analytics Social Button Tracking -->
<script type="text/javascript" src="http://www.tabpress.com/_js/ga_social_tracking.js">
<xsl:comment></xsl:comment>
</script>
<!-- Load Twitter JS-API asynchronously -->
<script>
(function(){var twitterWidgets = document.createElement('script');
twitterWidgets.type = 'text/javascript';
twitterWidgets.async = true;
twitterWidgets.src = 'http://platform.twitter.com/widgets.js';
// Setup a callback to track once the script loads.
twitterWidgets.onload = _ga.trackTwitter;
document.getElementsByTagName('head')[0].appendChild(twitterWidgets);
})();
</script>
</xsl:if>
</xsl:template>
<xsl:template name="user.header.navigation">
<xsl:param name="prev"/>
<xsl:param name="next"/>
<xsl:param name="nav.context"/>
<xsl:call-template name="webhelpheader">
<xsl:with-param name="prev" select="$prev"/>
<xsl:with-param name="next" select="$next"/>
<xsl:with-param name="nav.context" select="$nav.context"/>
</xsl:call-template>
<!--xsl:call-template name="webhelptoc"/-->
<!--testing toc in the content page>
<xsl:call-template name="webhelptoctoc"/>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<xsl:call-template name="search"/>
</xsl:if-->
</xsl:template>
<xsl:param name="rackspace.status.pi">
<xsl:call-template name="pi-attribute">
<xsl:with-param name="pis" select="/*/processing-instruction('rax')"/>
<xsl:with-param name="attribute" select="'status.bar.text'"/>
</xsl:call-template>
</xsl:param>
<xsl:param name="rackspace.status.text">
<xsl:if test="/*[contains(translate(@status,&lowercase;,&uppercase;),'DRAFT')]">DRAFT<xsl:text>&#160;-&#160;</xsl:text></xsl:if><xsl:choose>
<xsl:when test="$security = 'internal'">INTERNAL<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'reviewer'">REVIEW<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'writeronly'">WRITERONLY<xsl:text> -&#160;</xsl:text></xsl:when>
<xsl:when test="$security = 'external'"/>
</xsl:choose><xsl:if test="not(normalize-space($rackspace.status.pi) = '')"><xsl:value-of select="normalize-space($rackspace.status.pi)"/> -&#160;</xsl:if>
</xsl:param>
<xsl:template name="user.header.content">
<div class="statustext">
<xsl:choose>
<xsl:when test="not($rackspace.status.text = '')"> <!--TODO: Someday repeat this using javascript -->
<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>&#160;<xsl:value-of select="$rackspace.status.text"/>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
</div>
</xsl:template>
<xsl:template name="user.footer.navigation">
<xsl:call-template name="webhelptoc">
<xsl:with-param name="currentid" select="generate-id(.)"/>
</xsl:call-template>
</xsl:template>
<!-- The Header with the company logo -->
<xsl:template name="webhelpheader">
<xsl:param name="prev"/>
<xsl:param name="next"/>
<xsl:param name="nav.context"/>
<xsl:variable name="home" select="/*[1]"/>
<xsl:variable name="up" select="parent::*"/>
<div id="header">
<img style='margin-right: 2px; height: 59px; padding-right: 25px; padding-top: 8px' align="right"
src='../common/images/logo.png' alt="Company Logo"/>
<!-- Display the page title and the main heading(parent) of it-->
<h1 align="center">
<xsl:apply-templates select="." mode="object.title.markup"/>
<br/>
<xsl:choose>
<xsl:when
test="count($up) &gt; 0 and generate-id($up) != generate-id($home)">
<xsl:apply-templates select="$up" mode="object.title.markup"/>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
</h1>
<!-- Prev and Next links generation-->
<div id="navheader" align="right">
<xsl:comment>
<!-- KEEP this code. In case of neither prev nor next links are available, this will help to
keep the integrity of the DOM tree-->
</xsl:comment>
<!--xsl:with-param name="prev" select="$prev"/>
<xsl:with-param name="next" select="$next"/>
<xsl:with-param name="nav.context" select="$nav.context"/-->
<table>
<tr>
<td style="height: 28px; width: 16px;">
<a id="showHideButton" onclick="showHideToc();"
class="pointLeft" title="Hide TOC tree">.
</a>
</td>
<td>
<img src="../common/images/highlight-blue.gif" alt="H" height="25px"
onclick="toggleHighlight()" id="showHideHighlight" style="cursor:pointer">
<xsl:attribute name="title">
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'HighlightButton'"/>
</xsl:call-template>
</xsl:attribute>
</img>
</td>
<xsl:if test="count($prev) &gt; 0
or (count($up) &gt; 0
and generate-id($up) != generate-id($home)
and $navig.showtitles != 0)
or count($next) &gt; 0">
<td>
<xsl:if test="count($prev)>0">
<a accesskey="p">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$prev"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'prev'"/>
</xsl:call-template>
</a>
</xsl:if>
<!-- "Up" link-->
<xsl:choose>
<xsl:when test="count($up)&gt;0
and generate-id($up) != generate-id($home)">
|
<a accesskey="u">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$up"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'up'"/>
</xsl:call-template>
</a>
</xsl:when>
<xsl:otherwise>&#160;</xsl:otherwise>
</xsl:choose>
<xsl:if test="count($next)>0">
|
<a accesskey="n">
<xsl:attribute name="href">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="$next"/>
</xsl:call-template>
</xsl:attribute>
<xsl:call-template name="navig.content">
<xsl:with-param name="direction" select="'next'"/>
</xsl:call-template>
</a>
</xsl:if>
</td>
</xsl:if>
</tr>
</table>
</div>
</div>
</xsl:template>
<xsl:template name="webhelptoc">
<xsl:param name="currentid"/>
<xsl:choose>
<xsl:when test="$rootid != ''">
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="key('id',$rootid)" mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="key('id',$rootid)" mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="key('id',$rootid)"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir">
<xsl:with-param name="object" select="key('id',$rootid)"/>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="/*" mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="/*" mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target">
<xsl:with-param name="object" select="/"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir">
<xsl:with-param name="object" select="/"/>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<div>
<div id="leftnavigation" style="padding-top:3px; background-color:white;">
<div id="tabs">
<ul>
<li>
<a href="#treeDiv" tabindex="1">
<em>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'TableofContents'"/>
</xsl:call-template>
</em>
</a>
</li>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<li>
<a href="#searchDiv" tabindex="1">
<em>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'Search'"/>
</xsl:call-template>
</em>
</a>
</li>
</xsl:if>
</ul>
<div id="treeDiv">
<img src="../common/images/loading.gif" alt="loading table of contents..."
id="tocLoading" style="display:block;"/>
<div id="ulTreeDiv" style="display:none">
<ul id="tree" class="filetree">
<xsl:apply-templates select="/*/*" mode="webhelptoc">
<xsl:with-param name="currentid" select="$currentid"/>
</xsl:apply-templates>
</ul>
</div>
</div>
<xsl:if test="$webhelp.include.search.tab != 'false'">
<div id="searchDiv">
<div id="search">
<form onsubmit="Verifie(ditaSearch_Form);return false"
name="ditaSearch_Form"
class="searchForm">
<fieldset class="searchFieldSet">
<legend>
<xsl:call-template name="gentext">
<xsl:with-param name="key" select="'Search'"/>
</xsl:call-template>
</legend>
<center>
<input id="textToSearch" name="textToSearch" type="text"
class="searchText"/>
<xsl:text disable-output-escaping="yes"> <![CDATA[&nbsp;]]> </xsl:text>
<input onclick="Verifie(ditaSearch_Form)" type="button"
class="searchButton"
value="Go" id="doSearch"/>
</center>
</fieldset>
</form>
</div>
<div id="searchResults">
<center> </center>
</div>
</div>
</xsl:if>
</div>
</div>
</div>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template
match="d:book|d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv|d:index"
mode="webhelptoc">
<xsl:param name="currentid"/>
<xsl:variable name="title">
<xsl:if test="$webhelp.autolabel=1">
<xsl:variable name="label.markup">
<xsl:apply-templates select="." mode="label.markup"/>
</xsl:variable>
<xsl:if test="normalize-space($label.markup)">
<xsl:value-of select="concat($label.markup,$autotoc.label.separator)"/>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="." mode="title.markup"/>
</xsl:variable>
<xsl:variable name="href">
<xsl:choose>
<xsl:when test="$manifest.in.base.dir != 0">
<xsl:call-template name="href.target"/>
</xsl:when>
<xsl:otherwise>
<xsl:call-template name="href.target.with.base.dir"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="id" select="generate-id(.)"/>
<!--xsl:message>
<xsl: select="name(ancestor-or-self::*) "/>
</xsl:message-->
<xsl:if test="not(self::d:index) or (self::d:index and not($generate.index = 0))">
<!--li style="white-space: pre; line-height: 0em;"-->
<li tabindex="2">
<xsl:if test="$id = $currentid">
<xsl:attribute name="id">webhelp-currentid</xsl:attribute>
</xsl:if>
<span class="file">
<a href="{substring-after($href,concat($webhelp.base.dir,'/content/'))}">
<xsl:value-of select="$title"/>
</a>
</span>
<xsl:if test="d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv">
<ul>
<xsl:apply-templates
select="d:part|d:reference|d:preface|d:chapter|d:bibliography|d:appendix|d:article|d:glossary|d:section|d:simplesect|d:sect1|d:sect2|d:sect3|d:sect4|d:sect5|d:refentry|d:colophon|d:bibliodiv"
mode="webhelptoc">
<xsl:with-param name="currentid" select="$currentid"/>
</xsl:apply-templates>
</ul>
</xsl:if>
</li>
</xsl:if>
</xsl:template>
<xsl:template match="text()" mode="webhelptoc"/>
<xsl:template name="user.footer.content">
<script type="text/javascript" src="../common/main.js">
<xsl:comment></xsl:comment>
</script>
</xsl:template>
<xsl:template name="index.html">
<xsl:call-template name="write.chunk">
<xsl:with-param name="filename">
<!-- <xsl:if test="$manifest.in.base.dir != 0"> -->
<!-- <xsl:value-of select="$base.dir"/> -->
<!-- </xsl:if> -->
<xsl:choose>
<xsl:when test="$webhelp.start.filename">
<xsl:value-of select="concat($webhelp.base.dir,'/',$webhelp.start.filename)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="'index.html'"/>
</xsl:otherwise>
</xsl:choose>
</xsl:with-param>
<xsl:with-param name="method" select="'xml'"/>
<xsl:with-param name="encoding" select="'utf-8'"/>
<xsl:with-param name="indent" select="'yes'"/>
<xsl:with-param name="content">
<html>
<head>
<link rel="shortcut icon" href="favicon.ico"/>
<meta http-equiv="Refresh" content="1; URL=content/{$default.topic}"/>
<title><xsl:value-of select="//d:title[1]"/>&#160;</title>
</head>
<body>
If not automatically redirected, click here: <a href="content/{$default.topic}">content/<xsl:value-of select="$default.topic"/></a>
</body>
</html>
</xsl:with-param>
</xsl:call-template>
</xsl:template>
<xsl:include href="revhistory2atom.xsl"/>
</xsl:stylesheet>