From: David ‘Bombe’ Roden Date: Mon, 9 Mar 2009 13:58:22 +0000 (+0100) Subject: Add validation. X-Git-Url: https://git.pterodactylus.net/?p=arachne.git;a=commitdiff_plain;h=4274141d510353f4f8b6b76965d8e7fbd1467456 Add validation. --- diff --git a/src/net/pterodactylus/arachne/core/Site.java b/src/net/pterodactylus/arachne/core/Site.java index bcefb45..86f1fe1 100644 --- a/src/net/pterodactylus/arachne/core/Site.java +++ b/src/net/pterodactylus/arachne/core/Site.java @@ -3,6 +3,8 @@ */ package net.pterodactylus.arachne.core; +import de.ina.util.validation.Validation; + /** * Container for a freenet site. A freenet site consists of the routing and * decryption keys and the basename, without the edition. @@ -26,6 +28,7 @@ public class Site { * The basename of the site */ public Site(String key, String basename) { + Validation.begin().isNotNull("key", (Object) key).isNotNull("basename", (Object) basename).check(); this.key = key; this.basename = basename; }