|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.web3d.vrml.nodes.proto.AbstractProto
org.web3d.vrml.nodes.proto.ExternalPrototypeDecl
ExternalPrototypeDecl is an implementation of the VRMLExternProtoDeclare interface.
The implementation does not provide any events for either type of listener.
VRMLExternProtoDeclare,
VRMLProtoInstance| Field Summary | |
protected java.lang.String |
loadedURI
The URI that was acutally loaded |
| Fields inherited from class org.web3d.vrml.nodes.proto.AbstractProto |
BAD_NODE_MSG, errorReporter, FIELD_CLASH_MSG, fieldData, fieldDeclList, fieldIndexMap, isVrml97, nodeName, protoCreator, VRML97_FIELD_MSG, vrmlMajorVersion, vrmlMinorVersion |
| Fields inherited from interface org.web3d.vrml.nodes.VRMLExternalNodeType |
LOAD_COMPLETE, LOAD_FAILED, LOADING, NOT_LOADED |
| Constructor Summary | |
ExternalPrototypeDecl(java.lang.String name,
int majorVersion,
int minorVersion,
NodeTemplateToInstanceCreator creator)
Create a new instance of a proto that has the given name. |
|
| Method Summary | |
void |
addContentStateListener(VRMLContentStateListener l)
Add a listener to this node instance for the content state changes. |
void |
addUrlListener(VRMLUrlListener l)
Add a listener to this node instance. |
boolean |
checkValidContentType(java.lang.String mimetype)
Check to see if the given MIME type is one that would be supported as content coming into this node. |
VRMLNode |
createNewInstance(VRMLNode root,
boolean isStatic)
Create a new instance of a real node from this template. |
int |
getLoadState()
Ask the state of the load of this node. |
int |
getPrimaryType()
Get the primary type of this node. |
VRMLProtoDeclare |
getProtoDetails()
Get the real prototype information that this external reference maps to. |
java.lang.String[] |
getUrl()
Accessor method to get current value of field url |
java.lang.String |
getWorldUrl()
Get the world URL so set for this node. |
void |
removeContentStateListener(VRMLContentStateListener l)
Remove a listener from this node instance for the content state changes. |
void |
removeUrlListener(VRMLUrlListener l)
Remove a listener from this node instance. |
void |
setContent(java.lang.String mimetype,
java.lang.Object content)
Set the content of this node to the given object. |
void |
setLoadedURI(java.lang.String URI)
Notify the node which URL was used to load the content. |
void |
setLoadState(int state)
Set the load state of the node. |
void |
setProtoDetails(PrototypeDecl proto)
Set the real prototype information that this external reference maps to. |
void |
setUrl(java.lang.String[] newUrl,
int numValid)
Set a new value for the url list for this externproto. |
void |
setWorldUrl(java.lang.String url)
Set the world URL so that any relative URLs may be corrected to the fully qualified version. |
| Methods inherited from class org.web3d.vrml.nodes.proto.AbstractProto |
addNodeListener, appendField, checkNodeType, deleteField, deleteField, fireFieldChanged, getAllFields, getFieldCount, getFieldDeclaration, getFieldIndex, getNumFields, getVRMLNodeName, isVRML97, removeNodeListener, setErrorReporter |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.web3d.vrml.lang.VRMLNodeTemplate |
appendField, deleteField, deleteField, getAllFields, getFieldCount, getFieldDeclaration, getFieldIndex, getNumFields, getVRMLNodeName, setErrorReporter |
| Field Detail |
protected java.lang.String loadedURI
| Constructor Detail |
public ExternalPrototypeDecl(java.lang.String name,
int majorVersion,
int minorVersion,
NodeTemplateToInstanceCreator creator)
name - The name of the proto to usemajorVersion - The major version number of this sceneminorVersion - The minor version number of this scenecreator - The node creator for generating instances of ourself| Method Detail |
public VRMLNode createNewInstance(VRMLNode root,
boolean isStatic)
throws InvalidNodeTypeException
createNewInstance in interface VRMLNodeTemplateroot - The node that represents the root node of the
VRMLExecutionSpace that we're in.isStatic - true if this is created within a StaticGroup
InvalidNodeTypeException - The root node is not a node capable
of representing a root of a scene graphVRMLProtoInstance,
VRMLWorldRootNodeTypepublic void setProtoDetails(PrototypeDecl proto)
proto - The underlying proto definitionpublic VRMLProtoDeclare getProtoDetails()
getProtoDetails in interface VRMLExternProtoDeclare
public void setUrl(java.lang.String[] newUrl,
int numValid)
setUrl in interface VRMLSingleExternalNodeTypenewUrl - The new set of URLs to usenumValid - number of valid items to fetch from the listpublic java.lang.String[] getUrl()
getUrl in interface VRMLSingleExternalNodeTypepublic int getLoadState()
getLoadState in interface VRMLSingleExternalNodeTypepublic void setLoadState(int state)
setLoadState in interface VRMLSingleExternalNodeTypestate - The new state of the nodepublic boolean checkValidContentType(java.lang.String mimetype)
checkValidContentType in interface VRMLSingleExternalNodeTypemimetype - The type to check for
public void setWorldUrl(java.lang.String url)
setWorldUrl in interface VRMLExternalNodeTypeurl - The world URL.public java.lang.String getWorldUrl()
getWorldUrl in interface VRMLExternalNodeType
public void setContent(java.lang.String mimetype,
java.lang.Object content)
throws java.lang.IllegalArgumentException
setContent in interface VRMLSingleExternalNodeTypemimetype - The mime type of this object if knowncontent - The content of the object
IllegalArguementException - The content object is not supported
java.lang.IllegalArgumentExceptionpublic void setLoadedURI(java.lang.String URI)
setLoadedURI in interface VRMLSingleExternalNodeTypeURI - The URI used to load this contentpublic int getPrimaryType()
getPrimaryType in interface VRMLNodeTemplatepublic void addUrlListener(VRMLUrlListener l)
addUrlListener in interface VRMLExternalNodeTypel - The listener instance to addpublic void removeUrlListener(VRMLUrlListener l)
removeUrlListener in interface VRMLExternalNodeTypel - The listener to be removedpublic void addContentStateListener(VRMLContentStateListener l)
addContentStateListener in interface VRMLExternalNodeTypel - The listener instance to addpublic void removeContentStateListener(VRMLContentStateListener l)
removeContentStateListener in interface VRMLExternalNodeTypel - The listener to be removed
|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||