Class FormControl.Scriptable

    • Constructor Detail

      • Scriptable

        public Scriptable()
        construct a Scriptable
    • Method Detail

      • getName

        public java.lang.String getName()
        get my Name
        Specified by:
        getName in interface NamedDelegate
        Returns:
        the name of this scriptable
      • getID

        public java.lang.String getID()
        get my ID
        Specified by:
        getID in interface IdentifiedDelegate
        Returns:
        the id of this scriptable
      • get

        public java.lang.Object get​(java.lang.String propertyName)
        get the given property
        Specified by:
        get in interface Input
        Parameters:
        propertyName - - the name of the property to get
      • set

        public void set​(java.lang.String propertyName,
                        java.lang.Object value)
        set the given property to the given value
        Specified by:
        set in interface Input
        Overrides:
        set in class ScriptableDelegate
        Parameters:
        propertyName - - the property to set
        value - - the value to use
      • setAttribute

        public void setAttribute​(java.lang.String attributeName,
                                 java.lang.Object value)
        set the given attribute to the given value
        Specified by:
        setAttribute in interface Input
        Parameters:
        attributeName - - the name of the attribute to set
        value - - the value to use
      • click

        public void click()
                   throws java.io.IOException,
                          org.xml.sax.SAXException
        allow calling click for this control
        Specified by:
        click in interface Input
        Throws:
        java.io.IOException
        org.xml.sax.SAXException
      • blur

        public void blur()
        simulate blur
      • focus

        public void focus()
        simulate focus;
      • sendOnChangeEvent

        public void sendOnChangeEvent()
        allow firing a sendOnChangeEvent
        Specified by:
        sendOnChangeEvent in interface Input
      • get_element

        protected HTMLElement get_element()
        Returns:
        the _element
      • getAttribute

        public java.lang.String getAttribute​(java.lang.String attributeName)
        get the content of the given attribute
        Parameters:
        attributeName -
        Returns:
        the attribute as a string
      • removeAttribute

        public void removeAttribute​(java.lang.String attributeName)
        remove the given attribute
        Parameters:
        attributeName -
      • handleEvent

        public boolean handleEvent​(java.lang.String eventName)
        Description copied from class: ScriptableDelegate
        Executes the event Handler script for the specified event (such as onchange, onmousedown, onclick, onmouseup) if it is defined.
        Specified by:
        handleEvent in interface ScriptingEventHandler
        Overrides:
        handleEvent in class ScriptableDelegate
        Parameters:
        eventName - the name of the event for which a handler should be run.
        Returns:
        whether the event with the given name was handled