这里会显示出您选择的修订版和当前版本之间的差别。
| 两侧同时换到之前的修订记录 前一修订版 后一修订版 | 前一修订版 | ||
|
zh:courses:textmining2026:ch01 [2026/09/06 11:32] pzczxs [POM配置文件] |
zh:courses:textmining2026:ch01 [2026/09/06 12:17] (当前版本) pzczxs [测试实例] |
||
|---|---|---|---|
| 行 44: | 行 44: | ||
| *修改Use default Workspace location,或直接点击Next; | *修改Use default Workspace location,或直接点击Next; | ||
| *选择maven-archetype-quickstart,点击Next; | *选择maven-archetype-quickstart,点击Next; | ||
| - | *输入Group Id(例如:<color red>cn.edu.bjut</color>),Artifact Id(例如:<color red>textmining</color>)和Package(例如:<color red>cn.edu.bjut.textmining.chapter1</color>),点击Finish。 | + | *输入Group Id(例如:<color red>cn.edu.bjut.textmining</color>),Artifact Id(例如:<color red>JavaTextMining</color>)和Package(例如:<color red>cn.edu.bjut.textmining.chapter1</color>),点击Finish。 |
| - | ==== 第三方库依赖 ==== | + | ==== POM配置文件 ==== |
| - | <code xml> | + | <file xml pom.xml> |
| - | <dependency> | + | <project xmlns="http://maven.apache.org/POM/4.0.0" |
| - | <groupId>junit</groupId> | + | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| - | <artifactId>junit</artifactId> | + | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| - | <version>3.8.1</version> | + | <modelVersion>4.0.0</modelVersion> |
| - | <scope>test</scope> | + | |
| - | </dependency> | + | <groupId>cn.edu.bjut.textmining</groupId> |
| - | <dependency> | + | <artifactId>JavaTextMining</artifactId> |
| - | <groupId>org.slf4j</groupId> | + | <version>0.0.1-SNAPSHOT</version> |
| - | <artifactId>slf4j-simple</artifactId> | + | <packaging>jar</packaging> |
| - | <version>2.0.18</version> | + | |
| - | </dependency> | + | <name>textming</name> |
| - | <dependency> | + | <url>http://maven.apache.org</url> |
| - | <groupId>org.apache.opennlp</groupId> | + | |
| - | <artifactId>opennlp-tools</artifactId> | + | <properties> |
| - | <version>2.3.0</version> | + | <maven.compiler.source>17</maven.compiler.source> |
| - | </dependency> | + | <maven.compiler.target>17</maven.compiler.target> |
| - | </code> | + | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| + | </properties> | ||
| + | |||
| + | <dependencies> | ||
| + | <dependency> | ||
| + | <groupId>junit</groupId> | ||
| + | <artifactId>junit</artifactId> | ||
| + | <version>3.8.1</version> | ||
| + | <scope>test</scope> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.slf4j</groupId> | ||
| + | <artifactId>slf4j-simple</artifactId> | ||
| + | <version>2.0.18</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.apache.opennlp</groupId> | ||
| + | <artifactId>opennlp-tools</artifactId> | ||
| + | <version>2.3.0</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.apache.commons</groupId> | ||
| + | <artifactId>commons-lang3</artifactId> | ||
| + | <version>3.12.0</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>commons-io</groupId> | ||
| + | <artifactId>commons-io</artifactId> | ||
| + | <version>2.11.0</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.jsoup</groupId> | ||
| + | <artifactId>jsoup</artifactId> | ||
| + | <version>1.22.2</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.apache.lucene</groupId> | ||
| + | <artifactId>lucene-core</artifactId> | ||
| + | <version>8.11.2</version> | ||
| + | </dependency> | ||
| + | <dependency> | ||
| + | <groupId>org.apache.lucene</groupId> | ||
| + | <artifactId>lucene-analyzers-common</artifactId> | ||
| + | <version>8.11.2</version> | ||
| + | </dependency> | ||
| + | </dependencies> | ||
| + | </project> | ||
| + | </file> | ||
| ==== 实例代码 ==== | ==== 实例代码 ==== | ||