Package org.web3d.x3d.jsail.fields
Class SFNode
java.lang.Object
org.web3d.x3d.jsail.fields.X3DConcreteField
org.web3d.x3d.jsail.fields.SFNode
This utility class provides a concrete implementation corresponding to SFNode X3D field type.
Warning: this is an abstract interface that cannot be instantiated as a concrete object. Java programmers typically only need to use concrete objects provided by the
Package hint: This specification class is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI). SFNode specifies an X3D node; the default empty value of an uninitialized SFNode field is sometimes described as NULL.
Related field object:
Warning: this is an abstract interface that cannot be instantiated as a concrete object. Java programmers typically only need to use concrete objects provided by the
org.web3d.x3d.jsail
classes.
Package hint: This specification class is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI). SFNode specifies an X3D node; the default empty value of an uninitialized SFNode field is sometimes described as NULL.
Related field object:
MFNode
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final X3DNode
Default value for this field type is a null node.static final String
Default string value for this field type is "".static final String
String constant NAME provides name of this element: SFNodestatic final int
Default tuple size for this field type is 1 (i.e. number of component values making up a single-field SF object).Fields inherited from class org.web3d.x3d.jsail.fields.X3DConcreteField
validationResult
-
Constructor Summary
ConstructorDescriptionSFNode()
Constructor for SFNode performs value initialization.Constructor to copy an SFNode value as initial value for this new field object.Constructor for SFNode using a corresponding Java primitive org.web3d.x3d.sai.Core.X3DNode as new initial value. -
Method Summary
Modifier and TypeMethodDescriptionUtility method to clear all contained children including nodes, statements and comments (if any).Provides current value of the field as a Java primitive type.getValue()
Get the current value.final void
Initialization for SFNode applies default initial value.static final boolean
isArray()
Whether or not this field type is an array (false)boolean
Determine whether current value matches DEFAULT_VALUEApply an SFNode value to this field.void
Assign a new value to this field.toString()
Provides current value as a String.static String
Static utility method to provide String representation of a correctly typed input value.Methods inherited from class org.web3d.x3d.jsail.fields.X3DConcreteField
addX3DEventListener, getDefinition, getTupleSize, getValidationResult, isReadable, isWritable, removeX3DEventListener, setReadable, setWritable
-
Field Details
-
NAME
String constant NAME provides name of this element: SFNode- See Also:
-
DEFAULT_VALUE
Default value for this field type is a null node.- See Also:
-
DEFAULT_VALUE_STRING
Default string value for this field type is "".- See Also:
-
TUPLE_SIZE
public static final int TUPLE_SIZEDefault tuple size for this field type is 1 (i.e. number of component values making up a single-field SF object).- See Also:
-
-
Constructor Details
-
SFNode
public SFNode()Constructor for SFNode performs value initialization. -
SFNode
Constructor to copy an SFNode value as initial value for this new field object.- Parameters:
newValue
- The newValue to apply
-
SFNode
Constructor for SFNode using a corresponding Java primitive org.web3d.x3d.sai.Core.X3DNode as new initial value.- Parameters:
newValue
- is new value to assign setContainerFieldOverride(containerFieldName); // apply checksConcreteField#getTupleSize(String)
-
-
Method Details
-
isArray
public static final boolean isArray()Whether or not this field type is an array (false)- Returns:
- true if array type
-
initialize
public final void initialize()Initialization for SFNode applies default initial value.- Specified by:
initialize
in classX3DConcreteField
- See Also:
-
toString
-
getValue
-
getPrimitiveValue
Provides current value of the field as a Java primitive type.- Returns:
- current value
-
toString
-
setValue
-
setValue
-
clearChildren
-
isDefaultValue
public boolean isDefaultValue()Determine whether current value matches DEFAULT_VALUE- Returns:
- whether current value matches DEFAULT_VALUE
- See Also:
-