From 1740d1d22d9bd79c101212bdde37c30f64c23da1 Mon Sep 17 00:00:00 2001 From: baihuijuan <3078948726@qq.com> Date: Thu, 21 May 2026 16:28:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E6=88=90=E4=BB=A3=E7=A0=81=E8=90=BD?= =?UTF-8?q?=E5=9C=B0=E4=BD=9C=E4=B8=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- w11/ArticleA.java | 27 +++++++++++++++++++++++++++ w11/ArticleRepository.java | 4 ++++ w11/BlogStrategy.java | 4 ++++ w11/Command.java | 4 ++++ w11/CrawlCommand.java | 4 ++++ w11/CrawlStrategy.java | 4 ++++ w11/CrawlerException.java | 4 ++++ w11/HnuNewsStrategy.java | 4 ++++ w11/Main11.java | 4 ++++ w11/NetworkException.java | 4 ++++ w11/NewsStrategy.java | 4 ++++ w11/ParseException.java | 4 ++++ w11/logback | 0 w11/pom | 0 14 files changed, 71 insertions(+) create mode 100644 w11/ArticleA.java create mode 100644 w11/ArticleRepository.java create mode 100644 w11/BlogStrategy.java create mode 100644 w11/Command.java create mode 100644 w11/CrawlCommand.java create mode 100644 w11/CrawlStrategy.java create mode 100644 w11/CrawlerException.java create mode 100644 w11/HnuNewsStrategy.java create mode 100644 w11/Main11.java create mode 100644 w11/NetworkException.java create mode 100644 w11/NewsStrategy.java create mode 100644 w11/ParseException.java create mode 100644 w11/logback create mode 100644 w11/pom diff --git a/w11/ArticleA.java b/w11/ArticleA.java new file mode 100644 index 0000000..0042984 --- /dev/null +++ b/w11/ArticleA.java @@ -0,0 +1,27 @@ +import java.util.Date; + +public class article { + private String title; + private String content; + private String url; + private String author; // 新增 + private Date publishDate; // 新增 + + // 构造器 + public article(String title, String content, String url, String author, Date publishDate) { + this.title = title; + this.content = content; + this.url = url; + this.author = author; + this.publishDate = publishDate; + } + + // Getters and Setters + public String getAuthor() { return author; } + public void setAuthor(String author) { this.author = author; } + + public Date getPublishDate() { return publishDate; } + public void setPublishDate(Date publishDate) { this.publishDate = publishDate; } + + // 原有字段的 getter/setter... +} \ No newline at end of file diff --git a/w11/ArticleRepository.java b/w11/ArticleRepository.java new file mode 100644 index 0000000..6c379dc --- /dev/null +++ b/w11/ArticleRepository.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class ArticleRepository { +} diff --git a/w11/BlogStrategy.java b/w11/BlogStrategy.java new file mode 100644 index 0000000..37c8963 --- /dev/null +++ b/w11/BlogStrategy.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class BlogStrategy { +} diff --git a/w11/Command.java b/w11/Command.java new file mode 100644 index 0000000..e8cf8ac --- /dev/null +++ b/w11/Command.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class Command { +} diff --git a/w11/CrawlCommand.java b/w11/CrawlCommand.java new file mode 100644 index 0000000..40dde5e --- /dev/null +++ b/w11/CrawlCommand.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class CrawlCommand { +} diff --git a/w11/CrawlStrategy.java b/w11/CrawlStrategy.java new file mode 100644 index 0000000..092aa93 --- /dev/null +++ b/w11/CrawlStrategy.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class CrawlStrategy { +} diff --git a/w11/CrawlerException.java b/w11/CrawlerException.java new file mode 100644 index 0000000..bff0d88 --- /dev/null +++ b/w11/CrawlerException.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class CrawlerException { +} diff --git a/w11/HnuNewsStrategy.java b/w11/HnuNewsStrategy.java new file mode 100644 index 0000000..8bb5e3c --- /dev/null +++ b/w11/HnuNewsStrategy.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class HnuNewsStrategy { +} diff --git a/w11/Main11.java b/w11/Main11.java new file mode 100644 index 0000000..1e936b3 --- /dev/null +++ b/w11/Main11.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class Main { +} diff --git a/w11/NetworkException.java b/w11/NetworkException.java new file mode 100644 index 0000000..5baf7ca --- /dev/null +++ b/w11/NetworkException.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class NetworkException { +} diff --git a/w11/NewsStrategy.java b/w11/NewsStrategy.java new file mode 100644 index 0000000..0e9404d --- /dev/null +++ b/w11/NewsStrategy.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class NewsStrategy { +} diff --git a/w11/ParseException.java b/w11/ParseException.java new file mode 100644 index 0000000..fbbd6d4 --- /dev/null +++ b/w11/ParseException.java @@ -0,0 +1,4 @@ +package PACKAGE_NAME; + +public class ParseException { +} diff --git a/w11/logback b/w11/logback new file mode 100644 index 0000000..e69de29 diff --git a/w11/pom b/w11/pom new file mode 100644 index 0000000..e69de29