java.lang.Object
com.trapezium.vrml.VrmlElement
com.trapezium.vrml.SingleTokenElement
com.trapezium.vrml.MultipleTokenElement
com.trapezium.vrml.fields.Field
com.trapezium.vrml.node.Node
com.trapezium.vrml.node.PROTObase
com.trapezium.vrml.node.PROTO
- All Implemented Interfaces:
- java.io.Serializable, com.trapezium.pattern.VisitorPattern
- public class PROTO
- extends PROTObase
Scene graph component for a PROTO declaration.
- Since:
- 1.0
- Version:
- 1.1, 17 Dec 1997
| Nested classes inherited from class com.trapezium.vrml.fields.Field |
|
| Fields inherited from class com.trapezium.vrml.fields.Field |
|
|
Constructor Summary |
PROTO(int tokenOffset)
|
| Methods inherited from class com.trapezium.vrml.node.PROTObase |
addInterface, addISField, checkForUnusedInterfaces, getClosestFieldId, getFieldDescriptor, getFieldNames, getId, getInterfaceCount, getInterfaceDeclaration, getInterfaceVector, getISfield, getISfields, getNodeAt, getNodeName, getNumberISfields, getPROTObody, getPROTONodeType, hasUnusedInterfaces, isValidFieldId, setId |
| Methods inherited from class com.trapezium.vrml.node.Node |
addChildNode, addChildNode, addChildNode, ddump, generatedParent, getBoolean, getBoolValue, getChildNode, getDefaultFieldValue, getDEFparent, getField, getFieldAt, getFieldType, getFieldValue, getFloatArray, getFloatValue, getInterfaceType, getIntValue, getISfield, getLastField, getMFfield, getNode, getNodeValue, getNumberFields, getParent, isBindable, isDEF, isDEForUSE, isFieldUsedByROUTE, isImplicitFieldId, isSensor, isUSE, removeChildNode, removeField, setError, setField, setField, setField, setField, vrmlClone |
| Methods inherited from class com.trapezium.vrml.fields.Field |
cloneFieldValue, fieldValueTraverse, getFieldId, getFieldType, getFieldValue, getFloat, getInterfaceType, getNodeParent, getNodeValue, isInUse, isISfield, markInUse, setFieldId, setFieldType, setFieldType, setFieldValue |
| Methods inherited from class com.trapezium.vrml.VrmlElement |
addChild, addWarning, contains, containsErrors, deregisterSelf, dump, dump, dumpUserDefined, getChildAt, getError, getLastChild, getParent, getRoot, getScene, getTokenEnumerator, isScene, numberChildren, removeChild, removeVrmlElement, setParent, traverse, twoPassTraverse |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
suppressISwarning
public static boolean suppressISwarning
builtInNodeType
java.lang.String builtInNodeType
- PROTO nodes can be used in place of a particular built in type
PROTO
public PROTO(int tokenOffset)
isPROTOnode
public boolean isPROTOnode()
- template method, overrides Node.isPROTOnode() which returns false.
- Overrides:
isPROTOnode in class Node
getBuiltInNodeType
public java.lang.String getBuiltInNodeType()
- Get the built-in type for this PROTO, i.e. the type of the first Node in the PROTO.
- Specified by:
getBuiltInNodeType in class PROTObase
getBaseName
public java.lang.String getBaseName()
- Description copied from class:
com.trapezium.vrml.VrmlElement
- get the class name without package
setBuiltInNodeType
public void setBuiltInNodeType(java.lang.String type)
- Set the built in type that this PROTO can be substituted for.
getClosestInterfaceDeclaration
public com.trapezium.vrml.fields.Field getClosestInterfaceDeclaration(java.lang.String fieldName)
- get the PROTO interface field with the name that best matches input name.
This is used when a PROTO instance has an unknown field name. We
assume this is a typo, and search for a valid field name that matches.
checkInUse
public void checkInUse()
- check if all the PROTO interface fields are referenced by an IS statement