|
Xj3D 2.0 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.scripting.browser.CommonBrowser
org.web3d.vrml.scripting.browser.VRML97CommonBrowser
public class VRML97CommonBrowser
The common parts of a browser implementation suitable for VRML97 scripting.
This class is a full implementation because the external and scripting interfaces will use it differently. External use can just subclass and add the EAI Browser interface. For scripting, the need to extend the Browser base class means that this class will need to be delegated to.
The current implementation ignores any parameter values provided by the world.
| Field Summary |
|---|
| Fields inherited from class org.web3d.vrml.scripting.browser.CommonBrowser |
|---|
core, errorReporter, loaderManager, routeManager, stateManager |
| Constructor Summary | |
|---|---|
VRML97CommonBrowser(BrowserCore browser,
RouteManager rm,
FrameStateManager fsm,
WorldLoaderManager wlm,
VRMLNodeFactory nodeFac)
Create a browser instance that represents the given universe details. |
|
| Method Summary | |
|---|---|
VRMLNodeType[] |
createVrmlFromString(java.lang.String vrmlSyntax,
VRMLExecutionSpace parentSpace)
Parse the given string and turn this into a list of VRML nodes. |
void |
createVrmlFromURL(java.lang.String[] url,
VRMLNodeType node,
java.lang.String eventIn)
Create and load VRML from the given URL and place the returned values as nodes into the given VRML node in the scene. |
void |
replaceWorld(VRMLNodeType[] nodes)
Replace the current world with the given nodes. |
| Methods inherited from class org.web3d.vrml.scripting.browser.CommonBrowser |
|---|
addRoute, completeUrl, deleteRoute, getCurrentFrameRate, getCurrentSpeed, getDescription, getName, getVersion, getWorldURL, loadURL, setDescription, setErrorReporter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public VRML97CommonBrowser(BrowserCore browser,
RouteManager rm,
FrameStateManager fsm,
WorldLoaderManager wlm,
VRMLNodeFactory nodeFac)
browser - The core representation of the browserrm - A route manager for users creating/removing routeswlm - Loader manager for doing async callsfsm - State manager for coordinating inter-frame processingnodeFac - Factory to create nodes with for this renderer
java.lang.IllegalArgumentException - A paramter is null| Method Detail |
|---|
public void replaceWorld(VRMLNodeType[] nodes)
Calling this method causes a SHUTDOWN event followed by an INITIALIZED event to be generated.
nodes - The list of nodes to use as the new root of the world
public VRMLNodeType[] createVrmlFromString(java.lang.String vrmlSyntax,
VRMLExecutionSpace parentSpace)
throws VRMLException,
VRMLParseException,
java.io.IOException
At the point that this method returns, external files such as textures, sounds and inlines may not have been loaded.
The string may contain all legal VRML syntax. The VRML header line is not required to be present in the string.
vrmlSyntax - The string containing VRML string syntaxparentSpace - The parent space for these nodes or null for top-level
VRMLException - General error during processing
VRMLParseException - If the string does not contain legal
VRML syntax or no node instantiations
java.io.IOException
public void createVrmlFromURL(java.lang.String[] url,
VRMLNodeType node,
java.lang.String eventIn)
throws InvalidFieldException
url - The list of URLs in decreasing order of preference as defined
in the VRML97 specification.node - The destination node for the VRML code to be sent to.eventIn - The name of the MFNode eventIn to send the nodes to.
InvalidFieldException - the eventIn or node is not a valid
destination for the URL information
|
Xj3D 2.0 VRML/X3D Code API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||