* added complete XML header to sample usage of namespace
* fixes #164 git-svn-id: svn+ssh://svn.synyx.de/var/svn/synyx/opensource/hera/trunk@8084 5a64d73e-33d6-4ccc-9058-23f8668ecac9
This commit is contained in:
@@ -141,13 +141,20 @@ public class HostImpl implements Host {
|
||||
<example>
|
||||
<title>Host configuration using the plugin namespace</title>
|
||||
|
||||
<programlisting language="xml"><import resource="classpath*:com/acme/**/plugins.xml" />
|
||||
<programlisting language="xml"><beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:plugin="http://schemas.synyx.org/hera"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
|
||||
http://schemas.synyx.org/hera http://schemas.synyx.org/hera/hera.xsd">
|
||||
|
||||
<bean id="host" class="com.acme.HostImpl">
|
||||
<property name="plugins" ref="plugins" />
|
||||
</bean>
|
||||
<import resource="classpath*:com/acme/**/plugins.xml" />
|
||||
|
||||
<plugin:list id="plugins" class="org.acme.MyPluginInterface" /></programlisting>
|
||||
<bean id="host" class="com.acme.HostImpl">
|
||||
<property name="plugins" ref="plugins" />
|
||||
</bean>
|
||||
|
||||
<plugin:list id="plugins" class="org.acme.MyPluginInterface" />
|
||||
</beans></programlisting>
|
||||
</example>
|
||||
|
||||
<para>Suggested you have added the namespace XSD into Eclipse and
|
||||
@@ -158,10 +165,6 @@ public class HostImpl implements Host {
|
||||
<simplesect>
|
||||
<title>Using inner beans</title>
|
||||
|
||||
<note>
|
||||
<para>This feature is only available for version 0.3 and above!</para>
|
||||
</note>
|
||||
|
||||
<para>The listing above features an indirection for the
|
||||
<code>plugin</code> bean definition. Defining the plugin list as top
|
||||
level bean can have advantages: you easily could place all plugin lists
|
||||
|
||||
Reference in New Issue
Block a user