forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bd...@apache.org
Subject svn commit: r1096394 [2/5] - in /forrest/trunk: ./ whiteboard/forrest-osgi/ whiteboard/forrest-osgi/bin/ whiteboard/forrest-osgi/conf/ whiteboard/forrest-osgi/docs/ whiteboard/forrest-osgi/docs/src/ whiteboard/forrest-osgi/docs/src/documentation/ white...
Date Mon, 25 Apr 2011 01:38:10 GMT
Added: forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/resources/schema/symbols-project-v10.ent
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/resources/schema/symbols-project-v10.ent?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/resources/schema/symbols-project-v10.ent (added)
+++ forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/resources/schema/symbols-project-v10.ent Mon Apr 25 01:38:03 2011
@@ -0,0 +1,26 @@
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+
+<!-- Typical invocation:
+  <!ENTITY % symbols-project
+      PUBLIC "-//Apache Forrest//ENTITIES Symbols Project v1.0//EN"
+      "symbols-project-v10.ent">
+  %symbols-project;
+-->
+<!ENTITY myp "My Project Name">
+<!ENTITY myp-s "<strong>My Project Name</strong>">
+<!ENTITY myp-t "My Project Name&trade;">

Added: forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/sitemap.xmap
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/sitemap.xmap?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/sitemap.xmap (added)
+++ forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/sitemap.xmap Mon Apr 25 01:38:03 2011
@@ -0,0 +1,66 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
+  <map:components>
+    <map:actions>
+      <map:action logger="sitemap.action.sourcetype" name="sourcetype" src="org.apache.forrest.sourcetype.SourceTypeAction">
+        <sourcetype name="hello-v1.0">
+          <document-declaration public-id="-//Acme//DTD Hello Document V1.0//EN" />
+        </sourcetype>
+      </map:action>
+    </map:actions>
+    <map:selectors default="parameter">
+      <map:selector logger="sitemap.selector.parameter" name="parameter" src="org.apache.cocoon.selection.ParameterSelector" />
+    </map:selectors>
+  </map:components>
+  <map:resources>
+    <map:resource name="transform-to-document">
+      <map:act type="sourcetype" src="{src}">
+        <map:select type="parameter">
+          <map:parameter name="parameter-selector-test" value="{sourcetype}" />
+          <map:when test="hello-v1.0">
+            <map:generate src="{properties:content.xdocs}{../../1}.xml" />
+            <map:transform src="{properties:resources.stylesheets}/hello2document.xsl" />
+            <map:serialize type="xml-document"/>
+          </map:when>
+        </map:select>
+      </map:act>
+    </map:resource>
+  </map:resources>
+  <map:pipelines>
+    <map:pipeline>
+      <map:match pattern="old_site/*.html">
+        <map:select type="exists">
+          <map:when test="{properties:content}{1}.html">
+            <map:read src="{properties:content}{1}.html" mime-type="text/html"/>
+<!--
+          Use this instead if you want JTidy to clean up your HTML
+          <map:generate type="html" src="{properties:content}/{0}" />
+          <map:serialize type="html"/>
+        -->
+          </map:when>
+        </map:select>
+      </map:match>
+      <map:match pattern="**.xml">
+        <map:call resource="transform-to-document">
+          <map:parameter name="src" value="{properties:content.xdocs}{1}.xml" />
+        </map:call>
+      </map:match>
+    </map:pipeline>
+  </map:pipelines>
+</map:sitemap>

Added: forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/skinconf.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/skinconf.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/skinconf.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/docs/src/documentation/skinconf.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,438 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<!--
+Skin configuration file. This file contains details of your project,
+which will be used to configure the chosen Forrest skin.
+-->
+<!DOCTYPE skinconfig PUBLIC "-//APACHE//DTD Skin Configuration V0.8-2//EN" "http://forrest.apache.org/dtd/skinconfig-v08-2.dtd">
+<skinconfig>
+<!-- To enable lucene search add provider="lucene" (default is google).
+    Add box-location="alt" to move the search box to an alternate location
+    (if the skin supports it) and box-location="all" to show it in all
+    available locations on the page.  Remove the <search> element to show
+    no search box. @domain will enable sitesearch for the specific domain with google.
+    In other words google will search the @domain for the query string.
+  -->
+  <search name="MyProject" domain="example.org" provider="google"/>
+<!-- Disable the print link? If enabled, invalid HTML 4.0.1 -->
+  <disable-print-link>true</disable-print-link>
+<!-- Disable the PDF link? -->
+  <disable-pdf-link>true</disable-pdf-link>
+<!-- Disable the POD link? -->
+  <disable-pod-link>true</disable-pod-link>
+<!-- Disable the Text link? FIXME: NOT YET IMPLEMENETED. -->
+  <disable-txt-link>true</disable-txt-link>
+<!-- Disable the xml source link? -->
+<!-- The xml source link makes it possible to access the xml rendition
+    of the source frim the html page, and to have it generated statically.
+    This can be used to enable other sites and services to reuse the
+    xml format for their uses. Keep this disabled if you don't want other
+    sites to easily reuse your pages.-->
+  <disable-xml-link>true</disable-xml-link>
+<!-- Disable navigation icons on all external links? -->
+  <disable-external-link-image>true</disable-external-link-image>
+<!-- Disable w3c compliance links? 
+    Use e.g. align="center" to move the compliance links logos to 
+    an alternate location default is left.
+    (if the skin supports it) -->
+  <disable-compliance-links>false</disable-compliance-links>
+<!-- Render mailto: links unrecognisable by spam harvesters? -->
+  <obfuscate-mail-links>true</obfuscate-mail-links>
+  <obfuscate-mail-value>.at.</obfuscate-mail-value>
+<!-- Disable the javascript facility to change the font size -->
+  <disable-font-script>true</disable-font-script>
+<!-- mandatory project logo
+       default skin: renders it at the top -->
+  <project-name>MyProject</project-name>
+  <project-description>MyProject Description</project-description>
+  <project-url>http://example.org/myproj/</project-url>
+  <project-logo>images/project.png</project-logo>
+<!-- Alternative static image:
+  <project-logo>images/project-logo.gif</project-logo> -->
+<!-- optional group logo
+       default skin: renders it at the top-left corner -->
+  <group-name>MyGroup</group-name>
+  <group-description>MyGroup Description</group-description>
+  <group-url>http://example.org</group-url>
+  <group-logo>images/group.png</group-logo>
+<!-- Alternative static image:
+  <group-logo>images/group-logo.gif</group-logo> -->
+<!-- optional host logo (e.g. sourceforge logo)
+       default skin: renders it at the bottom-left corner -->
+  <host-url></host-url>
+  <host-logo></host-logo>
+<!-- relative url of a favicon file, normally favicon.ico -->
+  <favicon-url></favicon-url>
+<!-- The following are used to construct a copyright statement -->
+  <disable-copyright-footer>false</disable-copyright-footer>
+<!-- @inception enable automatic generation of a date-range to current date -->
+  <year inception="true">2005</year>
+  <vendor>The Example Organisation.</vendor>
+<!-- The optional copyright-link URL will be used as a link in the
+    copyright statement -->
+  <copyright-link>http://www.example.org/</copyright-link>
+<!-- Optional text trademark statement below the copyright statement -->
+<!--
+  <trademark-statement>
+    Apache Forrest, Forrest, Apache, the Apache feather logo, and the Apache Forrest
+    logos are trademarks of The Apache Software Foundation.
+  </trademark-statement>
+-->
+<!-- Some skins use this to form a 'breadcrumb trail' of links.
+    Use location="alt" to move the trail to an alternate location
+    (if the skin supports it).
+    Omit the location attribute to display the trail in the default location.
+    Use location="none" to not display the trail (if the skin supports it).
+    For some skins just set the attributes to blank.
+    
+    NOTE: If a breadcrumb entry points at a local file the href must
+    be complete, that is it must point to the file itself, not to a 
+    directory.
+  -->
+  <trail>
+    <link1 name="myGroup" href="http://www.apache.org/"/>
+    <link2 name="myProject" href="http://forrest.apache.org/"/>
+    <link3 name="" href=""/>
+  </trail>
+<!-- Configure the TOC, i.e. the Table of Contents.
+  @max-depth
+   how many "section" levels need to be included in the
+   generated Table of Contents (TOC). 
+  @min-sections
+   Minimum required to create a TOC.
+  @location ("page","menu","page,menu", "none")
+   Where to show the TOC.
+  -->
+  <toc max-depth="2" min-sections="1" location="page"/>
+<!-- Heading types can be clean|underlined|boxed  -->
+  <headings type="boxed"/>
+<!-- The optional feedback element will be used to construct a
+    feedback link in the footer with the page pathname appended:
+    <a href="@href">{@to}</a>
+    -->
+  <feedback to="webmaster@example.org"
+    href="mailto:webmaster@example.org?subject=Feedback&#160;" >
+    Send feedback about the website to:
+  </feedback>
+<!-- Optional message of the day (MOTD).
+    Note: This is only implemented in the pelt skin.
+    Note: Beware issue FOR-677 if you use an absolute path uri.
+    If the optional <motd> element is used, then messages will be appended
+    depending on the URI string pattern.
+    motd-option : Each option will match a pattern and apply its text.
+      The "pattern" attribute specifies the pattern to be matched.
+      This can be a specific page, or a general pattern to match a set of pages,
+      e.g. everything in the "samples" directory.
+      The @starts-with=true anchors the string to the start, otherwise contains 
+    motd-title : This text will be added in brackets after the <html><title>
+      and this can be empty.
+    motd-page : This text will be added in a panel on the face of the page,
+      with the "motd-page-url" being the hyperlink "More".
+    Values for the "location" attribute are:
+      page : on the face of the page, e.g. in the spare space of the toc
+      alt : at the bottom of the left-hand navigation panel
+      both : both
+    -->
+<!--
+  <motd>
+    <motd-option pattern="samples/sample.html">
+      <motd-title>sample</motd-title>
+      <motd-page location="both">
+        This is an example of a Message of the day (MOTD).
+      </motd-page>
+      <motd-page-url>faq.html</motd-page-url>
+    </motd-option>
+    <motd-option pattern="samples/faq.html">
+      <motd-page location="page">
+        How to enable this MOTD is on this page.
+      </motd-page>
+      <motd-page-url>http://forrest.apache.org/docs/faq.html</motd-page-url>
+    </motd-option>
+  </motd>
+-->
+<!--
+    extra-css - here you can define custom css-elements that are 
+    A) overriding the fallback elements or 
+    B) adding the css definition from new elements that you may have 
+       used in your documentation.
+    -->
+  <extra-css>
+<!--Example of reason B:
+        To define the css definition of a new element that you may have used
+        in the class attribute of a <p> node. 
+        e.g. <p class="quote"/>
+    -->
+    p.quote {
+      margin-left: 2em;
+      padding: .5em;
+      background-color: #f0f0f0;
+      font-family: monospace;
+    }
+    <!--Example:
+        To override the colours of links only in the footer.
+    -->
+    #footer a { color: #0F3660; }
+    #footer a:visited { color: #009999; }
+  </extra-css>
+  <colors>
+<!-- These values are used for the generated CSS files.
+    They essentially "override" the default colors defined in the chosen skin.
+    There are four duplicate "groups" of colors below, denoted by comments:
+      Color group: Forrest, Krysalis, Collabnet, and Lenya using Pelt.
+    They are provided for example only. To customize the colors of any skin,
+    uncomment one of these groups of color elements and change the values
+    of the particular color elements that you wish to change.
+    Note that by default, all color groups are commented-out which means that
+    the default colors provided by the skin are being used.
+  -->
+<!-- Color group: Forrest: example colors similar to forrest.apache.org
+    Some of the element names are obscure, so comments are added to show how
+    the "pelt" skin uses them, other skins might use these elements in a different way.
+    Tip: temporarily change the value of an element to red (#ff0000) and see the effect.
+     pelt: breadtrail: the strip at the top of the page and the second strip under the tabs
+     pelt: header: top strip containing project and group logos
+     pelt: heading|subheading: section headings within the content
+     pelt: navstrip: the strip under the tabs which contains the published date
+     pelt: menu: the left-hand navigation panel
+     pelt: toolbox: the selected menu item
+     pelt: searchbox: the background of the searchbox
+     pelt: border: line border around selected menu item
+     pelt: body: any remaining parts, e.g. the bottom of the page
+     pelt: footer: the second from bottom strip containing credit logos and published date
+     pelt: feedback: the optional bottom strip containing feedback link
+  -->
+<!--
+    <color name="breadtrail" value="#cedfef" font="#0F3660" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="header" value="#294563"/>
+    <color name="tab-selected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="tab-unselected" value="#b5c7e7" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="subtab-selected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="subtab-unselected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="heading" value="#294563"/>
+    <color name="subheading" value="#4a6d8c"/>
+    <color name="published" value="#4C6C8F" font="#FFFFFF"/>
+    <color name="feedback" value="#4C6C8F" font="#FFFFFF" align="center"/>
+    <color name="navstrip" value="#4a6d8c" font="#ffffff" link="#0F3660" vlink="#0F3660" hlink="#000066"/>
+    <color name="menu" value="#4a6d8c" font="#cedfef" link="#ffffff" vlink="#ffffff" hlink="#ffcf00"/>    
+    <color name="toolbox" value="#4a6d8c"/>
+    <color name="border" value="#294563"/>
+    <color name="dialog" value="#4a6d8c"/>
+    <color name="searchbox" value="#4a6d8c" font="#000000"/>
+    <color name="body" value="#ffffff" link="#0F3660" vlink="#009999" hlink="#000066"/>
+    <color name="table" value="#7099C5"/>    
+    <color name="table-cell" value="#f0f0ff"/>    
+    <color name="highlight" value="#ffff00"/>
+    <color name="fixme" value="#cc6600"/>
+    <color name="note" value="#006699"/>
+    <color name="warning" value="#990000"/>
+    <color name="code" value="#CFDCED"/>
+    <color name="footer" value="#cedfef"/>
+-->
+<!-- Color group: Krysalis -->
+<!--
+    <color name="header"    value="#FFFFFF"/>
+
+    <color name="tab-selected" value="#a5b6c6" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="tab-unselected" value="#F7F7F7"  link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="subtab-selected" value="#a5b6c6"  link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="subtab-unselected" value="#a5b6c6"  link="#000000" vlink="#000000" hlink="#000000"/>
+
+    <color name="heading" value="#a5b6c6"/>
+    <color name="subheading" value="#CFDCED"/>
+        
+    <color name="navstrip" value="#CFDCED" font="#000000" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="toolbox" value="#a5b6c6"/>
+    <color name="border" value="#a5b6c6"/>
+        
+    <color name="menu" value="#F7F7F7" link="#000000" vlink="#000000" hlink="#000000"/>    
+    <color name="dialog" value="#F7F7F7"/>
+            
+    <color name="body"    value="#ffffff" link="#0F3660" vlink="#009999" hlink="#000066"/>
+    
+    <color name="table" value="#a5b6c6"/>    
+    <color name="table-cell" value="#ffffff"/>    
+    <color name="highlight" value="#ffff00"/>
+    <color name="fixme" value="#cc6600"/>
+    <color name="note" value="#006699"/>
+    <color name="warning" value="#990000"/>
+    <color name="code" value="#a5b6c6"/>
+        
+    <color name="footer" value="#a5b6c6"/>
+-->
+<!-- Color group: Collabnet -->
+<!--
+    <color name="header"    value="#003366"/>
+
+    <color name="tab-selected" value="#dddddd" link="#555555" vlink="#555555" hlink="#555555"/>
+    <color name="tab-unselected" value="#999999" link="#ffffff" vlink="#ffffff" hlink="#ffffff"/>
+    <color name="subtab-selected" value="#cccccc" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="subtab-unselected" value="#cccccc" link="#555555" vlink="#555555" hlink="#555555"/>
+
+    <color name="heading" value="#003366"/>
+    <color name="subheading" value="#888888"/>
+    
+    <color name="navstrip" value="#dddddd" font="#555555"/>
+    <color name="toolbox" value="#dddddd" font="#555555"/>
+    <color name="border" value="#999999"/>
+    
+    <color name="menu" value="#ffffff"/>    
+    <color name="dialog" value="#eeeeee"/>
+            
+    <color name="body"      value="#ffffff"/>
+    
+    <color name="table" value="#ccc"/>    
+    <color name="table-cell" value="#ffffff"/>   
+    <color name="highlight" value="#ffff00"/>
+    <color name="fixme" value="#cc6600"/>
+    <color name="note" value="#006699"/>
+    <color name="warning" value="#990000"/>
+    <color name="code" value="#003366"/>
+        
+    <color name="footer" value="#ffffff"/>
+-->
+<!-- Color group: Lenya using pelt-->
+<!--
+
+    <color name="header" value="#ffffff"/>
+
+    <color name="tab-selected" value="#E5E4D9" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="tab-unselected" value="#F5F4E9" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="subtab-selected" value="#000000" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="subtab-unselected" value="#E5E4D9" link="#000000" vlink="#000000" hlink="#000000"/>
+
+    <color name="heading" value="#E5E4D9"/>
+    <color name="subheading" value="#000000"/>
+    <color name="published" value="#000000"/>
+    <color name="navstrip" value="#E5E4D9" font="#000000"/>
+    <color name="toolbox" value="#CFDCED" font="#000000"/>
+    <color name="border" value="#999999"/>
+
+    <color name="menu" value="#E5E4D9" font="#000000" link="#000000" vlink="#000000" hlink="#000000"/>
+    <color name="dialog" value="#CFDCED"/>
+    <color name="body" value="#ffffff" />
+
+    <color name="table" value="#ccc"/>
+    <color name="table-cell" value="#ffffff"/>
+    <color name="highlight" value="#ffff00"/>
+    <color name="fixme" value="#cc6600"/>
+    <color name="note" value="#006699"/>
+    <color name="warning" value="#990000"/>
+    <color name="code" value="#003366"/>
+
+    <color name="footer" value="#E5E4D9"/>
+-->
+  </colors>
+<!-- Settings specific to PDF output. -->
+  <pdf>
+<!-- 
+       Supported page sizes are a0, a1, a2, a3, a4, a5, executive,
+       folio, legal, ledger, letter, quarto, tabloid (default letter).
+       Supported page orientations are portrait, landscape (default
+       portrait).
+       Supported text alignments are left, right, justify (default left).
+    -->
+    <page size="letter" orientation="portrait" text-align="left"/>
+<!-- 
+       Pattern of the page numbering in the footer - Default is "Page x".
+       first occurrence of '1' digit represents the current page number,
+       second occurrence of '1' digit represents the total page number,
+       anything else is considered as the static part of the numbering pattern.
+       Examples : x is the current page number, y the total page number.
+       <page-numbering-format>none</page-numbering-format> Do not displays the page numbering
+       <page-numbering-format>1</page-numbering-format> Displays "x"
+       <page-numbering-format>p1.</page-numbering-format> Displays "px."
+       <page-numbering-format>Page 1/1</page-numbering-format> Displays "Page x/y"
+       <page-numbering-format>(1-1)</page-numbering-format> Displays "(x-y)"
+    -->
+    <page-numbering-format>Page 1</page-numbering-format>
+<!--
+       Margins can be specified for top, bottom, inner, and outer
+       edges. If double-sided="false", the inner edge is always left
+       and the outer is always right. If double-sided="true", the
+       inner edge will be left on odd pages, right on even pages,
+       the outer edge vice versa.
+       Specified below are the default settings.
+    -->
+    <margins double-sided="false">
+      <top>1in</top>
+      <bottom>1in</bottom>
+      <inner>1.25in</inner>
+      <outer>1in</outer>
+    </margins>
+<!--
+      Print the URL text next to all links going outside the file
+    -->
+    <show-external-urls>false</show-external-urls>
+<!--
+      Normally all links inside a Forrest site are relative. This
+      does not work well in PDFs which are typically viewed outside of
+      the web site. Setting this option adds the given prefix to all
+      relative URLs, both to the link as well as the optional, additional text.
+    -->
+    <url-prefix></url-prefix> 
+<!--
+      Disable the copyright footer on each page of the PDF.
+      A footer is composed for each page. By default, a "credit" with role=pdf
+      will be used, as explained below. Otherwise a copyright statement
+      will be generated. This latter can be disabled.
+    -->
+    <disable-copyright-footer>false</disable-copyright-footer>
+
+    <!--
+    Disable the generation of the table of content on the first page
+    of the PDF. By default the TOC is generated.
+    -->
+    <disable-toc>false</disable-toc>
+  </pdf>
+<!-- 
+    Credits are typically rendered as a set of small clickable
+    images in the page footer.
+    
+    Use box-location="alt" to move the credits to an alternate location
+    (if the skin supports it).
+
+    For example, pelt skin:
+    - box-location="alt" will place the logo at the end of the
+      left-hand coloured menu panel.
+    - box-location="alt2" will place them underneath that panel
+      in the left-hand whitespace.
+    - Otherwise they are placed next to the compatibility icons
+      at the bottom of the screen.
+
+    Comment out the whole <credit>-element if you want no credits in the
+    web pages  
+   -->
+  <credits>
+    <credit box-location="alt">
+      <name>Built with Apache Forrest</name>
+      <url>http://forrest.apache.org/</url>
+      <image>images/built-with-forrest-button.png</image>
+      <width>88</width>
+      <height>31</height>
+    </credit>
+<!-- A credit with @role="pdf" will be used to compose a footer
+     for each page in the PDF, using either "name" or "url" or both.
+    -->
+<!--
+    <credit role="pdf">
+      <name>Built with Apache Forrest</name>
+      <url>http://forrest.apache.org/</url>
+    </credit>
+    -->
+  </credits>
+</skinconfig>

Added: forrest/trunk/whiteboard/forrest-osgi/forrest.build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/forrest.build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/forrest.build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/forrest.build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest" default="site">
+
+  <!-- 
+    Basedir is set to $PROJECT_HOME by `forrest' command,
+    which is the working directory from which `forrest' is called
+    regardless of any basedir setting in this file.
+  -->
+
+  <property environment="env" />
+
+  <property name="forrest.home" location="${env.FORREST_HOME}" />
+  <property name="forrest.bin.dir" location="${forrest.home}/bin" />
+  <property name="forrest.lib.dir" location="${forrest.home}/lib" />
+
+  <property name="tools.dir" location="${forrest.home}/tools" />
+  <property name="ant.dir" location="${tools.dir}/ant" />
+  <property name="bnd.dir" location="${tools.dir}/bnd" />
+  <property name="bnd.jar.file" location="${bnd.dir}/lib/bnd-0.0.384.jar" />
+
+  <property name="forrest.bundle.dir" location="${forrest.home}/bundle" />
+  <property name="forrest.bundle-cache.dir" location="${forrest.home}/felix-cache" />
+  <property name="forrest.osgi.conf.file"
+            location="${forrest.home}/conf/config.properties" />
+
+  <property name="project.home" location="." />
+  <property file="${project.home}/forrest.properties" />
+  <property file="${forrest.home}/conf/default-forrest.properties" />
+
+  <target name="init">
+  </target>
+
+  <target name="site" depends="init" description="* Generate static documentation">
+    <java classname="org.apache.forrest.Forrest"
+          fork="yes">
+      <jvmarg line="${forrest.jvmargs}" />
+      <classpath>
+        <fileset dir="${forrest.lib.dir}" includes="*.jar" />
+        <pathelement location="${forrest.home}/main/build/classes" />
+      </classpath>
+      <syspropertyset>
+        <propertyref prefix="forrest." />
+        <propertyref prefix="project." />
+      </syspropertyset>
+    </java>
+  </target>
+
+  <target name="run" depends="init" description="Run Apache Forrest in dynamic mode">
+  </target>
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.http.bundle-2.2.0.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.http.bundle-2.2.0.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.http.bundle-2.2.0.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.http.bundle-2.2.0.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.log-1.0.1.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.log-1.0.1.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.log-1.0.1.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.felix.log-1.0.1.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.log4j-1.2.16.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.log4j-1.2.16.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.log4j-1.2.16.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.log4j-1.2.16.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.bcel-5.2_3.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.bcel-5.2_3.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.bcel-5.2_3.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.bcel-5.2_3.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xalan-serializer-2.7.1_3.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xalan-serializer-2.7.1_3.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xalan-serializer-2.7.1_3.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xalan-serializer-2.7.1_3.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xerces-2.9.1_4.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xerces-2.9.1_4.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xerces-2.9.1_4.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xerces-2.9.1_4.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xmlresolver-1.2-4.0-m1.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xmlresolver-1.2-4.0-m1.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xmlresolver-1.2-4.0-m1.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/org.apache.servicemix.bundles.xmlresolver-1.2-4.0-m1.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-api-1.6.1.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-api-1.6.1.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-api-1.6.1.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-api-1.6.1.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-log4j12-1.6.1.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-log4j12-1.6.1.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-log4j12-1.6.1.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/slf4j-log4j12-1.6.1.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/bundle/xalan-2.7.1.kf3.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/bundle/xalan-2.7.1.kf3.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/bundle/xalan-2.7.1.kf3.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/bundle/xalan-2.7.1.kf3.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/org.apache.felix.framework-3.2.0.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/org.apache.felix.framework-3.2.0.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/org.apache.felix.framework-3.2.0.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/org.apache.felix.framework-3.2.0.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/lib/org.osgi.compendium-4.2.0.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/lib/org.osgi.compendium-4.2.0.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/lib/org.osgi.compendium-4.2.0.jar (added) and forrest/trunk/whiteboard/forrest-osgi/lib/org.osgi.compendium-4.2.0.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/main/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/main/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/main/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/main/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest Main" default="compile">
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/main/src/java/org/apache/forrest/Forrest.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/main/src/java/org/apache/forrest/Forrest.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/main/src/java/org/apache/forrest/Forrest.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/main/src/java/org/apache/forrest/Forrest.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,227 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Enumeration;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Properties;
+
+import org.apache.felix.framework.util.Util;
+
+import org.osgi.framework.Bundle;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.BundleException;
+import org.osgi.framework.Constants;
+import org.osgi.framework.launch.Framework;
+import org.osgi.framework.launch.FrameworkFactory;
+
+public class Forrest {
+
+  private static Framework sOsgiFramework;
+
+  private List<Bundle> mBundleList = new ArrayList<Bundle>();
+
+  public Forrest() {
+    try {
+      launchOsgiFramework();
+      installBundles();
+      startBundles();
+      // System.exit(0);
+    } catch (Exception ex) {
+      System.err.println("Error launching framework: " + ex);
+      System.exit(0);
+    }
+  }
+
+  private void launchOsgiFramework() throws Exception {
+    sOsgiFramework = getFrameworkFactory().newFramework(getForrestOsgiProperties());
+    sOsgiFramework.start();
+  }
+
+  /**
+   * This method is from Apache Felix:
+   *   main/src/main/java/org/apache/felix/main/Main.java
+   *
+   * java.util.ServiceLoader is cleaner, but requires Java 6
+   *
+   * Simple method to parse META-INF/services file for framework factory.
+   * Currently, it assumes the first non-commented line is the class name
+   * of the framework factory implementation.
+   * @return The created <tt>FrameworkFactory</tt> instance.
+   * @throws Exception if any errors occur.
+   **/
+  private static FrameworkFactory getFrameworkFactory() throws Exception {
+    URL url = Forrest.class.getClassLoader().getResource
+      ("META-INF/services/org.osgi.framework.launch.FrameworkFactory");
+
+    if (url != null) {
+      BufferedReader br = new BufferedReader
+        (new InputStreamReader(url.openStream()));
+
+      try {
+        for (String s = br.readLine(); s != null; s = br.readLine()) {
+          s = s.trim();
+
+          // Try to load first non-empty, non-commented line.
+          if ((s.length() > 0) && (s.charAt(0) != '#')) {
+            return (FrameworkFactory) Class.forName(s).newInstance();
+          }
+        }
+      } finally {
+        if (br != null) {
+          br.close();
+        }
+      }
+    }
+
+    throw new Exception("Could not find framework factory.");
+  }
+
+  private void addShutdownHook() {
+    Runtime.getRuntime().addShutdownHook(new Thread() {
+
+        public void run() {
+          System.out.println("Ok, bye!");
+
+          try {
+            if (null != sOsgiFramework) {
+              sOsgiFramework.stop();
+              sOsgiFramework.waitForStop(0);
+            }
+          } catch (Exception ex) {
+            System.err.println("Error stopping framework: " + ex);
+          }
+        }
+
+      });
+  }
+
+  /*
+   * The following methods are attributed to
+   *   OSGi in Action
+   *   Richard S Hall, Karl Pauls, Stuart McCulloch, David Savage
+   *   Manning Publications Co, 2011
+   */
+  private void installBundles() throws BundleException {
+    // forrest.bundle.dir is defined in forrest.build.xml
+    String bundleDir = System.getProperty("forrest.bundle.dir");
+		
+    System.out.println("Installing bundles from: " + bundleDir);
+
+    File[] files = new File(bundleDir).listFiles();
+    Arrays.sort(files);
+    List<File> jars = new ArrayList<File>();
+
+    for (int i = 0; i < files.length; i++) {
+      if (files[i].getName().toLowerCase().endsWith(".jar")) {
+        jars.add(files[i]);
+      }
+    }
+
+    if (jars.isEmpty()) {
+      System.out.println("No bundles to install");
+    } else {
+      addShutdownHook();
+    }
+
+    BundleContext context = sOsgiFramework.getBundleContext();
+
+    for (int i = 0; i < jars.size(); i++) {
+      System.out.println("Installing bundle: " + jars.get(i).getName());
+      String path = jars.get(i).toURI().toString();
+      Bundle bundle = context.installBundle(path);
+      mBundleList.add(bundle);
+    }
+  }
+
+  private void startBundles() throws BundleException {
+    for (int i = 0; i < mBundleList.size(); i++) {
+      if (!isFragment(mBundleList.get(i))) {
+        System.out.println("Starting bundle: " + mBundleList.get(i).getSymbolicName());
+        mBundleList.get(i).start();
+      }
+    }
+  }
+
+  private boolean isFragment(Bundle bundle) {
+    return null != bundle.getHeaders().get(Constants.FRAGMENT_HOST);
+  }
+
+  /*
+   * This method is based on Apache Felix launch code
+   */
+  private Properties getForrestOsgiProperties() {
+    // Check the forrest.osgi.conf.file system property
+    // and load the properties from that file.
+    // The property is set in forrest.build.xml and passed
+    // to the JVM as a system property.
+
+    Properties props = new Properties();
+    File config = new File(System.getProperty("forrest.osgi.conf.file"));
+		
+    System.out.println("Can read props from " + config.getName() + ": " + config.canRead());
+
+    try {
+      InputStream in = config.toURI().toURL().openStream();
+      props.load(in);
+
+      if (in != null) {
+        in.close();
+      }
+    } catch (Exception e) {
+      System.err.println("Oops: " + e);
+
+      return null;
+    }
+
+    Enumeration<?> sysplist = System.getProperties().propertyNames();
+
+    while (sysplist.hasMoreElements()) {
+      String key = (String) sysplist.nextElement();
+
+      if (key.startsWith("felix.")
+          || key.startsWith("org.osgi.")
+          || key.startsWith("forrest.") || key.startsWith("project.")) {
+        System.out.println("Setting property '" + key + "' to '" + System.getProperty(key) + "'");
+        props.setProperty(key, System.getProperty(key));
+      }
+    }
+
+    Enumeration<?> configplist = props.propertyNames();
+
+    while (configplist.hasMoreElements()) {
+      String name = (String) configplist.nextElement();
+      props.setProperty(name,
+                        Util.substVars(props.getProperty(name), name, null, props));
+    }
+
+    return props;
+  }
+
+  public static void main(String[] args) {
+    new Forrest();
+  }
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/master.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/master.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/master.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/master.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest master" default="compile-all">
+<!-- Bundles import this build file -->
+
+  <property environment="env" />
+
+  <property name="forrest.home" location="${env.FORREST_HOME}" />
+  <property name="forrest.bin.dir" location="${forrest.home}/bin" />
+  <property name="forrest.lib.dir" location="${forrest.home}/lib" />
+
+  <property name="tools.dir" location="${forrest.home}/tools" />
+  <property name="ant.dir" location="${tools.dir}/ant" />
+  <property name="bnd.dir" location="${tools.dir}/bnd" />
+  <property name="bnd.jar.file" location="${bnd.dir}/lib/bnd-0.0.384.jar" />
+
+  <property name="bundle.deploy.dir" location="${forrest.home}/bundle" />
+
+<!--
+  Bundle properties
+  Override in bundle build.xml where necessary
+-->
+  <property name="bundle.vendor" value="The Apache Software Foundation" />
+  <property name="bundle.name" value="" />
+  <property name="bundle.symbolic.name" value="" />
+  <property name="bundle.activator" value="" />
+  <property name="bundle.version" value="0.10.1.dev" />
+  <property name="bundle.bnd.file" location="" />
+  <property name="src.dir" location="src" />
+  <property name="java.src.dir" location="${src.dir}/java" />
+  <property name="bundle.resource.dir" location="${src.dir}/bundle" />
+  <property name="build.dir" location="build" />
+  <property name="build.classes" location="${build.dir}/classes" />
+  <property name="jar.file" location="${bundle.symbolic.name}.jar" />
+
+  <target name="init">
+    <mkdir dir="${build.classes}" />
+
+    <path id="classpath">
+      <fileset dir="${forrest.lib.dir}" includes="*.jar" />
+      <fileset dir="${bundle.deploy.dir}" includes="*.jar" />
+    </path>
+  </target>
+
+  <target name="compile" depends="init">
+    <echo>Compiling ${ant.project.name}</echo>
+    <javac srcdir="${java.src.dir}"
+           destdir="${build.classes}"
+           classpathref="classpath"
+           debug="true"
+           includeantruntime="false">
+      <compilerarg value="-Xlint" />
+    </javac>
+  </target>
+
+  <target name="jar" depends="compile">
+    <echo>Packaging ${ant.project.name}</echo>
+    <jar destfile="${build.dir}/${jar.file}">
+      <fileset dir="${build.classes}" />
+    </jar>
+  </target>
+
+  <target name="bundle" depends="jar">
+    <echo>Bundling ${ant.project.name}</echo>
+    <mkdir dir="${bundle.deploy.dir}" />
+
+    <taskdef resource="aQute/bnd/ant/taskdef.properties"
+             classpath="${bnd.jar.file}" />
+
+    <!--
+    <bndwrap
+        jars="${build.dir}/${jar.file}"
+        output="${bundle.deploy.dir}/${bundle.symbolic.name}-${bundle.version}.jar" />
+    -->
+    <bnd
+        classpath="${build.dir}/${jar.file}"
+        eclipse="false"
+        failok="false"
+        files="${bundle.bnd.file}"
+        output="${bundle.deploy.dir}/${bundle.symbolic.name}-${bundle.version}.jar" />
+  </target>
+
+  <target name="clean">
+    <delete dir="${build.dir}" />
+  </target>
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest Logging" default="bundle">
+
+<!--
+  Bundle properties
+  Override master build.xml where necessary
+-->
+  <property name="bundle.name" value="Apache Forrest Logging Bundle" />
+  <property name="bundle.symbolic.name" value="org.apache.forrest.log" />
+  <property name="bundle.activator" value="org.apache.forrest.log.LogPlugin" />
+  <property name="bundle.bnd.file" location="log.bnd" />
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-api-1.5.11.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-api-1.5.11.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-api-1.5.11.jar (added) and forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-api-1.5.11.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-simple-1.5.11.jar
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-simple-1.5.11.jar?rev=1096394&view=auto
==============================================================================
Files forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-simple-1.5.11.jar (added) and forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/lib/slf4j-simple-1.5.11.jar Mon Apr 25 01:38:03 2011 differ

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/log.bnd
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/log.bnd?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/log.bnd (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/log.bnd Mon Apr 25 01:38:03 2011
@@ -0,0 +1,8 @@
+Bundle-Name: ${bundle.name}
+Bundle-SymbolicName: ${bundle.symbolic.name}
+Bundle-Version: ${bundle.version}
+Bundle-Activator: ${bundle.activator}
+Bundle-Vendor: ${bundle.vendor}
+Import-Package: org.osgi.framework, org.osgi.service.log, org.apache.forrest.log, org.slf4j, org.osgi.util.tracker, org.slf4j.impl, org.apache.log4j
+Export-Package: org.apache.forrest.log
+Private-Package: *

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/LogPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/LogPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/LogPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/LogPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.log;
+
+import java.util.Properties;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.ServiceReference;
+import org.osgi.service.log.LogReaderService;
+import org.osgi.service.log.LogService;
+import org.osgi.util.tracker.ServiceTracker;
+
+import org.apache.forrest.log.service.LogWriter;
+
+public class LogPlugin implements BundleActivator {
+
+  private static LogPlugin sInstance = null;
+
+  private ServiceTracker mLogTracker;
+
+  public void start(final BundleContext context) throws Exception {
+    sInstance = this;
+    mLogTracker = new ServiceTracker(context, LogService.class.getName(), null);
+    mLogTracker.open();
+
+    ServiceReference readerRef = context.getServiceReference(LogReaderService.class.getName());
+
+    if (null != readerRef) {
+      System.out.println("Registering LogWriter");
+      LogReaderService readerService = (LogReaderService) context.getService(readerRef);
+      readerService.addLogListener(new LogWriter());
+      getDefault().getLogService().log(LogService.LOG_DEBUG, "Log bundle starting (and self-hosting)");
+    } else {
+      System.out.println("Could not add log listener (LogReaderService is unavailable)");
+    }
+  }
+
+  public void stop(BundleContext context) throws Exception {
+    sInstance = null;
+    mLogTracker.close();
+    System.out.println("Log bundle stopping");
+  }
+
+  public static LogPlugin getDefault() {
+    return sInstance;
+  }
+
+  public LogService getLogService() {
+    LogService theServ = (LogService) mLogTracker.getService();
+
+    return theServ;
+  }
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/service/LogWriter.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/service/LogWriter.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/service/LogWriter.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log/src/java/org/apache/forrest/log/service/LogWriter.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.log.service;
+
+import org.osgi.service.log.LogEntry;
+import org.osgi.service.log.LogListener;
+import org.osgi.service.log.LogService;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class LogWriter implements LogListener {
+
+  private static final String[] LEVEL_STRING = { "", "ERROR", "WARNING", "INFO", "DEBUG" };
+
+  private static final Logger sLogger = LoggerFactory.getLogger(LogWriter.class);
+
+  @Override
+  public void logged(LogEntry entry) {
+    int level = entry.getLevel();
+
+    if (level > -1 && level < LEVEL_STRING.length) {
+      switch (level) {
+      case LogService.LOG_ERROR:
+        sLogger.error(entry.getMessage());
+        break;
+      case LogService.LOG_WARNING:
+        sLogger.warn(entry.getMessage());
+        break;
+      case LogService.LOG_INFO:
+        sLogger.info(entry.getMessage());
+        break;
+      case LogService.LOG_DEBUG:
+        sLogger.debug(entry.getMessage());
+        break;
+      default:
+        sLogger.warn("LogEntry with unknown log level: " + level);
+      }
+    }
+  }
+
+}
+

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest Log4j Config" default="bundle">
+
+<!--
+  Bundle properties
+  Override master build.xml where necessary
+-->
+  <property name="bundle.name" value="Apache Forrest Log4j Config Bundle" />
+  <property name="bundle.symbolic.name" value="org.apache.forrest.log4j.conf" />
+  <property name="bundle.bnd.file" location="log4j.bnd" />
+
+  <!--
+    Override master jar target to include bundle resources
+  -->
+  <target name="jar">
+    <jar destfile="${build.dir}/${jar.file}">
+      <fileset dir="${java.src.dir}" />
+    </jar>
+  </target>
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/log4j.bnd
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/log4j.bnd?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/log4j.bnd (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/log4j.bnd Mon Apr 25 01:38:03 2011
@@ -0,0 +1,6 @@
+Bundle-Name: ${bundle.name}
+Bundle-SymbolicName: ${bundle.symbolic.name}
+Bundle-Version: ${bundle.version}
+Bundle-Vendor: ${bundle.vendor}
+Fragment-Host: org.apache.log4j
+Private-Package: *

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/src/java/log4j.properties
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/src/java/log4j.properties?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/src/java/log4j.properties (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.log4j.conf/src/java/log4j.properties Mon Apr 25 01:38:03 2011
@@ -0,0 +1,6 @@
+log4j.rootLogger=INFO, A
+log4j.appender.A=org.apache.log4j.ConsoleAppender
+log4j.appender.A.layout=org.apache.log4j.PatternLayout
+log4j.appender.A.layout.ConversionPattern=%-5p: %m%n
+
+log4j.logger.org.apache.forrest=DEBUG

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest Plugin API" default="bundle">
+
+<!--
+  Bundle properties
+  Override master.xml where necessary
+-->
+  <property name="bundle.name" value="Apache Forrest Plugin API Bundle" />
+  <property name="bundle.symbolic.name" value="org.apache.forrest.plugin.api" />
+  <property name="bundle.bnd.file" location="pluginApi.bnd" />
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/pluginApi.bnd
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/pluginApi.bnd?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/pluginApi.bnd (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/pluginApi.bnd Mon Apr 25 01:38:03 2011
@@ -0,0 +1,6 @@
+Bundle-Name: ${bundle.name}
+Bundle-SymbolicName: ${bundle.symbolic.name}
+Bundle-Version: ${bundle.version}
+Bundle-Vendor: ${bundle.vendor}
+Export-Package: org.apache.forrest.plugin.api
+Import-Package: javax.xml.transform, javax.xml.transform.stream, org.apache.forrest.plugin.api, org.osgi.framework, org.osgi.service.log, org.apache.forrest.log

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/AbstractPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/AbstractPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/AbstractPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/AbstractPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.net.URI;
+import org.osgi.framework.BundleContext;
+import org.osgi.service.log.LogService;
+
+import org.apache.forrest.log.LogPlugin;
+import org.apache.forrest.plugin.api.ForrestPlugin;
+import org.apache.forrest.plugin.api.ForrestResult;
+import org.apache.forrest.plugin.api.ForrestSource;
+
+public abstract class AbstractPlugin implements ForrestPlugin {
+
+  private BundleContext mContext;
+
+  public AbstractPlugin(final BundleContext context) {
+    mContext = context;
+  }
+
+  protected final BundleContext getBundleContext() {
+    return mContext;
+  }
+
+  public abstract ForrestSource getSource(URI uri);
+
+  public abstract ForrestResult transform(ForrestSource source);
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseInputPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseInputPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseInputPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseInputPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.net.URI;
+import org.osgi.framework.BundleContext;
+import org.osgi.service.log.LogService;
+
+import org.apache.forrest.log.LogPlugin;
+import org.apache.forrest.plugin.api.ForrestResult;
+import org.apache.forrest.plugin.api.ForrestSource;
+
+public class BaseInputPlugin extends AbstractPlugin {
+
+  public BaseInputPlugin(final BundleContext context) {
+    super(context);
+  }
+
+  public ForrestSource getSource(URI uri) {
+    LogPlugin.getDefault().getLogService().log
+      (LogService.LOG_DEBUG, "BaseInputPlugin.getSource() must be implemented by a plugin, ignoring");
+
+    return null;
+  }
+
+  public ForrestResult transform(ForrestSource source) {
+    LogPlugin.getDefault().getLogService().log
+      (LogService.LOG_DEBUG, "transform() called on an input plugin, ignoring");
+
+    return null;
+  }
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseOutputPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseOutputPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseOutputPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/BaseOutputPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.net.URI;
+import org.osgi.framework.BundleContext;
+import org.osgi.service.log.LogService;
+
+import org.apache.forrest.log.LogPlugin;
+import org.apache.forrest.plugin.api.ForrestResult;
+import org.apache.forrest.plugin.api.ForrestSource;
+
+public class BaseOutputPlugin extends AbstractPlugin {
+
+  public BaseOutputPlugin(final BundleContext context) {
+    super(context);
+  }
+
+  public ForrestSource getSource(URI uri) {
+    LogPlugin.getDefault().getLogService().log
+      (LogService.LOG_DEBUG, "getSource() called on an output plugin, ignoring");
+
+    return null;
+  }
+
+  public ForrestResult transform(ForrestSource source) {
+    LogPlugin.getDefault().getLogService().log
+      (LogService.LOG_DEBUG, "BaseOutputPlugin.transform() must be implemented by a plugin, ignoring");
+
+    return null;
+  }
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.net.URI;
+
+public interface ForrestPlugin {
+
+  public static String TYPE_INPUT = "input";
+
+  public static String TYPE_OUTPUT = "output";
+
+  public ForrestSource getSource(URI uri);
+
+  public ForrestResult transform(ForrestSource input);
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestResult.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestResult.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestResult.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestResult.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+public interface ForrestResult {
+
+  public String getResultAsString();
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestSource.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestSource.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestSource.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestSource.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.io.InputStream;
+import javax.xml.transform.stream.StreamResult;
+
+public interface ForrestSource {
+
+  public InputStream getInputStream();
+  public String getSourceAsString();
+  public void setInternalRepresentation(String internal);
+  public String getInternalRepresentationAsString();
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestStreamSource.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestStreamSource.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestStreamSource.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.api/src/java/org/apache/forrest/plugin/api/ForrestStreamSource.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,76 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.api;
+
+import java.io.BufferedReader;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.IOException;
+import javax.xml.transform.stream.StreamResult;
+
+public class ForrestStreamSource implements ForrestSource {
+
+  private InputStream mRawInputStream;
+  private String mInternalString;
+
+  public ForrestStreamSource(InputStream input) {
+    mRawInputStream = input;
+  }
+
+  @Override
+  public InputStream getInputStream() {
+    return mRawInputStream;
+  }
+
+  @Override
+  public String getSourceAsString() {
+    if (null != mRawInputStream) {
+      StringBuilder inputString = new StringBuilder();
+      BufferedReader br = new BufferedReader(new InputStreamReader(mRawInputStream));
+
+      try {
+        String line = br.readLine();
+
+        while (null != line) {
+          inputString.append(line);
+          line = br.readLine();
+        }
+
+        return inputString.toString();
+      } catch (IOException ioe) {
+        System.out.println("Problem accessing the resource: " + ioe);
+      }
+    }
+
+    return new String();
+  }
+
+  @Override
+  public String getInternalRepresentationAsString() {
+    if (null != mInternalString) {
+      return mInternalString;
+    }
+
+    return new String();
+  }
+
+  @Override
+  public void setInternalRepresentation(String internal) {
+    mInternalString = internal;
+  }
+
+}

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest XDoc Input Resources" default="bundle">
+
+<!--
+  Bundle properties
+  Override master build.xml where necessary
+-->
+  <property name="bundle.name" value="Apache Forrest XDoc Input Resources Bundle" />
+  <property name="bundle.symbolic.name" value="org.apache.forrest.plugin.input.xdoc.res" />
+  <property name="bundle.bnd.file" location="xdocInputRes.bnd" />
+
+  <!--
+    Override master jar target to include bundle resources
+  -->
+  <target name="jar">
+    <jar destfile="${build.dir}/${jar.file}">
+      <fileset dir="${bundle.resource.dir}" />
+    </jar>
+  </target>
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/src/bundle/resources/stylesheets/documentv20-to-internal.xsl
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/src/bundle/resources/stylesheets/documentv20-to-internal.xsl?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/src/bundle/resources/stylesheets/documentv20-to-internal.xsl (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/src/bundle/resources/stylesheets/documentv20-to-internal.xsl Mon Apr 25 01:38:03 2011
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+<!-- document-v20.dtd to document-v13.dtd transformation -->
+  <xsl:template match="/">
+    <xsl:apply-templates/>
+  </xsl:template>
+  <xsl:template match="a">
+    <link>
+      <xsl:apply-templates select="@*"/>
+      <xsl:apply-templates select="node()"/>
+    </link>
+  </xsl:template>
+<!-- the obligatory copy-everything -->
+  <xsl:template match="node() | @*">
+    <xsl:copy>
+      <xsl:apply-templates select="@*"/>
+      <xsl:apply-templates/>
+    </xsl:copy>
+  </xsl:template>
+</xsl:stylesheet>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/xdocInputRes.bnd
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/xdocInputRes.bnd?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/xdocInputRes.bnd (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc.res/xdocInputRes.bnd Mon Apr 25 01:38:03 2011
@@ -0,0 +1,6 @@
+Bundle-Name: ${bundle.name}
+Bundle-SymbolicName: ${bundle.symbolic.name}
+Bundle-Version: ${bundle.version}
+Bundle-Vendor: ${bundle.vendor}
+Private-Package: *
+Fragment-Host: org.apache.forrest.plugin.input.xdoc

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/build.xml
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/build.xml?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/build.xml (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/build.xml Mon Apr 25 01:38:03 2011
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  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.
+-->
+<project name="Apache Forrest XDoc Input" default="bundle">
+
+<!--
+  Bundle properties
+  Override master build.xml where necessary
+-->
+  <property name="bundle.name" value="Apache Forrest XDoc Input Bundle" />
+  <property name="bundle.symbolic.name" value="org.apache.forrest.plugin.input.xdoc" />
+  <property name="bundle.activator" value="org.apache.forrest.plugin.input.xdoc.XDocInputPlugin" />
+  <property name="bundle.bnd.file" location="xdocInput.bnd" />
+
+  <import file="../master.xml" />
+
+</project>

Added: forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/src/java/org/apache/forrest/plugin/input/xdoc/XDocInputPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/src/java/org/apache/forrest/plugin/input/xdoc/XDocInputPlugin.java?rev=1096394&view=auto
==============================================================================
--- forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/src/java/org/apache/forrest/plugin/input/xdoc/XDocInputPlugin.java (added)
+++ forrest/trunk/whiteboard/forrest-osgi/org.apache.forrest.plugin.input.xdoc/src/java/org/apache/forrest/plugin/input/xdoc/XDocInputPlugin.java Mon Apr 25 01:38:03 2011
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * 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.
+ */
+package org.apache.forrest.plugin.input.xdoc;
+
+import java.util.Properties;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+
+import org.apache.forrest.plugin.api.ForrestPlugin;
+import org.apache.forrest.plugin.input.xdoc.service.XDocInput;
+
+public class XDocInputPlugin implements BundleActivator {
+
+  public void start(final BundleContext context) throws Exception {
+    System.out.println("XDoc bundle starting");
+
+    Properties props = new Properties();
+    props.put("pluginType", "input");
+    props.put("contentType", "application/xml");
+    context.registerService(ForrestPlugin.class.getName(), new XDocInput(context), props);
+  }
+
+  public void stop(BundleContext context) throws Exception {
+    System.out.println("XDoc bundle stopping");
+  }
+
+}



Mime
View raw message