54.8. xsl:include の使用
Camel は URIResolver の独自の実装を提供します。これにより、Camel はクラスパスから含まれるファイルをロードできます。
たとえば、以下のコードの include ファイルは、開始エンドポイントと相対的にあります。
<xsl:include href="staff_template.xsl"/>
<xsl:include href="staff_template.xsl"/>
つまり、Camel は クラス パス内のファイルを org/apache/camel/component/xslt/staff_template.xslとして特定します。
classpath: または file: を使用して、クラスパスまたはファイルシステムのいずれかを検索するよう Camel に指示することができます。接頭辞を省略すると、Camel はエンドポイント設定から接頭辞を使用します。エンドポイント設定で接頭辞が指定されていない場合、デフォルトは classpath: です。
include パスで後方を参照することもできます。以下の例では、xsl ファイルは org/apache/camel/component で解決されます。
<xsl:include href="../staff_other_template.xsl"/>
<xsl:include href="../staff_other_template.xsl"/>