Extensible 3D (X3D) language bindings
Part 2: Java
Annex B
(normative)
Abstract node interfaces
This annex provides the definition of the interface signature for each interface that represents the abstract node instance defined in IS0/IEC 19775-2 (see 2.[19775]).
See Table B.1 for the topics in this clause.
This annex describes all the known interfaces that represent abstract node types. It also defines the other types such as interfaces that represent fields scenes etc. The convention used is to provide the definition of the class using the Java language syntax as would be seen in a Java source file.
The naming convention used by to construct interfaces follows these rules:
addChildren
and removeChildren
methods of
the grouping node are left untouched.Extra convenience methods may be supplied by the interfaces on an as-desired basis.
public interface X3DAppearanceChildNode extends X3DNode { }
public interface X3DAppearanceNode extends X3DNode { }
public interface X3DAudioClipNode extends X3DTimeDependentNode, X3DUrlObject { public String getDescription(); public void setDescription(String str); public float getPitch(); public void setPitch(float pitch) throws InvalidFieldValueException; public double getDuration(); public getDuration(double time); }
public interface X3DBackgroundNode extends X3DBindableNode { public int getNumSkyAngle(); public void getSkyAngle(float[] angles); public void setSkyAngle(float[] angles); public int getNumGroundAngle(); public void getGroundAngle(float[] angle); public void setGroundAngle(float[] angle); public int getNumSkyColor(); public void getSkyColor(float[] colors); public void setSkyColor(float[] colors); public int getNumGroundColor(); public void getGroundColor(float[] color); public void setGroundColor(float[] color); }
public interface X3DBindableNode extends X3DChildNode { public void setBind(boolean enable); public boolean isBound(); public double getBindTime(); }
public interface X3DChildNode extends X3DNode { }
public interface X3DColorNode extends X3DGeometricPropertyNode { public int getNumColors(); public int getNumComponents(); public void setColor(float[] colors); public void getColor(float[] color); }
public interface X3DComposedGeometryNode extends X3DGeometryNode { public X3DNode getColor(); public void setColor(X3DColorNode node); public void setColor(X3DProtoInstance comp) throws InvalidFieldValueException; public X3DNode getCoord(); public void setCoord(X3DCoordinateNode node); public void setCoord(X3DProtoInstance node) throws InvalidFieldValueException; public X3DNode getTexCoord(); public void setTexCoord(X3DTextureCoordinateNode node); public void setTexCoord(X3DProtoInstance node) throws InvalidFieldValueException; public X3DNode getNormal(); public void setNormal(X3DNormalNode node); public void setNormal(X3DProtoInstance node) throws InvalidFieldValueException; public boolean getIsSolid(); public void setIsSolid(boolean solid) throws InvalidWritableFieldException; public boolean getIsCCW(); public void setIsCCW(boolean ccw); throws InvalidWritableFieldException; public boolean getColorPerVertex(); public void setColorPerVertex(boolean perVertex); throws InvalidWritableFieldException; public boolean getNormalPerVertex(); public void setNormalPerVertex(boolean perVertex); throws InvalidWritableFieldException; }
public interface X3DCoordinateNode extends X3DGeometricPropertyNode { public int getNumCoordinates(); public void setPoint(float[] points); public void getPoint(float[] points); }
public interface X3DDragSensorNode extends X3DPointingDeviceSensorNode { public void setAutoOffset(boolean newAutoOffset); public boolean getAutoOffset(); public void getTrackPoint(float[] point); }
public interface X3DEnvironmentalSensorNode extends X3DSensorNode { public double getEnterTime(); public double getExitTime(); public void getCenter(float[] pos); public void setCenter(float[] pos); public void getSize(float[] size); public void setSize(float[] size); }
public interface X3DFontStyleNode extends X3DNode { public int PLAIN_STYLE = java.awt.Font.PLAIN; public int ITALIC_STYLE = java.awt.Font.ITALIC; public int BOLD_STYLE = java.awt.Font.BOLD; public int BOLDITALIC_STYLE = java.awt.Font.BOLD + java.awt.Font.ITALIC; public int BEGIN_JUSTIFY = 1; public int END_JUSTIFY = 2; public int MIDDLE_JUSTIFY = 3; public int FIRST_JUSTIFY = 4; public Font getFont(); public int getHorizontalJustification(); public int getVerticalJustification(); public float getSpacing(); public float getSize(); public boolean isTopToBottom(); public boolean isLeftToRight(); }
public interface X3DGeometricPropertyNode extends X3DNode { }
public interface X3DGeometryNode extends X3DNode { }
public interface X3DGroupingNode extends X3DChildNode, X3DBoundedObject { public void getChildren(X3DNode[] nodes); public void setChildren(X3DNode[] kids) throws InvalidNodeException; public void addChildren(X3DNode[] added) throws InvalidNodeException; public void addChild(X3DNode added) throws InvalidNodeException; public void removeChildren(X3DNode[] removed) throws InvalidNodeException; public void removeChild(X3DNode removed) throws InvalidNodeException; public int getNumChildren(); }
public interface X3DInfoNode extends X3DChildNode { }
public interface X3DInterpolatorNode extends X3DChildNode { public void setFraction(float value); public int getNumKeys(); public void setKey(float[] keys); public void getKey(float[] keys); }
public interface X3DKeyDeviceSensorNode extends X3DSensorNode { }
public interface X3DLightNode extends X3DChildNode { public boolean getOn(); public void setOn(boolean state); public float getAmbientIntensity(); public void setAmbientIntensity(float intensity) throws InvalidFieldValueException; public void getColor(float[] color); public void setColor(float[] color) throws InvalidFieldValueException; public float getIntensity(); public void setIntensity(float newIntensity) throws InvalidFieldValueException; }
public interface X3DMaterialNode extends X3DAppearanceChildNode { }
public interface X3DNetworkSensorNode extends X3DSensorNode { }
public interface X3DNode extends X3DMetadataObject { public String getNodeName() throws InvalidNodeException; public X3DFieldDefinition[] getFieldDefinitions() throws InvalidNodeException; public void realize() throws InvalidNodeException; public boolean isRealized() throws InvalidNodeException; public int[] getNodeType() throws InvalidNodeException; public X3DField getField(String name) throws InvalidFieldException, InvalidNodeException; public void dispose() throws InvalidNodeException; }
public interface X3DNormalNode extends X3DGeometricPropertyNode { public int getNumNormals(); public void setVector(float[] value); public void getVector(float[] value); }
public interface X3DParametricGeometryNode extends X3DGeometryNode { }
public interface X3DPointingDeviceSensorNode extends X3DSensorNode { }
public interface X3DProtoInstance extends X3DNode { public int[] getImplementationTypes(); }
public interface X3DScriptNode extends X3DChildNode, X3DUrlObject { }
public interface X3DSensorNode extends X3DChildNode { public void setEnabled(boolean state); public boolean getEnabled(); public boolean getIsActive(); }
public interface X3DSequencerNode extends X3DChildNode { public void setFraction(float fraction); public int getNumKey(); public void getKey(float[] keys); public void setKey(float[] keys); public int getNumKeyValue(); }
public interface X3DShapeNode extends X3DChildNode { public X3DNode getAppearance(); public void setAppearance(X3DAppearanceNode app); public void setAppearance(X3DProtoInstance app); public X3DNode getGeometry(); public void setGeometry(X3DGeometryNode geom); public void setGeometry(X3DProtoInstance geom); }
public interface X3DSoundNode extends X3DChildNode { }
public interface X3DSoundSourceNode extends X3DTimeDependentNode { public float getPitch(); public void setPitch(float pitch) throws InvalidFieldValueException; public void setDescription(String text); public String getDescription(String text); }
public interface X3DTextNode extends X3DGeometryNode { public void setFontStyle(X3DFontStyleNode fs); public void setFontStyle(X3DProtoInstance fs); public X3DNode getFontStyle(); public int getNumText(); public void setText(String[] text); public void getText(String[] text); }
public interface X3DTextureCoordinateNode extends X3DGeometricPropertyNode { public int getNumCoordinates(); public int getNumComponents(); public void setPoint(float[] points); public void getPoint(float[] points); }
public interface X3DTextureNode extends X3DAppearanceChildNode { }
public interface X3DTexture2DNode extends X3DTextureNode { public void setRepeatS(boolean state); public boolean getRepeatS(); public void setRepeatT(boolean state); public boolean getRepeatT(); }
public interface X3DTextureTransformNode extends X3DAppearanceChildNode { }
public interface X3DTextureTransform2DNode extends X3DTextureTransformNode { public void getCenter(float[] position); public void setCenter(float[] position); public float getRotation(); public void setRotation(float angle); public void getScale(float[] scale); public void setScale(float[] scale); public void getTranslation(float[] trans); public void setTranslation(float[] trans); }
public interface X3DTimeDependentNode extends X3DChildNode { public boolean getIsActive(); public boolean getIsPaused(); public double getElapsedTime(); public void setNumLoops(float count); public float getNumLoops(); public void setLoop(boolean loop); public boolean getLoop(); public void setStartTime(double time); public double getStartTime(); public void setStopTime(double time); public double getStopTime(); public void setPauseTime(double time); public double getPauseTime(); public void setUnPauseTime(double time); public double getUnPauseTime(); }
public interface X3DTouchSensorNode extends X3DPointingDeviceSensorNode { public boolean getIsOver(); public double getEnterTime(); public double getTouchTime(); }
public interface X3DTriggerNode extends X3DChildNode { }
public interface X3DBoundedObject { }
public interface X3DMetadataObject { public void setMetadata(X3DMetadataObject data); public X3DMetadataObject getMetadata(); public void setStandard(String std); public String getStandard(); public void setName(String name); public String getName(); }
public interface X3DUrlObject { public int getNumUrls(); public void getUrl(String[] urls); public void setUrl(String[] urls); }
public interface X3DFieldTypes { public int INPUT_ONLY = 1; public int INITIALIZE_ONLY = 2; public int INPUT_OUTPUT = 3; public int OUTPUT_ONLY = 4; public int SFBOOL = 1; public int MFBOOL = 2; public int SFCOLOR = 21; public int MFCOLOR = 22; public int SFCOLORRGBA = 23; public int MFCOLORRGBA = 24; public int SFDOUBLE = 7; public int MFDOUBLE = 8; public int SFFLOAT = 5; public int MFFLOAT = 6; public int SFIMAGE = 25; public int MFIMAGE = 26; public int SFINT32 = 3; public int MFINT32 = 4; public int SFNODE = 11; public int MFNODE = 12; public int SFROTATION = 19; public int MFROTATION = 20; public int SFSTRING = 27; public int MFSTRING = 28; public int SFTIME = 9; public int MFTIME = 10; public int SFVEC2F = 13; public int MFVEC2F = 14; public int SFVEC3F = 15; public int MFVEC3F = 16; public int SFVEC3D = 17; public int MFVEC3D = 18; }
public class X3DFieldEvent extends java.util.EventObject { public X3DFieldEvent(Object src, double ts, Object data); public double getTime(); public Object getData(); }
public interface X3DFieldEventListener extends java.util.EventListener { public void readableFieldChanged(X3DFieldEvent evt); }
public interface X3DFieldDefinition { public String getName(); public int getAccessType(); public int getFieldType(); public String getFieldTypeString(); }
public interface X3DField { public X3DFieldDefinition getDefinition(); public boolean isReadable(); public boolean isWritable(); public void addX3DEventListener(X3DFieldEventListener l); public void removeX3DEventListener(X3DFieldEventListener l); public void setUserData(Object data); public Object getUserData(); }
public interface MField extends X3DField { public int size(); public void clear(); public void remove(int index); }
public interface SFBool extends X3DField { public boolean getValue(); public void setValue(boolean value); }
public interface MFBool extends MField { public void getValue(boolean[] vals); public boolean get1Value(int index); public void setValue(int size, boolean[] value); public void set1Value(int index, boolean value) throws ArrayIndexOutOfBoundsException; public void append(boolean value); public void insertValue(int index, boolean value); }
public interface SFColor extends X3DField { public void getValue(float[] value); public void setValue(float[] value); }
public interface MFColor extends MField { public void getValue(float[][] value); public void getValue(float[] value); public void get1Value(int index, float[] value); public void setValue(int numColors, float[] value); public void setValue(int numColors, float[][] value); public void set1Value(int index, float[] value); public void append(float[] value); public void insertValue(int index, float[] value); }
public interface SFColorRGBA extends X3DField { public void getValue(float[] value); public void setValue(float[] value); }
public interface MFColorRGBA extends MField { public void getValue(float[][] value); public void getValue(float[] value); public void get1Value(int index, float[] value); public void setValue(int numColors, float[] value); public void setValue(int numColors, float[][] value); public void set1Value(int index, float[] value); public void append(float[] value); public void insertValue(int index, float[] value); }
public interface SFDouble extends X3DField { public double getValue(); public void setValue(double value); }
public interface MFDouble extends MField { public void getValue(double[] values); public double get1Value(int index) throws ArrayIndexOutOfBoundsException; public void setValue(int size, double[] value); public void set1Value(int index, double value) throws ArrayIndexOutOfBoundsException; public void append(double[] value); public void insertValue(int index, double[] value); }
public interface SFFloat extends X3DField { public float getValue(); public void setValue(float value); }
public interface MFFloat extends MField { public void getValue(float[] values); public float get1Value(int index) throws ArrayIndexOutOfBoundsException; public void setValue(int size, float[] value); public void set1Value(int index, float value) throws ArrayIndexOutOfBoundsException; public void append(float[] value); public void insertValue(int index, float[] value); }
public interface SFImage extends X3DField { public int getWidth(); public int getHeight(); public int getComponents(); public void getPixels(int[] pixels); public java.awt.image.WritableRenderedImage getImage(); public void setValue(int width, int height, int components, int[] pixels); public void setImage(java.awt.image.RenderedImage image); public void setSubImage(java.awt.image.RenderedImage image, int srcWidth, int srcHeight, int srcXOffset, int srcYOffset, int destXOffset, int destYOffset); }
public interface MFImage extends MField { public int getWidth(int imgIndex); public int getHeight(int imgIndex); public int getComponents(int imgIndex); public void getPixels(int imgIndex, int[] pixels); public WritableRenderedImage getImage(int imgIndex); public void setImage(int imgIndex, RenderedImage img); public void setSubImage(int imgIndex, RenderedImage img, int srcWidth, int srcHeight, int srcXOffset, int srcYOffset, int destXOffset, int destYOffset); public void set1Value(int index, int value); public void set1Value(int imgIndex, int width, int height, int components, int[] pixels); public void setValue(int[] value); public void setImage(RenderedImage[] img); public void append(RenderedImage value); public void insertValue(int index, RenderedImage value);
public interface SFInt32 extends X3DField { public int getValue(); public void setValue(int value); }
public interface MFInt32 extends MField { public void getValue(int[] values); public int get1Value(int index) throws ArrayIndexOutOfBoundsException; public void setValue(int size, int[] value); public void set1Value(int index, int value) throws ArrayIndexOutOfBoundsException; public void append(int[] value); public void insertValue(int index, int[] value); }
public interface SFNode extends X3DField { public X3DNode getValue(); public void setValue(X3DNode value) throws InvalidNodeException; }
public interface MFNode extends MField { public void getValue(X3DNode[] nodes); public X3DNode get1Value(int index); public void setValue(int size, X3DNode[] value); public void set1Value(int index, X3DNode value); public void append(X3DNode value); public void insertValue(int index, X3DNode value); }
public interface SFRotation extends X3DField { public void getValue(float[] value); public void setValue(float[] value); }
public interface MFRotation extends MField { public void getValue(float[][] value); public void getValue(float[] value); public void get1Value(int index, float[] value); public void setValue(int numRotations, float[] value); public void setValue(int numRotations, float[][] value); public void set1Value(int index, float[] value); public void append(float[] value); public void insertValue(int index, float[] value); }
public interface SFString extends X3DField { public String getValue(); public void setValue(String value); }
public interface MFString extends MField { public void getValue(String[] value); public String get1Value(int index); public void setValue(int numStrings, String[] value); public void set1Value(int index, String value); public void append(String[] value); public void insertValue(int index, String[] value); }
public interface SFTime extends X3DField { public double getValue(); public long getJavaValue(); public void setValue(double value); public void setValue(long value); }
public interface MFTime extends MField { public void getValue(double[] value); public double get1Value(int index); public long get1JavaValue(int index); public void setValue(int size, double[] value); public void setValue(int size, long[] value); public void set1Value(int index, double value); public void set1Value(int index, long value); public void append(double value); public void append(long value); public void insertValue(int index, long value); public void insertValue(int index, double value); }
public interface SFVec2d extends X3DField { public void getValue(double[] value); public void setValue(double[] value); }
public interface MFVec2d extends MField { public void getValue(double[][] value); public void getValue(double[] value); public void get1Value(int index, double[] value); public void setValue(int size, double[] value); public void setValue(int size, double[][] value); public void set1Value(int index, double[] value); public void append(double[] value); public void insertValue(int index, double[] value); }
public interface SFVec2f extends X3DField { public void getValue(float[] value); public void setValue(float[] value); }
public interface MFVec2f extends MField { public void getValue(float[][] value); public void getValue(float[] value); public void get1Value(int index, float[] value); public void setValue(int size, float[] value); public void setValue(int size, float[][] value); public void set1Value(int index, float[] value); public void append(float[] value); public void insertValue(int index, float[] value); }
public interface SFVec3d extends X3DField { public void getValue(double[] value); public void setValue(double[] value); }
public interface MFVec3d extends MField { public void getValue(double[][] value); public void getValue(double[] value); public void get1Value(int index, double[] value); public void setValue(int size, double[] value); public void setValue(int size, double[][] value); public void set1Value(int index, double[] value); public void append(double[] value); public void insertValue(int index, double[] value); }
public interface SFVec3f extends X3DField { public void getValue(float[] value); public void setValue(float[] value); }
public interface MFVec3f extends MField { public void getValue(float[][] value); public void getValue(float[] value); public void get1Value(int index, float[] value); public void setValue(int size, float[] value); public void setValue(int size, float[][] value); public void set1Value(int index, float[] value); public void append(float[] value); public void insertValue(int index, float[] value); }
public class BrowserEvent extends EventObject { public static final int INITIALIZED = 0; public static final int SHUTDOWN = 1; public static final int URL_ERROR = 2; public static final int CONNECTION_ERROR = 10; public static final int LAST_IDENTIFIER = 100; public BrowserEvent(Object browser, int action); public int getID(); }
public class BrowserFactory { private BrowserFactory(); public static void setBrowserFactoryImpl( BrowserFactoryImpl fac) throws IllegalArgumentException, X3DException, SecurityException; public static X3DComponent createX3DComponent(Map params) throws NotSupportedException; public static ExternalBrowser getBrowser(Applet applet) throws NotSupportedException, NoSuchBrowserException, ConnectionException; public static ExternalBrowser getBrowser(Applet applet, String frameName, int index) throws NotSupportedException, NoSuchBrowserException, ConnectionException; public static ExternalBrowser getBrowser(InetAddress address, int port) throws NotSupportedException, NoSuchBrowserException, UnknownHostException, ConnectionException; }
public class X3DFieldEvent extends EventObject { public X3DFieldEvent(Object src, double ts, Object data); public double getTime(); public Object getData(); }
public class Matrix3 { public Matrix3(); public void setIdentity(); public void set(int row, int column) public float get(int row, int column) public void setTransform(SFVec2f translation, SFVec3f rotation, SFVec2f scale, SFVec3f scaleOrientation, SFVec2f center) public void getTransform(SFVec2f translation, SFVec3f rotation, SFVec2f scale) public Matrix3 inverse() public Matrix3 transpose() public Matrix3 multiplyLeft(Matrix3 mat) public Matrix3 multiplyRight(Matrix3 mat) public Matrix3 multiplyRowVector(SFVec3f vec) public Matrix3 multiplyColVector(SFVec3f vec) }
public class Matrix4 { public Matrix4(); public void setIdentity(); public void set(int row, int column) public float get(int row, int column) public void setTransform(SFVec3f translation, SFRotation rotation, SFVec3f scale, SFRotation scaleOrientation, SFVec3f center) public void getTransform(SFVec3f translation, SFRotation rotation, SFVec3f scale) public Matrix3 inverse() public Matrix3 transpose() public Matrix3 multiplyLeft(Matrix4 mat) public Matrix3 multiplyRight(Matrix4 mat) public Matrix3 multiplyRowVector(SFVec3f vec) public Matrix3 multiplyColVector(SFVec3f vec) }
public interface ComponentInfo { public String getName(); public int getLevel(); public String getTitle(); public String getProviderURL(); public String toX3DString(); }
public interface ProfileInfo { public String getName(); public String getTitle(); public ComponentInfo[] getComponents(); public String toX3DString(); }
public class X3DException extends RuntimeException { public X3DException(); public X3DException(String); }
public class BrowserNotSharedException extends X3DException { public BrowserNotSharedException(); public BrowserNotSharedException(String); }
public class ConnectionException extends X3DException { public ConnectionException(); public ConnectionException(String); }
public class ImportedNodeException extends X3DException { public ImportedNodeException(); public ImportedNodeException(String); }
public class InsufficientCapabilitiesException extends X3DException { public InsufficientCapabilitiesException(); public InsufficientCapabilitiesException(String); }
public class InvalidBrowserException extends X3DException { public InvalidBrowserException(); public InvalidBrowserException(String); }
public class InvalidDocumentException extends X3DException { public InvalidDocumentException(); public InvalidDocumentException(String); }
public class InvalidExecutionContextException extends X3DException { public InvalidExecutionContextException(); public InvalidExecutionContextException(String); }
public class InvalidFieldException extends X3DException { public InvalidFieldException(); public InvalidFieldException(String); }
public class InvalidFieldValueException extends X3DException { public InvalidFieldValueException(); public InvalidFieldValueException(String); }
public class InvalidNodeException extends X3DException { public InvalidNodeException(); public InvalidNodeException(String); }
public class InvalidOperationTimingException extends X3DException { public InvalidOperationTimingException(); public InvalidOperationTimingException(String); }
public class InvalidProtoException extends X3DException { public InvalidProtoException(); public InvalidProtoException(String); }
public class InvalidRouteException extends X3DException { public InvalidRouteException(); public InvalidRouteException(String); }
public class InvalidURLException extends X3DException { public InvalidURLException(); public InvalidURLException(String); }
public class InvalidX3DException extends X3DException { public InvalidX3DException(); public InvalidX3DException(String); }
public class NodeInUseException extends X3DException { public NodeInUseException(); public NodeInUseException(String); }
public class NodeUnavailableException extends X3DException { public NodeUnavailableException(); public NodeUnavailableException(String); }
public class NoSuchBrowserException extends X3DException { public NoSuchBrowserException(); public NoSuchBrowserException(String); }
public class NotSupportedException extends X3DException { public NotSupportedException(); public NotSupportedException(String); }
public class URLUnavailableException extends X3DException { public URLUnavailableException(); public URLUnavailableException(String); }