2 * Copyright 2005 the original author or authors.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 package org.wamblee.crawler.kiss.main;
20 * Access to system properties for the crawler.
22 * @author Erik Brakkee
24 public final class SystemProperties {
26 private static final String DEBUG_PROPERTY = "kiss.debug";
28 private static final String NO_PROGRAM_DETAILS = "kiss.nodetails";
30 private static final String DISABLE_RECORD = "kiss.norecord";
33 * Disabled constructor.
36 private SystemProperties() {
41 * Determines if the system is run in debug mode. When in debug mode, less
42 * extensive crawling is done.
44 * @return True iff we are running in debug mode.
46 public static boolean isDebugMode() {
47 return System.getProperties().getProperty(DEBUG_PROPERTY) != null;
51 * Determines if no program details are required.
53 * @return True iff no program details are required.
55 public static boolean isNoProgramDetailsRequired() {
56 return System.getProperties().getProperty(NO_PROGRAM_DETAILS) != null;
60 * Determines if recording is disabled.
62 * @return True iff no recording should be done.
64 public static boolean isRecordDisabled() {
65 return System.getProperties().getProperty(DISABLE_RECORD) != null;