From: David ‘Bombe’ Roden Date: Mon, 9 Mar 2009 13:40:38 +0000 (+0100) Subject: Add page container. X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=2afeec11e70577d9b92b1e73bdc23869c46a85ce;p=arachne.git Add page container. --- diff --git a/src/net/pterodactylus/arachne/core/Page.java b/src/net/pterodactylus/arachne/core/Page.java new file mode 100644 index 0000000..8c4ae44 --- /dev/null +++ b/src/net/pterodactylus/arachne/core/Page.java @@ -0,0 +1,51 @@ +/* + * © 2009 David ‘Bombe’ Roden + */ +package net.pterodactylus.arachne.core; + +/** + * Container for a page. A page consists of a {@link Site} and a path within the + * site. + * + * @author David ‘Bombe’ Roden + */ +public class Page { + + /** The site of the page. */ + private final Site site; + + /** The path of the page. */ + private final String path; + + /** + * Creates a new page. + * + * @param site + * The site of the page + * @param path + * The path of the page + */ + public Page(Site site, String path) { + this.site = site; + this.path = path; + } + + /** + * Returns the site of the page. + * + * @return The page’s site + */ + public Site getSite() { + return site; + } + + /** + * Returns the path of the page within the site. + * + * @return The page’s path + */ + public String getPath() { + return path; + } + +}