2 * © 2009 David ‘Bombe’ Roden
4 package net.pterodactylus.arachne.core;
6 import de.ina.util.validation.Validation;
9 * Container for an edition. An edition is (contrary to the usual “freenet
10 * jargon”) a specific edition of a site.
12 * @author David ‘Bombe’ Roden <bombe@pterodactylus.net>
14 public class Edition {
16 /** The site of the edition. */
17 private final Site site;
19 /** The edition number of the edition. */
20 private final int number;
23 * Creates a new edition.
26 * The site of the edition
28 * The edition number of the edition
30 public Edition(Site site, int number) {
31 Validation.begin().isNotNull("site", site).isPositive("edition", number).check();
37 * Returns the site of this edition.
39 * @return This edition’s site
41 public Site getSite() {
46 * Returns the edition number of this edition.
48 * @return This edition’s edition number
50 public int getNumber() {
61 * @see java.lang.Object#toString()
64 public String toString() {
65 return getClass().getName() + "[site=" + site + ",number=" + number + "]";