Interface StringSensor

All Superinterfaces:
X3DChildNode, X3DKeyDeviceSensorNode, X3DNode, X3DSensorNode
All Known Implementing Classes:
StringSensorObject

public interface StringSensor
extends X3DKeyDeviceSensorNode
StringSensor generates events as the user presses keys on the keyboard.

X3D node tooltip: [X3DKeyDeviceSensorNode] StringSensor generates events as the user presses keys on the keyboard. Browser support includes the notion of "keyboard focus". *


Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
See Also:
SAI Java Specification: TODO, X3D Abstract Specification: StringSensor, X3D Tooltips: StringSensor, X3D Scene Authoring Hints
  • Method Summary

    Modifier and Type Method Description
    boolean getDeletionAllowed()
    Provide boolean value from inputOutput SFBool field named deletionAllowed.
    boolean getEnabled()
    Provide boolean value from inputOutput SFBool field named enabled.
    java.lang.String getEnteredText()
    Provide String value from outputOnly SFString field named enteredText.
    java.lang.String getFinalText()
    Provide String value from outputOnly SFString field named finalText.
    boolean getIsActive()
    Provide boolean value from outputOnly SFBool field named isActive.
    X3DMetadataObject getMetadata()
    Provide X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.
    StringSensor setDeletionAllowed​(boolean newValue)
    Accessor method to assign boolean value to inputOutput SFBool field named deletionAllowed.
    StringSensor setEnabled​(boolean newValue)
    Accessor method to assign boolean value to inputOutput SFBool field named enabled.
    StringSensor setMetadata​(X3DMetadataObject newValue)
    Accessor method to assign X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.
  • Method Details

    • getDeletionAllowed

      boolean getDeletionAllowed()
      Provide boolean value from inputOutput SFBool field named deletionAllowed.

      Tooltip: If deletionAllowed is true, then previously entered character in enteredText can be removed. If deletionAllowed is false, then characters may only be added to the string.
      • Hint: deletion key is typically defined by local system.
      Returns:
      value of deletionAllowed field
    • setDeletionAllowed

      StringSensor setDeletionAllowed​(boolean newValue)
      Accessor method to assign boolean value to inputOutput SFBool field named deletionAllowed.

      Tooltip: If deletionAllowed is true, then previously entered character in enteredText can be removed. If deletionAllowed is false, then characters may only be added to the string.
      • Hint: deletion key is typically defined by local system.
      Parameters:
      newValue - is new value for the deletionAllowed field.
      Returns:
      StringSensor - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getEnabled

      boolean getEnabled()
      Provide boolean value from inputOutput SFBool field named enabled.

      Tooltip: Enables/disables node operation. *
      Specified by:
      getEnabled in interface X3DKeyDeviceSensorNode
      Specified by:
      getEnabled in interface X3DSensorNode
      Returns:
      value of enabled field
    • setEnabled

      StringSensor setEnabled​(boolean newValue)
      Accessor method to assign boolean value to inputOutput SFBool field named enabled.

      Tooltip: Enables/disables node operation. *
      Specified by:
      setEnabled in interface X3DKeyDeviceSensorNode
      Specified by:
      setEnabled in interface X3DSensorNode
      Parameters:
      newValue - is new value for the enabled field.
      Returns:
      StringSensor - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getEnteredText

      java.lang.String getEnteredText()
      Provide String value from outputOnly SFString field named enteredText.

      Tooltip: Events generated as character-producing keys are pressed on keyboard.
      • Warning: it is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.
      Returns:
      value of enteredText field
    • getFinalText

      java.lang.String getFinalText()
      Provide String value from outputOnly SFString field named finalText.

      Tooltip: Events generated when sequence of keystrokes matches keys in terminationText string when this condition occurs, enteredText is moved to finalText and enteredText is set to empty string.
      • Hint: termination key is typically defined by local system.
      • Warning: it is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.
      Returns:
      value of finalText field
    • getIsActive

      boolean getIsActive()
      Provide boolean value from outputOnly SFBool field named isActive.

      Tooltip: Select geometry by activating the pointing device (e.g. clicking the mouse) to generate isActive events. Output event isActive=true is sent when geometry is selected (e.g. when primary mouse button is pressed), output event isActive=false is sent when geometry is deselected (e.g. when primary mouse button is released).
      • Warning: it is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.
      Specified by:
      getIsActive in interface X3DKeyDeviceSensorNode
      Specified by:
      getIsActive in interface X3DSensorNode
      Returns:
      value of isActive field
    • getMetadata

      X3DMetadataObject getMetadata()
      Provide X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.
      Specified by:
      getMetadata in interface X3DChildNode
      Specified by:
      getMetadata in interface X3DKeyDeviceSensorNode
      Specified by:
      getMetadata in interface X3DNode
      Specified by:
      getMetadata in interface X3DSensorNode
      Returns:
      value of metadata field
      See Also:
      X3D Scene Authoring Hints: Metadata Nodes
    • setMetadata

      StringSensor setMetadata​(X3DMetadataObject newValue)
      Accessor method to assign X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.
      Specified by:
      setMetadata in interface X3DChildNode
      Specified by:
      setMetadata in interface X3DKeyDeviceSensorNode
      Specified by:
      setMetadata in interface X3DNode
      Specified by:
      setMetadata in interface X3DSensorNode
      Parameters:
      newValue - is new value for the metadata field.
      Returns:
      StringSensor - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
      See Also:
      X3D Scene Authoring Hints: Metadata Nodes