Path: blob/aarch64-shenandoah-jdk8u272-b10/jaxp/src/javax/xml/transform/Result.java
32285 views
/*1* Copyright (c) 2000, 2005, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation. Oracle designates this7* particular file as subject to the "Classpath" exception as provided8* by Oracle in the LICENSE file that accompanied this code.9*10* This code is distributed in the hope that it will be useful, but WITHOUT11* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or12* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License13* version 2 for more details (a copy is included in the LICENSE file that14* accompanied this code).15*16* You should have received a copy of the GNU General Public License version17* 2 along with this work; if not, write to the Free Software Foundation,18* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.19*20* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA21* or visit www.oracle.com if you need additional information or have any22* questions.23*/2425package javax.xml.transform;2627/**28* <p>An object that implements this interface contains the information29* needed to build a transformation result tree.</p>30*31* @author <a href="[email protected]">Jeff Suttor</a>32*/33public interface Result {3435/**36* The name of the processing instruction that is sent if the37* result tree disables output escaping.38*39* <p>Normally, result tree serialization escapes & and < (and40* possibly other characters) when outputting text nodes.41* This ensures that the output is well-formed XML. However,42* it is sometimes convenient to be able to produce output that is43* almost, but not quite well-formed XML; for example,44* the output may include ill-formed sections that will45* be transformed into well-formed XML by a subsequent non-XML aware46* process. If a processing instruction is sent with this name,47* serialization should be output without any escaping. </p>48*49* <p>Result DOM trees may also have PI_DISABLE_OUTPUT_ESCAPING and50* PI_ENABLE_OUTPUT_ESCAPING inserted into the tree.</p>51*52* @see <a href="http://www.w3.org/TR/xslt#disable-output-escaping">disable-output-escaping in XSLT Specification</a>53*/54public static final String PI_DISABLE_OUTPUT_ESCAPING =55"javax.xml.transform.disable-output-escaping";5657/**58* The name of the processing instruction that is sent59* if the result tree enables output escaping at some point after having60* received a PI_DISABLE_OUTPUT_ESCAPING processing instruction.61*62* @see <a href="http://www.w3.org/TR/xslt#disable-output-escaping">disable-output-escaping in XSLT Specification</a>63*/64public static final String PI_ENABLE_OUTPUT_ESCAPING =65"javax.xml.transform.enable-output-escaping";6667/**68* Set the system identifier for this Result.69*70* <p>If the Result is not to be written to a file, the system identifier is optional.71* The application may still want to provide one, however, for use in error messages72* and warnings, or to resolve relative output identifiers.</p>73*74* @param systemId The system identifier as a URI string.75*/76public void setSystemId(String systemId);7778/**79* Get the system identifier that was set with setSystemId.80*81* @return The system identifier that was set with setSystemId,82* or null if setSystemId was not called.83*/84public String getSystemId();85}868788