aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/pdf
diff options
context:
space:
mode:
authorSimon Pepping <spepping@apache.org>2004-07-09 17:27:12 +0000
committerSimon Pepping <spepping@apache.org>2004-07-09 17:27:12 +0000
commitd04908a05ef64a2850289f6817125bd8a02c9088 (patch)
treed061c12afadde065aacd2f067490e7af033b6bc9 /src/java/org/apache/fop/pdf
parentf7ebe087cfc59cf9ff28e7f458e2e4f21f9770e9 (diff)
downloadxmlgraphics-fop-d04908a05ef64a2850289f6817125bd8a02c9088.tar.gz
xmlgraphics-fop-d04908a05ef64a2850289f6817125bd8a02c9088.zip
Implementing user configuration file.
Adding debug logging for user configuration, user PDF filters and user fonts. Adding reporting of mime type to renderers. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197774 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/pdf')
-rw-r--r--src/java/org/apache/fop/pdf/PDFFilterList.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/java/org/apache/fop/pdf/PDFFilterList.java b/src/java/org/apache/fop/pdf/PDFFilterList.java
index 946e10dc7..499bafc06 100644
--- a/src/java/org/apache/fop/pdf/PDFFilterList.java
+++ b/src/java/org/apache/fop/pdf/PDFFilterList.java
@@ -23,6 +23,11 @@ import java.io.OutputStream;
import java.util.List;
import java.util.Map;
+// commons logging
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+// Avalon
import org.apache.avalon.framework.configuration.Configuration;
import org.apache.avalon.framework.configuration.ConfigurationException;
@@ -48,6 +53,11 @@ public class PDFFilterList {
private boolean ignoreASCIIFilters = false;
/**
+ * logging instance
+ */
+ protected static Log logger = LogFactory.getLog("org.apache.fop.render");
+
+ /**
* Default constructor.
* <p>
* The flag for ignoring ASCII filters defaults to false.
@@ -276,6 +286,22 @@ public class PDFFilterList {
if (type == null) {
type = PDFFilterList.DEFAULT_FILTER;
}
+
+ if (!filterList.isEmpty() && logger.isDebugEnabled()) {
+ StringBuffer debug = new StringBuffer("Adding PDF filter");
+ if (filterList.size() != 1) {
+ debug.append("s");
+ }
+ debug.append(" for type ").append(type).append(": ");
+ for (int j = 0; j < filterList.size(); j++) {
+ if (j != 0) {
+ debug.append(", ");
+ }
+ debug.append(filterList.get(j));
+ }
+ logger.debug(debug.toString());
+ }
+
if (filterMap.get(type) != null) {
throw new ConfigurationException("A filterList of type '"
+ type + "' has already been defined");