changeset 5244:98b9cd9ee0fc

[JAVADOC/DOC] RT-30851 FXMLLoader has many undocumented fields
author Martin Sladecek <martin.sladecek@oracle.com>
date Thu, 03 Oct 2013 13:49:18 +0200
parents 5677ce5e6af3
children b182b0b07282
files modules/fxml/src/main/docs/javafx/fxml/doc-files/introduction_to_fxml.html modules/fxml/src/main/java/javafx/fxml/FXMLLoader.java
diffstat 2 files changed, 116 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/modules/fxml/src/main/docs/javafx/fxml/doc-files/introduction_to_fxml.html	Thu Oct 03 09:09:01 2013 +0200
+++ b/modules/fxml/src/main/docs/javafx/fxml/doc-files/introduction_to_fxml.html	Thu Oct 03 13:49:18 2013 +0200
@@ -242,6 +242,10 @@
 
 <p><span class="code">&lt;fx:include&gt;</span> also supports attributes for specifying the name of the resource bundle that should be used to localize the included content, as well as the character set used to encode the source file. Resource resolution is discussed in a later section.</p>
 
+<pre class="code">
+&lt;fx:include source="<span class="variable">filename</span>" resources="<span class="variable">resource_file</span>" charset="utf-8"/&gt;
+</pre>
+
 <h4><a name="constant_elements">&lt;fx:constant&gt;</a></h4>
 <p><assert id="constant" group="instance_declarations">The <span class="code">&lt;fx:constant&gt;</span> element creates a reference to a class constant.</assert> For example, the following markup sets the value of the "minWidth" property of a<span class="code">Button</span> instance to the value of the <span class="code">NEGATIVE_INFINITY</span> constant defined by the <span class="code">java.lang.Double</span> class:</p>
 
@@ -766,7 +770,7 @@
 &lt;?import javafx.scene.layout.*?&gt;
 
 &lt;VBox xmlns:fx="http://javafx.com/fxml"&gt;
-    &lt;fx:script source="example.js"/&gt;
+    &lt;fx:script source="example.js" charset="cp1252"/&gt;
 
     &lt;children&gt;
         &lt;Button text="Click Me!" onAction="handleButtonAction(event);"/&gt;
--- a/modules/fxml/src/main/java/javafx/fxml/FXMLLoader.java	Thu Oct 03 09:09:01 2013 +0200
+++ b/modules/fxml/src/main/java/javafx/fxml/FXMLLoader.java	Thu Oct 03 13:49:18 2013 +0200
@@ -1769,108 +1769,219 @@
 
     private static final Pattern extraneousWhitespacePattern = Pattern.compile("\\s+");
 
+    /**
+     * The character set used when character set is not explicitly specified
+     */
     public static final String DEFAULT_CHARSET_NAME = "UTF-8";
 
+    /**
+     * The tag name of language processing instruction
+     */
     public static final String LANGUAGE_PROCESSING_INSTRUCTION = "language";
+    /**
+     * The tag name of import processing instruction
+     */
     public static final String IMPORT_PROCESSING_INSTRUCTION = "import";
 
+    /**
+     * Prefix of 'fx' namespace
+     */
     public static final String FX_NAMESPACE_PREFIX = "fx";
+    /**
+     * The name of fx:controller attribute of a root
+     */
     public static final String FX_CONTROLLER_ATTRIBUTE = "controller";
+    /**
+     * The name of fx:id attribute
+     */
     public static final String FX_ID_ATTRIBUTE = "id";
+    /**
+     * The name of fx:value attribute
+     */
     public static final String FX_VALUE_ATTRIBUTE = "value";
     /**
+     * The tag name of 'fx:constant'
      * @since JavaFX 2.2
      */
     public static final String FX_CONSTANT_ATTRIBUTE = "constant";
+    /**
+     * The name of 'fx:factory' attribute
+     */
     public static final String FX_FACTORY_ATTRIBUTE = "factory";
 
+    /**
+     * The tag name of &lt;fx:include&gt;
+     */
     public static final String INCLUDE_TAG = "include";
+    /**
+     * &lt;fx:include&gt; 'source' attribute
+     */
     public static final String INCLUDE_SOURCE_ATTRIBUTE = "source";
+    /**
+     * &lt;fx:include&gt; 'resources' attribute
+     */
     public static final String INCLUDE_RESOURCES_ATTRIBUTE = "resources";
+    /**
+     * &lt;fx:include&gt; 'charset' attribute
+     */
     public static final String INCLUDE_CHARSET_ATTRIBUTE = "charset";
 
+    /**
+     * The tag name of &lt;fx:script&gt;
+     */
     public static final String SCRIPT_TAG = "script";
+    /**
+     * &lt;fx:script&gt; 'source' attribute
+     */
     public static final String SCRIPT_SOURCE_ATTRIBUTE = "source";
+    /**
+     * &lt;fx:script&gt; 'charset' attribute
+     */
     public static final String SCRIPT_CHARSET_ATTRIBUTE = "charset";
 
+    /**
+     * The tag name of &lt;fx:define&gt;
+     */
     public static final String DEFINE_TAG = "define";
 
+    /**
+     * The tag name of &lt;fx:reference&gt;
+     */
     public static final String REFERENCE_TAG = "reference";
+    /**
+     * &ltfx:reference&gt 'source' attribute
+     */
     public static final String REFERENCE_SOURCE_ATTRIBUTE = "source";
 
     /**
+     * The tag name of &lt;fx:root&gt;
      * @since JavaFX 2.2
      */
     public static final String ROOT_TAG = "root";
     /**
+     * &lt;fx:root&gt; 'type' attribute
      * @since JavaFX 2.2
      */
     public static final String ROOT_TYPE_ATTRIBUTE = "type";
 
+    /**
+     * The tag name of &lt;fx:copy&gt;
+     */
     public static final String COPY_TAG = "copy";
+    /**
+     * &lt;fx:copy&gt; 'source' attribute
+     */
     public static final String COPY_SOURCE_ATTRIBUTE = "source";
 
+    /**
+     * The prefix of event handler attributes
+     */
     public static final String EVENT_HANDLER_PREFIX = "on";
+    /**
+     * The name of the Event object in event handler scripts
+     */
     public static final String EVENT_KEY = "event";
+    /**
+     * Suffix for property change/invalidation handlers
+     */
     public static final String CHANGE_EVENT_HANDLER_SUFFIX = "Change";
     private static final String COLLECTION_HANDLER_NAME = EVENT_HANDLER_PREFIX + CHANGE_EVENT_HANDLER_SUFFIX;
 
+    /**
+     * Value that represents 'null'
+     */
     public static final String NULL_KEYWORD = "null";
 
     /**
+     * Escape prefix for escaping special characters inside attribute values.
+     * Serves as an escape for {@link #ESCAPE_PREFIX}, {@link #RELATIVE_PATH_PREFIX},
+     * {@link #RESOURCE_KEY_PREFIX, {@link #EXPRESSION_PREFIX}, {@link #BI_DIRECTIONAL_BINDING_PREFIX}
      * @since JavaFX 2.1
      */
     public static final String ESCAPE_PREFIX = "\\";
+    /**
+     * Prefix for relative location resultion
+     */
     public static final String RELATIVE_PATH_PREFIX = "@";
+    /**
+     * Prefix for resource resolution
+     */
     public static final String RESOURCE_KEY_PREFIX = "%";
+    /**
+     * Prefix for (variable) expression resolution
+     */
     public static final String EXPRESSION_PREFIX = "$";
+    /**
+     * Prefix for binding expression resolution
+     */
     public static final String BINDING_EXPRESSION_PREFIX = "${";
+    /**
+     * Suffix for binding expression resolution
+     */
     public static final String BINDING_EXPRESSION_SUFFIX = "}";
 
     /**
+     * Prefix for bidirectional-binding expression resolution
      * @since JavaFX 2.1
      */
     public static final String BI_DIRECTIONAL_BINDING_PREFIX = "#{";
     /**
+     * Suffix for bidirectional-binding expression resolution
      * @since JavaFX 2.1
      */
     public static final String BI_DIRECTIONAL_BINDING_SUFFIX = "}";
 
     /**
+     * Delimiter for arrays as values
      * @since JavaFX 2.1
      */
     public static final String ARRAY_COMPONENT_DELIMITER = ",";
 
     /**
+     * A key for location URL in namespace map
+     * @see #getNamespace()
      * @since JavaFX 2.2
      */
     public static final String LOCATION_KEY = "location";
     /**
+     * A key for ResourceBundle in namespace map
+     * @see #getNamespace()
      * @since JavaFX 2.2
      */
     public static final String RESOURCES_KEY = "resources";
 
+    /**
+     * Prefix for controller method resolution
+     */
     public static final String CONTROLLER_METHOD_PREFIX = "#";
     /**
+     * A key for controller in namespace map
+     * @see #getNamespace()
      * @since JavaFX 2.1
      */
     public static final String CONTROLLER_KEYWORD = "controller";
     /**
+     * A suffix for controllers of included fxml files.
+     * The full key is stored in namespace map.
+     * @see #getNamespace()
      * @since JavaFX 2.2
      */
     public static final String CONTROLLER_SUFFIX = "Controller";
 
     /**
+     * The name of initialize method
      * @since JavaFX 2.2
      */
     public static final String INITIALIZE_METHOD_NAME = "initialize";
 
     /**
+     * Contains the current javafx version
      * @since JavaFX 8.0
      */
     public static final String JAVAFX_VERSION;
 
     /**
+     * Contains the current fx namepsace version
      * @since JavaFX 8.0
      */
     public static final String FX_NAMESPACE_VERSION = "1";