2012-02-06 6 views
1

Apache Tikaソースフォルダをダウンロードしました.Mavenをインストールしました。次に、コマンドラインで(MVNインストール)私はティカインストールされている:org.apache.tikaソースを自分のプロジェクトに統合するには?

[INFO] Reactor Summary: 
[INFO] ------------------------------------------------------------------------ 
[INFO] Apache Tika parent .................................... SUCCESS [4:20.656s] 
[INFO] Apache Tika core ...................................... SUCCESS [2:26.466s] 
[INFO] Apache Tika parsers ................................... SUCCESS [3:27.711s] 
[INFO] Apache Tika application ............................... SUCCESS [1:23.548s] 
[INFO] Apache Tika OSGi bundle ............................... SUCCESS [3:34.223s] 
[INFO] Apache Tika ........................................... SUCCESS [6.217s] 
[INFO] ------------------------------------------------------------------------ 
[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD SUCCESSFUL 

をしかし、今、私は私のプロジェクトでティカを使用するための次のステップが何であるかを知りません。実際に私は私のプロジェクトにTikaを追加する方法を知らない。

jikaファイルの代わりにTikaソースを使用した理由は、farsi.ngpファイルをTikaのlanguageIdentificationに追加したかったからです。私はfarsi.ngpを追加し、TikaをMavenでビルドしましたが、今は次のステップが分かりません。本当に自分のプロジェクトに追加しなければならないものは何ですか?

+0

これを依存関係として含めます。しかし、それを非標準ビルドとして識別する何らかのタグを付けてください。まだ、リリースに含まれるようにTikaにパッチを提出してください。ありがとう。 –

答えて

2

私はthisページを読み、次は私の提案です:

あなたは、コードを変更したり.ngpファイルを追加し、コードをビルドした後、あなたはこれらの成果物を作成取得する必要があります。

tika-core/target/tika-core-1.0.jar 
tika-parsers/target/tika-parsers-1.0.jar 

どこあなたのアプリケーションでは、tikaを使うことを望み、2つのtika jarとそれに依存するjarファイルをclasspathに置きます。たとえば、アプリケーションでantを使用している場合は、次のようにビルドファイルに追加します。

<classpath> 
    ... <!-- your other classpath entries --> 
    <pathelement location="path/to/tika-core-1.0.jar"/> 
    <pathelement location="path/to/tika-parsers-1.0.jar"/> 
    <pathelement location="path/to/commons-logging-1.1.1.jar"/> 
    <pathelement location="path/to/commons-compress-1.0.jar"/> 
    <pathelement location="path/to/pdfbox-1.0.0-incubating.jar"/> 
    <pathelement location="path/to/fontbox-1.0.0-incubator.jar"/> 
    <pathelement location="path/to/jempbox-1.0.0-incubator.jar"/> 
    <pathelement location="path/to/poi-3.6.jar"/> 
    <pathelement location="path/to/poi-scratchpad-3.6.jar"/> 
    <pathelement location="path/to/poi-ooxml-3.6.jar"/> 
    <pathelement location="path/to/poi-ooxml-schemas-3.6.jar"/> 
    <pathelement location="path/to/xmlbeans-2.3.0.jar"/> 
    <pathelement location="path/to/dom4j-1.6.1.jar"/> 
    <pathelement location="path/to/xml-apis-1.0.b2.jar"/> 
    <pathelement location="path/to/geronimo-stax-api_1.0_spec-1.0.jar"/> 
    <pathelement location="path/to/tagsoup-1.2.jar"/> 
    <pathelement location="path/to/asm-3.1.jar"/> 
    <pathelement location="path/to/log4j-1.2.14.jar"/> 
    <pathelement location="path/to/metadata-extractor-2.4.0-beta-1.jar"/> 
</classpath> 

これは役に立ちます。

+0

それは助けた – aliakbarian

関連する問題