jaxp/src/com/sun/org/apache/xml/internal/serializer/XSLOutputAttributes.java
author lana
Tue, 18 Mar 2014 17:49:48 -0700
changeset 23377 2af1ddf102a4
parent 12457 c348e06f0e82
child 24888 2e493ac78624
permissions -rw-r--r--
Merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6
7f561c08de6b Initial load
duke
parents:
diff changeset
     1
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
     2
 * reserved comment block
7f561c08de6b Initial load
duke
parents:
diff changeset
     3
 * DO NOT REMOVE OR ALTER!
7f561c08de6b Initial load
duke
parents:
diff changeset
     4
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
     5
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
     6
 * Copyright 2003-2004 The Apache Software Foundation.
7f561c08de6b Initial load
duke
parents:
diff changeset
     7
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
     8
 * Licensed under the Apache License, Version 2.0 (the "License");
7f561c08de6b Initial load
duke
parents:
diff changeset
     9
 * you may not use this file except in compliance with the License.
7f561c08de6b Initial load
duke
parents:
diff changeset
    10
 * You may obtain a copy of the License at
7f561c08de6b Initial load
duke
parents:
diff changeset
    11
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    12
 *     http://www.apache.org/licenses/LICENSE-2.0
7f561c08de6b Initial load
duke
parents:
diff changeset
    13
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    14
 * Unless required by applicable law or agreed to in writing, software
7f561c08de6b Initial load
duke
parents:
diff changeset
    15
 * distributed under the License is distributed on an "AS IS" BASIS,
7f561c08de6b Initial load
duke
parents:
diff changeset
    16
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
7f561c08de6b Initial load
duke
parents:
diff changeset
    17
 * See the License for the specific language governing permissions and
7f561c08de6b Initial load
duke
parents:
diff changeset
    18
 * limitations under the License.
7f561c08de6b Initial load
duke
parents:
diff changeset
    19
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
    20
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
    21
 * $Id: XSLOutputAttributes.java,v 1.2.4.1 2005/09/15 08:15:32 suresh_emailid Exp $
7f561c08de6b Initial load
duke
parents:
diff changeset
    22
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
    23
package com.sun.org.apache.xml.internal.serializer;
7f561c08de6b Initial load
duke
parents:
diff changeset
    24
7f561c08de6b Initial load
duke
parents:
diff changeset
    25
import java.util.Vector;
7f561c08de6b Initial load
duke
parents:
diff changeset
    26
7f561c08de6b Initial load
duke
parents:
diff changeset
    27
/**
7f561c08de6b Initial load
duke
parents:
diff changeset
    28
 * This interface has methods associated with the XSLT xsl:output attribues
7f561c08de6b Initial load
duke
parents:
diff changeset
    29
 * specified in the stylesheet that effect the format of the document output.
7f561c08de6b Initial load
duke
parents:
diff changeset
    30
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    31
 * In an XSLT stylesheet these attributes appear for example as:
7f561c08de6b Initial load
duke
parents:
diff changeset
    32
 * <pre>
7f561c08de6b Initial load
duke
parents:
diff changeset
    33
 * <xsl:output method="xml" omit-xml-declaration="no" indent="yes"/>
7f561c08de6b Initial load
duke
parents:
diff changeset
    34
 * </pre>
7f561c08de6b Initial load
duke
parents:
diff changeset
    35
 * The xsl:output attributes covered in this interface are:
7f561c08de6b Initial load
duke
parents:
diff changeset
    36
 * <pre>
7f561c08de6b Initial load
duke
parents:
diff changeset
    37
 * version
7f561c08de6b Initial load
duke
parents:
diff changeset
    38
 * encoding
7f561c08de6b Initial load
duke
parents:
diff changeset
    39
 * omit-xml-declarations
7f561c08de6b Initial load
duke
parents:
diff changeset
    40
 * standalone
7f561c08de6b Initial load
duke
parents:
diff changeset
    41
 * doctype-public
7f561c08de6b Initial load
duke
parents:
diff changeset
    42
 * doctype-system
7f561c08de6b Initial load
duke
parents:
diff changeset
    43
 * cdata-section-elements
7f561c08de6b Initial load
duke
parents:
diff changeset
    44
 * indent
7f561c08de6b Initial load
duke
parents:
diff changeset
    45
 * media-type
7f561c08de6b Initial load
duke
parents:
diff changeset
    46
 * </pre>
7f561c08de6b Initial load
duke
parents:
diff changeset
    47
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    48
 * The one attribute not covered in this interface is <code>method</code> as
7f561c08de6b Initial load
duke
parents:
diff changeset
    49
 * this value is implicitly chosen by the serializer that is created, for
7f561c08de6b Initial load
duke
parents:
diff changeset
    50
 * example ToXMLStream vs. ToHTMLStream or another one.
7f561c08de6b Initial load
duke
parents:
diff changeset
    51
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    52
 * This interface is only used internally within Xalan.
7f561c08de6b Initial load
duke
parents:
diff changeset
    53
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    54
 * @xsl.usage internal
7f561c08de6b Initial load
duke
parents:
diff changeset
    55
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
    56
interface XSLOutputAttributes
7f561c08de6b Initial load
duke
parents:
diff changeset
    57
{
7f561c08de6b Initial load
duke
parents:
diff changeset
    58
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    59
     * Returns the previously set value of the value to be used as the public
7f561c08de6b Initial load
duke
parents:
diff changeset
    60
     * identifier in the document type declaration (DTD).
7f561c08de6b Initial load
duke
parents:
diff changeset
    61
     *
7f561c08de6b Initial load
duke
parents:
diff changeset
    62
     *@return the public identifier to be used in the DOCTYPE declaration in the
7f561c08de6b Initial load
duke
parents:
diff changeset
    63
     * output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
    64
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    65
    public String getDoctypePublic();
7f561c08de6b Initial load
duke
parents:
diff changeset
    66
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    67
     * Returns the previously set value of the value to be used
7f561c08de6b Initial load
duke
parents:
diff changeset
    68
     * as the system identifier in the document type declaration (DTD).
7f561c08de6b Initial load
duke
parents:
diff changeset
    69
     * @return the system identifier to be used in the DOCTYPE declaration in
7f561c08de6b Initial load
duke
parents:
diff changeset
    70
     * the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
    71
     *
7f561c08de6b Initial load
duke
parents:
diff changeset
    72
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    73
    public String getDoctypeSystem();
7f561c08de6b Initial load
duke
parents:
diff changeset
    74
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    75
     * @return the character encoding to be used in the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
    76
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    77
    public String getEncoding();
7f561c08de6b Initial load
duke
parents:
diff changeset
    78
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    79
         * @return true if the output document should be indented to visually
7f561c08de6b Initial load
duke
parents:
diff changeset
    80
         * indicate its structure.
7f561c08de6b Initial load
duke
parents:
diff changeset
    81
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    82
    public boolean getIndent();
7f561c08de6b Initial load
duke
parents:
diff changeset
    83
7f561c08de6b Initial load
duke
parents:
diff changeset
    84
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    85
     * @return the number of spaces to indent for each indentation level.
7f561c08de6b Initial load
duke
parents:
diff changeset
    86
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    87
    public int getIndentAmount();
7f561c08de6b Initial load
duke
parents:
diff changeset
    88
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    89
     * @return the mediatype the media-type or MIME type associated with the
7f561c08de6b Initial load
duke
parents:
diff changeset
    90
     * output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
    91
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    92
    public String getMediaType();
7f561c08de6b Initial load
duke
parents:
diff changeset
    93
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    94
     * @return true if the XML declaration is to be omitted from the output
7f561c08de6b Initial load
duke
parents:
diff changeset
    95
     * document.
7f561c08de6b Initial load
duke
parents:
diff changeset
    96
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
    97
    public boolean getOmitXMLDeclaration();
7f561c08de6b Initial load
duke
parents:
diff changeset
    98
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    99
      * @return a value of "yes" if the <code>standalone</code> delaration is to
7f561c08de6b Initial load
duke
parents:
diff changeset
   100
      * be included in the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   101
      */
7f561c08de6b Initial load
duke
parents:
diff changeset
   102
    public String getStandalone();
7f561c08de6b Initial load
duke
parents:
diff changeset
   103
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   104
     * @return the version of the output format.
7f561c08de6b Initial load
duke
parents:
diff changeset
   105
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   106
    public String getVersion();
7f561c08de6b Initial load
duke
parents:
diff changeset
   107
7f561c08de6b Initial load
duke
parents:
diff changeset
   108
7f561c08de6b Initial load
duke
parents:
diff changeset
   109
7f561c08de6b Initial load
duke
parents:
diff changeset
   110
7f561c08de6b Initial load
duke
parents:
diff changeset
   111
7f561c08de6b Initial load
duke
parents:
diff changeset
   112
7f561c08de6b Initial load
duke
parents:
diff changeset
   113
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   114
     * Sets the value coming from the xsl:output cdata-section-elements
7f561c08de6b Initial load
duke
parents:
diff changeset
   115
     * stylesheet property.
7f561c08de6b Initial load
duke
parents:
diff changeset
   116
     *
7f561c08de6b Initial load
duke
parents:
diff changeset
   117
     * This sets the elements whose text elements are to be output as CDATA
7f561c08de6b Initial load
duke
parents:
diff changeset
   118
     * sections.
7f561c08de6b Initial load
duke
parents:
diff changeset
   119
     * @param URI_and_localNames pairs of namespace URI and local names that
7f561c08de6b Initial load
duke
parents:
diff changeset
   120
     * identify elements whose text elements are to be output as CDATA sections.
7f561c08de6b Initial load
duke
parents:
diff changeset
   121
     * The namespace of the local element must be the given URI to match. The
7f561c08de6b Initial load
duke
parents:
diff changeset
   122
     * qName is not given because the prefix does not matter, only the namespace
7f561c08de6b Initial load
duke
parents:
diff changeset
   123
     * URI to which that prefix would map matters, so the prefix itself is not
7f561c08de6b Initial load
duke
parents:
diff changeset
   124
     * relevant in specifying which elements have their text to be output as
7f561c08de6b Initial load
duke
parents:
diff changeset
   125
     * CDATA sections.
7f561c08de6b Initial load
duke
parents:
diff changeset
   126
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   127
    public void setCdataSectionElements(Vector URI_and_localNames);
7f561c08de6b Initial load
duke
parents:
diff changeset
   128
7f561c08de6b Initial load
duke
parents:
diff changeset
   129
    /** Set the value coming from the xsl:output doctype-public and doctype-system stylesheet properties
7f561c08de6b Initial load
duke
parents:
diff changeset
   130
     * @param system the system identifier to be used in the DOCTYPE declaration
7f561c08de6b Initial load
duke
parents:
diff changeset
   131
     * in the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   132
     * @param pub the public identifier to be used in the DOCTYPE declaration in
7f561c08de6b Initial load
duke
parents:
diff changeset
   133
     * the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   134
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   135
    public void setDoctype(String system, String pub);
7f561c08de6b Initial load
duke
parents:
diff changeset
   136
7f561c08de6b Initial load
duke
parents:
diff changeset
   137
    /** Set the value coming from the xsl:output doctype-public stylesheet attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   138
      * @param doctype the public identifier to be used in the DOCTYPE
7f561c08de6b Initial load
duke
parents:
diff changeset
   139
      * declaration in the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   140
      */
7f561c08de6b Initial load
duke
parents:
diff changeset
   141
    public void setDoctypePublic(String doctype);
7f561c08de6b Initial load
duke
parents:
diff changeset
   142
    /** Set the value coming from the xsl:output doctype-system stylesheet attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   143
      * @param doctype the system identifier to be used in the DOCTYPE
7f561c08de6b Initial load
duke
parents:
diff changeset
   144
      * declaration in the output document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   145
      */
7f561c08de6b Initial load
duke
parents:
diff changeset
   146
    public void setDoctypeSystem(String doctype);
7f561c08de6b Initial load
duke
parents:
diff changeset
   147
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   148
     * Sets the character encoding coming from the xsl:output encoding stylesheet attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   149
     * @param encoding the character encoding
7f561c08de6b Initial load
duke
parents:
diff changeset
   150
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   151
    public void setEncoding(String encoding);
7f561c08de6b Initial load
duke
parents:
diff changeset
   152
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   153
     * Sets the value coming from the xsl:output indent stylesheet
7f561c08de6b Initial load
duke
parents:
diff changeset
   154
     * attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   155
     * @param indent true if the output document should be indented to visually
7f561c08de6b Initial load
duke
parents:
diff changeset
   156
     * indicate its structure.
7f561c08de6b Initial load
duke
parents:
diff changeset
   157
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   158
    public void setIndent(boolean indent);
7f561c08de6b Initial load
duke
parents:
diff changeset
   159
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   160
     * Sets the value coming from the xsl:output media-type stylesheet attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   161
     * @param mediatype the media-type or MIME type associated with the output
7f561c08de6b Initial load
duke
parents:
diff changeset
   162
     * document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   163
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   164
    public void setMediaType(String mediatype);
7f561c08de6b Initial load
duke
parents:
diff changeset
   165
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   166
     * Sets the value coming from the xsl:output omit-xml-declaration stylesheet attribute
7f561c08de6b Initial load
duke
parents:
diff changeset
   167
     * @param b true if the XML declaration is to be omitted from the output
7f561c08de6b Initial load
duke
parents:
diff changeset
   168
     * document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   169
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   170
    public void setOmitXMLDeclaration(boolean b);
7f561c08de6b Initial load
duke
parents:
diff changeset
   171
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   172
     * Sets the value coming from the xsl:output standalone stylesheet attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   173
     * @param standalone a value of "yes" indicates that the
7f561c08de6b Initial load
duke
parents:
diff changeset
   174
     * <code>standalone</code> delaration is to be included in the output
7f561c08de6b Initial load
duke
parents:
diff changeset
   175
     * document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   176
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   177
    public void setStandalone(String standalone);
7f561c08de6b Initial load
duke
parents:
diff changeset
   178
    /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   179
     * Sets the value coming from the xsl:output version attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   180
     * @param version the version of the output format.
7f561c08de6b Initial load
duke
parents:
diff changeset
   181
     */
7f561c08de6b Initial load
duke
parents:
diff changeset
   182
    public void setVersion(String version);
7f561c08de6b Initial load
duke
parents:
diff changeset
   183
7f561c08de6b Initial load
duke
parents:
diff changeset
   184
}