1 /*
2 * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
3 * @LastModified: Nov 2017
4 */
5 /*
6 * Licensed to the Apache Software Foundation (ASF) under one or more
7 * contributor license agreements. See the NOTICE file distributed with
8 * this work for additional information regarding copyright ownership.
9 * The ASF licenses this file to You under the Apache License, Version 2.0
10 * (the "License"); you may not use this file except in compliance with
11 * the License. You may obtain a copy of the License at
12 *
13 * http://www.apache.org/licenses/LICENSE-2.0
14 *
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
20 */
21
22 package com.sun.org.apache.xalan.internal.xsltc.trax;
23
72 import javax.xml.transform.sax.SAXSource;
73 import javax.xml.transform.sax.SAXTransformerFactory;
74 import javax.xml.transform.sax.TemplatesHandler;
75 import javax.xml.transform.sax.TransformerHandler;
76 import javax.xml.transform.stax.*;
77 import javax.xml.transform.stream.StreamResult;
78 import javax.xml.transform.stream.StreamSource;
79 import jdk.xml.internal.JdkXmlFeatures;
80 import jdk.xml.internal.JdkXmlUtils;
81 import jdk.xml.internal.SecuritySupport;
82 import org.xml.sax.InputSource;
83 import org.xml.sax.XMLFilter;
84 import org.xml.sax.XMLReader;
85 import org.xml.sax.helpers.XMLReaderFactory;
86
87 /**
88 * Implementation of a JAXP1.1 TransformerFactory for Translets.
89 * @author G. Todd Miller
90 * @author Morten Jorgensen
91 * @author Santiago Pericas-Geertsen
92 */
93 @SuppressWarnings("deprecation") //org.xml.sax.helpers.XMLReaderFactory
94 public class TransformerFactoryImpl
95 extends SAXTransformerFactory implements SourceLoader, ErrorListener
96 {
97 // Public constants for attributes supported by the XSLTC TransformerFactory.
98 public final static String TRANSLET_NAME = "translet-name";
99 public final static String DESTINATION_DIRECTORY = "destination-directory";
100 public final static String PACKAGE_NAME = "package-name";
101 public final static String JAR_NAME = "jar-name";
102 public final static String GENERATE_TRANSLET = "generate-translet";
103 public final static String AUTO_TRANSLET = "auto-translet";
104 public final static String USE_CLASSPATH = "use-classpath";
105 public final static String DEBUG = "debug";
106 public final static String ENABLE_INLINING = "enable-inlining";
107 public final static String INDENT_NUMBER = "indent-number";
108
109 /**
110 * This error listener is used only for this factory and is not passed to
111 * the Templates or Transformer objects that we create.
|
1 /*
2 * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
3 */
4 /*
5 * Licensed to the Apache Software Foundation (ASF) under one or more
6 * contributor license agreements. See the NOTICE file distributed with
7 * this work for additional information regarding copyright ownership.
8 * The ASF licenses this file to You under the Apache License, Version 2.0
9 * (the "License"); you may not use this file except in compliance with
10 * the License. You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20
21 package com.sun.org.apache.xalan.internal.xsltc.trax;
22
71 import javax.xml.transform.sax.SAXSource;
72 import javax.xml.transform.sax.SAXTransformerFactory;
73 import javax.xml.transform.sax.TemplatesHandler;
74 import javax.xml.transform.sax.TransformerHandler;
75 import javax.xml.transform.stax.*;
76 import javax.xml.transform.stream.StreamResult;
77 import javax.xml.transform.stream.StreamSource;
78 import jdk.xml.internal.JdkXmlFeatures;
79 import jdk.xml.internal.JdkXmlUtils;
80 import jdk.xml.internal.SecuritySupport;
81 import org.xml.sax.InputSource;
82 import org.xml.sax.XMLFilter;
83 import org.xml.sax.XMLReader;
84 import org.xml.sax.helpers.XMLReaderFactory;
85
86 /**
87 * Implementation of a JAXP1.1 TransformerFactory for Translets.
88 * @author G. Todd Miller
89 * @author Morten Jorgensen
90 * @author Santiago Pericas-Geertsen
91 * @LastModified: Nov 2017
92 */
93 @SuppressWarnings("deprecation") //org.xml.sax.helpers.XMLReaderFactory
94 public class TransformerFactoryImpl
95 extends SAXTransformerFactory implements SourceLoader, ErrorListener
96 {
97 // Public constants for attributes supported by the XSLTC TransformerFactory.
98 public final static String TRANSLET_NAME = "translet-name";
99 public final static String DESTINATION_DIRECTORY = "destination-directory";
100 public final static String PACKAGE_NAME = "package-name";
101 public final static String JAR_NAME = "jar-name";
102 public final static String GENERATE_TRANSLET = "generate-translet";
103 public final static String AUTO_TRANSLET = "auto-translet";
104 public final static String USE_CLASSPATH = "use-classpath";
105 public final static String DEBUG = "debug";
106 public final static String ENABLE_INLINING = "enable-inlining";
107 public final static String INDENT_NUMBER = "indent-number";
108
109 /**
110 * This error listener is used only for this factory and is not passed to
111 * the Templates or Transformer objects that we create.
|