aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorGlen Mazza <gmazza@apache.org>2004-06-20 12:35:17 +0000
committerGlen Mazza <gmazza@apache.org>2004-06-20 12:35:17 +0000
commitd6fc7d07d23209f2416a674e5208ae53f070ae26 (patch)
treeffd46f9672c76e5b581fed77338ec0d1d8632366 /examples
parentb638342ab96a6d344aab5fd9653ca24e29d90424 (diff)
downloadxmlgraphics-fop-d6fc7d07d23209f2416a674e5208ae53f070ae26.tar.gz
xmlgraphics-fop-d6fc7d07d23209f2416a674e5208ae53f070ae26.zip
1.) Removed the get/setLogger methods from Driver, obsolete with Commons-Logging.
2.) Updated examples and documentation. 3.) Added a -v option to show version of FOP being used. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197740 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'examples')
-rw-r--r--examples/embedding/java/embedding/ExampleDOM2PDF.java14
-rw-r--r--examples/embedding/java/embedding/ExampleFO2PDF.java14
-rw-r--r--examples/embedding/java/embedding/ExampleObj2PDF.java15
-rw-r--r--examples/embedding/java/embedding/ExampleXML2PDF.java6
4 files changed, 11 insertions, 38 deletions
diff --git a/examples/embedding/java/embedding/ExampleDOM2PDF.java b/examples/embedding/java/embedding/ExampleDOM2PDF.java
index ab02e6607..5531cc252 100644
--- a/examples/embedding/java/embedding/ExampleDOM2PDF.java
+++ b/examples/embedding/java/embedding/ExampleDOM2PDF.java
@@ -18,12 +18,10 @@
package embedding;
-//Java
+// Java
import java.io.File;
import java.io.IOException;
import java.io.OutputStream;
-
-//JAXP
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.DocumentBuilder;
@@ -33,10 +31,7 @@ import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.Text;
-// Commons-Logging
-import org.apache.commons.logging.impl.SimpleLog;
-
-//FOP
+// FOP
import org.apache.fop.apps.Driver;
import org.apache.fop.apps.FOPException;
@@ -61,10 +56,7 @@ public class ExampleDOM2PDF {
// Construct driver
Driver driver = new Driver();
- // Setup logger
- SimpleLog logger = new SimpleLog("log");
- logger.setLevel(SimpleLog.LOG_LEVEL_INFO);
- driver.setLogger(logger);
+ // Setup driver
driver.initialize();
// Setup Renderer (output format)
diff --git a/examples/embedding/java/embedding/ExampleFO2PDF.java b/examples/embedding/java/embedding/ExampleFO2PDF.java
index be8cd7822..6d7a7c564 100644
--- a/examples/embedding/java/embedding/ExampleFO2PDF.java
+++ b/examples/embedding/java/embedding/ExampleFO2PDF.java
@@ -18,19 +18,16 @@
package embedding;
-//Java
+// Java
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
-//SAX
+// SAX
import org.xml.sax.InputSource;
-// Commons-Logging
-import org.apache.commons.logging.impl.SimpleLog;
-
-//FOP
+// FOP
import org.apache.fop.apps.Driver;
import org.apache.fop.apps.FOPException;
@@ -51,10 +48,7 @@ public class ExampleFO2PDF {
// Construct driver
Driver driver = new Driver();
- // Setup logger
- SimpleLog logger = new SimpleLog("log");
- logger.setLevel(SimpleLog.LOG_LEVEL_INFO);
- driver.setLogger(logger);
+ // Setup driver
driver.initialize();
// Setup Renderer (output format)
diff --git a/examples/embedding/java/embedding/ExampleObj2PDF.java b/examples/embedding/java/embedding/ExampleObj2PDF.java
index 313faee43..ff2419ff3 100644
--- a/examples/embedding/java/embedding/ExampleObj2PDF.java
+++ b/examples/embedding/java/embedding/ExampleObj2PDF.java
@@ -18,12 +18,12 @@
package embedding;
-//Java
+// Java
import java.io.File;
import java.io.OutputStream;
import java.io.IOException;
-//JAXP
+// JAXP
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.TransformerException;
@@ -32,13 +32,9 @@ import javax.xml.transform.Result;
import javax.xml.transform.stream.StreamSource;
import javax.xml.transform.sax.SAXResult;
-// Commons-Logging
-import org.apache.commons.logging.impl.SimpleLog;
-
-//FOP
+// FOP
import org.apache.fop.apps.Driver;
import org.apache.fop.apps.FOPException;
-
import embedding.model.ProjectTeam;
/**
@@ -62,10 +58,7 @@ public class ExampleObj2PDF {
// Construct driver
Driver driver = new Driver();
- // Setup logger
- SimpleLog logger = new SimpleLog("log");
- logger.setLevel(SimpleLog.LOG_LEVEL_INFO);
- driver.setLogger(logger);
+ // Setup driver
driver.initialize();
// Setup Renderer (output format)
diff --git a/examples/embedding/java/embedding/ExampleXML2PDF.java b/examples/embedding/java/embedding/ExampleXML2PDF.java
index 60cdd12ef..bb16b6528 100644
--- a/examples/embedding/java/embedding/ExampleXML2PDF.java
+++ b/examples/embedding/java/embedding/ExampleXML2PDF.java
@@ -32,9 +32,6 @@ import javax.xml.transform.Result;
import javax.xml.transform.stream.StreamSource;
import javax.xml.transform.sax.SAXResult;
-// Commons-Logging
-import org.apache.commons.logging.impl.SimpleLog;
-
//FOP
import org.apache.fop.apps.Driver;
import org.apache.fop.apps.FOPException;
@@ -74,9 +71,6 @@ public class ExampleXML2PDF {
Driver driver = new Driver();
// Setup logger
- SimpleLog logger = new SimpleLog("log");
- logger.setLevel(SimpleLog.LOG_LEVEL_INFO);
- driver.setLogger(logger);
driver.initialize();
// Setup Renderer (output format)