1 <?xml version="1.0" encoding="UTF-8"?>
3 ~ Licensed to the Apache Software Foundation (ASF) under one
4 ~ or more contributor license agreements. See the NOTICE file
5 ~ distributed with this work for additional information
6 ~ regarding copyright ownership. The ASF licenses this file
7 ~ to you under the Apache License, Version 2.0 (the
8 ~ "License"); you may not use this file except in compliance
9 ~ with the License. You may obtain a copy of the License at
11 ~ http://www.apache.org/licenses/LICENSE-2.0
13 ~ Unless required by applicable law or agreed to in writing,
14 ~ software distributed under the License is distributed on an
15 ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 ~ KIND, either express or implied. See the License for the
17 ~ specific language governing permissions and limitations
22 version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
23 xmlns:plexus="org.apache.maven.archiva.common.spring.CamelCaseXpathFunction">
25 use xalan extension mecanism to call static methods
26 @see http://www.ibm.com/developerworks/library/x-xalanextensions.html
29 <xsl:output method="xml" indent="yes"
30 doctype-public="-//SPRING//DTD BEAN 2.0//EN"
31 doctype-system="http://www.springframework.org/dtd/spring-beans-2.0.dtd" />
33 <xsl:template match="/component-set">
35 <xsl:for-each select="components/component">
38 <xsl:when test="role-hint">
39 <xsl:attribute name="id">
40 <xsl:value-of select="concat( role, '#', role-hint )" />
44 <xsl:attribute name="id">
45 <xsl:value-of select="role" />
49 <xsl:attribute name="class">
50 <xsl:value-of select="implementation" />
52 <xsl:if test="instanciation-strategy/text() = 'per-lookup'">
53 <xsl:attribute name="scope">prototype</xsl:attribute>
55 <xsl:for-each select="requirements/requirement">
57 <xsl:attribute name="name">
58 <xsl:value-of select="field-name" />
61 <xsl:when test="role-hint">
62 <xsl:attribute name="ref">
63 <xsl:value-of select="concat( role, '#', role-hint )" />
67 <xsl:attribute name="ref">
68 <xsl:value-of select="role" />
74 <xsl:for-each select="configuration/*">
76 <xsl:attribute name="name">
77 <xsl:value-of select="plexus:toCamelCase( name(.) )" />
79 <xsl:attribute name="value">
80 <xsl:value-of select="." />