From de7b6ed8820a244280ecab89fcd45c8751233074 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Fri, 21 Sep 2012 12:49:35 +0200 Subject: [PATCH] =?utf8?q?Add=20=E2=80=9Calways=20force=20insert=E2=80=9D?= =?utf8?q?=20option=20to=20projects.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- .../de/todesbaum/jsite/application/Project.java | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/src/main/java/de/todesbaum/jsite/application/Project.java b/src/main/java/de/todesbaum/jsite/application/Project.java index 36fff55..484de85 100644 --- a/src/main/java/de/todesbaum/jsite/application/Project.java +++ b/src/main/java/de/todesbaum/jsite/application/Project.java @@ -60,6 +60,9 @@ public class Project implements Comparable { /** The edition to insert to. */ protected int edition; + /** Whether to always force inserts. */ + private boolean alwaysForceInserts; + /** Whether to ignore hidden directory. */ private boolean ignoreHiddenFiles; @@ -89,6 +92,7 @@ public class Project implements Comparable { localPath = project.localPath; indexFile = project.indexFile; lastInsertionTime = project.lastInsertionTime; + alwaysForceInserts = project.alwaysForceInserts; ignoreHiddenFiles = project.ignoreHiddenFiles; fileOptions = new HashMap(project.fileOptions); } @@ -252,6 +256,29 @@ public class Project implements Comparable { } /** + * Returns whether files for this project should always be inserted, even + * when unchanged. + * + * @return {@code true} to always force inserts on this project, + * {@code false} otherwise + */ + public boolean isAlwaysForceInsert() { + return alwaysForceInserts; + } + + /** + * Sets whether files for this project should always be inserted, even when + * unchanged. + * + * @param alwaysForceInsert + * {@code true} to always force inserts on this project, + * {@code false} otherwise + */ + public void setAlwaysForceInsert(boolean alwaysForceInsert) { + this.alwaysForceInserts = alwaysForceInsert; + } + + /** * Returns whether hidden files are ignored, i.e. not inserted. * * @return {@code true} if hidden files are not inserted, {@code false} -- 2.7.4