Author: buildbot
Date: Wed Feb 15 19:20:51 2012
New Revision: 804953
Log:
Staging update by buildbot for stanbol
Modified:
websites/staging/stanbol/trunk/ (props changed)
websites/staging/stanbol/trunk/content/stanbol/docs/trunk/enhancer/index.html
Propchange: websites/staging/stanbol/trunk/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Wed Feb 15 19:20:51 2012
@@ -1 +1 @@
-1244647
+1244661
Modified:
websites/staging/stanbol/trunk/content/stanbol/docs/trunk/enhancer/index.html
==============================================================================
---
websites/staging/stanbol/trunk/content/stanbol/docs/trunk/enhancer/index.html
(original)
+++
websites/staging/stanbol/trunk/content/stanbol/docs/trunk/enhancer/index.html
Wed Feb 15 19:20:51 2012
@@ -79,34 +79,15 @@
<p>For detailed information please see the documentation provided by the
Stanbol Web UI (e.g. <a
href="http://localhost:8080/enhancer">http://localhost:8080/enhancer</a>
assuming that Apache Stanbol runs on localhost:8080).</p>
<h3 id="java_api">Java API:</h3>
<p>The usage of the Java API requires the following OSGI Services</p>
-<table class="codehilitetable"><tr><td class="linenos"><div
class="linenodiv"><pre>1
-2
-3
-4</pre></div></td><td class="code"><div class="codehilite"><pre><span
class="nd">@Reference</span>
+<div class="codehilite"><pre><span class="nd">@Reference</span>
<span class="n">EnhancementJobManager</span> <span
class="n">jobManager</span><span class="o">;</span>
<span class="nd">@Reference</span>
<span class="n">ChainManager</span> <span class="n">chainManager</span><span
class="o">;</span>
</pre></div>
-</td></tr></table>
+
<p>This code snipped shows how to enhance a HTML document</p>
-<table class="codehilitetable"><tr><td class="linenos"><div
class="linenodiv"><pre> 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
-10
-11
-12
-13
-14
-15
-16
-17</pre></div></td><td class="code"><div class="codehilite"><pre><span
class="n">InputStream</span> <span class="n">content</span><span
class="o">;</span> <span class="c1">//the content (assuming an HTML
document)</span>
+<div class="codehilite"><pre><span class="n">InputStream</span> <span
class="n">content</span><span class="o">;</span> <span class="c1">//the content
(assuming an HTML document)</span>
<span class="n">String</span> <span class="n">chainName</span><span
class="o">;</span> <span class="c1">//the name of the chain or null to use the
default</span>
<span class="n">ContentItem</span> <span class="n">contentItem</span> <span
class="o">=</span> <span class="k">new</span> <span
class="n">InMemoryContentItem</span><span class="o">(</span>
<span class="n">IOUtils</span><span class="o">.</span><span
class="na">toByteArray</span><span class="o">(</span><span
class="n">content</span><span class="o">),</span> <span
class="s">"text/html; charset=UTF-8"</span><span class="o">);</span>
@@ -124,7 +105,7 @@
<span class="c1">//Get the enhancement Results</span>
<span class="n">MGraph</span> <span class="n">enhancements</span> <span
class="o">=</span> <span class="n">contentItem</span><span
class="o">.</span><span class="na">getMetadata</span><span class="o">();</span>
</pre></div>
-</td></tr></table>
+
<p>After the enhancement process finishes ContentIems do not only contain the
metadata but also other informations such as converted versions of the parsed
content. The following code snippet shows how to retrieve the text version of
the parsed HTML content such as created by the <a
href="engines/metaxaengine.html">Metaxa Engine</a>.</p>
<div class="codehilite"><pre><span class="n">Entry</span><span
class="sr"><UriRef,Blob></span> <span class="n">textContentPart</span>
<span class="o">=</span>