com.ibm.as400.util.html

Class BidiOrdering

  • All Implemented Interfaces:
    HTMLTagElement, java.io.Serializable


    public class BidiOrdering
    extends HTMLTagAttributes
    implements java.io.Serializable
    The BidiOrdering class represents an HTML tag used to alter the language and direction of text.

    Here is an example of a BidiOrdering tag:

      <bdo lang="he" dir="rtl">
      Some Hebrew Text.
      </bdo>
      

    The equivalent tag using XSL Formatting Objects looks like this:

      <fo:block-container writing-mode='rl'>
      <fo:block>Some Hebrew Text</fo:block>
      </fo:block-container>
      

    BidiOrdering objects generate the following events:

    • ElementEvent - The events fired are:
      • elementAdded
      • elementRemoved
    • PropertyChangeEvent
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor and Description
      BidiOrdering()
      Constructs a default BidiOrdering object.
      BidiOrdering(java.lang.String dir)
      Constructs a BidiOrdering object with the specified dir.
      BidiOrdering(java.lang.String lang, java.lang.String dir)
      Constructs a BidiOrdering object with the specified lang and dir.
    • Constructor Detail

      • BidiOrdering

        public BidiOrdering()
        Constructs a default BidiOrdering object.
      • BidiOrdering

        public BidiOrdering(java.lang.String dir)
        Constructs a BidiOrdering object with the specified dir.
        Parameters:
        dir - The direction of the text being displayed.
      • BidiOrdering

        public BidiOrdering(java.lang.String lang,
                    java.lang.String dir)
        Constructs a BidiOrdering object with the specified lang and dir.
        Parameters:
        lang - The language of the text.
        dir - The direction of text being displayed.
    • Method Detail

      • addItem

        public void addItem(HTMLTagElement data)
        Adds an HTMLTagElement to the list elements.
        Parameters:
        data - The data to re-order.
      • addItem

        public void addItem(java.lang.String data)
        Adds a String to the list of elements.
        Parameters:
        data - The data to re-order.
      • addItemElementListener

        public void addItemElementListener(ElementListener listener)
        Adds an ElementListener.
        Parameters:
        listener - The ElementListener.
      • getDirection

        public java.lang.String getDirection()
        Returns the direction of the text interpretation.
        Returns:
        The direction of the text.
      • getLanguage

        public java.lang.String getLanguage()
        Returns the language of the element.
        Returns:
        The language of the element.
      • getItems

        public java.util.Vector getItems()
        Returns the list of items.
        Returns:
        The list.
      • getTag

        public java.lang.String getTag()
        Returns the tag for the Bi-Directional Ordering.
        Specified by:
        getTag in interface HTMLTagElement
        Returns:
        The tag.
      • getFOTag

        public java.lang.String getFOTag()
        Returns the XSL formatting object's tag for the Bi-Directional Ordering. The language attribute is not supported in XSL-FO.
        Specified by:
        getFOTag in interface HTMLTagElement
        Returns:
        The tag.
      • isUseFO

        public boolean isUseFO()
        Returns if Formatting Object tags are outputted. The default value is false.
        Returns:
        true if the output generated is an XSL formatting object, false if the output generated is HTML.
      • removeItem

        public void removeItem(HTMLTagElement data)
        Removess an HTMLTagElement from the list.
        Parameters:
        data - The data to remove.
      • removeItemElementListener

        public void removeItemElementListener(ElementListener listener)
        Removes this ElementListener.
        Parameters:
        listener - The ElementListener.
      • setDirection

        public void setDirection(java.lang.String dir)
        Sets the direction of the text interpretation.
        Parameters:
        dir - The direction. One of the following constants defined in HTMLConstants: LTR or RTL.
        See Also:
        HTMLConstants
      • setLanguage

        public void setLanguage(java.lang.String lang)
        Sets the language of the input tag.
        Parameters:
        lang - The language. Example language tags include: en and en-US.
      • setUseFO

        public void setUseFO(boolean useFO)
        Sets if Formatting Object tags should be outputted. The default value is false.
        Parameters:
        useFO - - true if output generated is an XSL formatting object, false if the output generated is HTML.
      • toString

        public java.lang.String toString()
        Returns a String representation for the BidiOrdering tag.
        Overrides:
        toString in class java.lang.Object
        Returns:
        The tag.