Xj3D 2.0 VRML/X3D Code API

org.web3d.vrml.nodes
Interface VRMLLinkNodeType


public interface VRMLLinkNodeType

Representation of a node that represents navigatable links to other files.

Link nodes do not require content to come from other places, but they do want to provide information about where that object might allow the user to navigate too.

All URLs returned from the getUrl() call are required to be fully qualified. The one exception are links within the same world. These links shall have the first character start with '#'. This will then refer to the DEF name of a viewpoint that is the new location to travel to.

Version:
$Revision: 1.5 $
Author:
Justin Couch

Method Summary
 java.lang.String getDescription()
          Get the description to associate with the link.
 java.lang.String[] getParameter()
          Get the current list of parameters registered for this link.
 java.lang.String[] getUrl()
          Get the list of URLs requested by this node.
 void setDescription(java.lang.String desc)
          Set the description string for this link.
 void setParameter(java.lang.String[] params)
          Set the parameter list to the new series of values.
 void setUrl(java.lang.String[] url, int numValid)
          Set the URL to a new value.
 void setWorldUrl(java.lang.String url)
          Set the world URL so that any relative URLs may be corrected to the fully qualified version.
 

Method Detail

getDescription

java.lang.String getDescription()
Get the description to associate with the link. This is a line of text suitable for mouseovers, status information etc. If there is no description set then it returns null.

Returns:
The current description or null

setDescription

void setDescription(java.lang.String desc)
Set the description string for this link. Setting a value of null will clear the current description.

Parameters:
desc - The new description to set

getParameter

java.lang.String[] getParameter()
Get the current list of parameters registered for this link. If there are none set then this will return null. No format checking of the strings are performed.

Returns:
The list of current parameter values or null

setParameter

void setParameter(java.lang.String[] params)
Set the parameter list to the new series of values. A value of null for the parameter list will clear the current list.

Parameters:
params - The new list of parameters to use

setWorldUrl

void setWorldUrl(java.lang.String url)
Set the world URL so that any relative URLs may be corrected to the fully qualified version. Guaranteed to be non-null.

Parameters:
url - The world URL.

getUrl

java.lang.String[] getUrl()
Get the list of URLs requested by this node. If there are no URLs supplied in the text file then this will return a zero length array.

Returns:
The list of URLs to attempt to load

setUrl

void setUrl(java.lang.String[] url,
            int numValid)
Set the URL to a new value. If the value is null, it removes the old contents (if set) and treats it as though there is no content.

Parameters:
url - The list of urls to set or null
numValid - The number of valid values to copy from the array

Xj3D 2.0 VRML/X3D Code API

Copyright © 2001 - 2006 Web3D Consortium