org.apache.velocity.runtime.parser.node
Class NodeUtils
public
class
NodeUtils
extends Object
Utilities for dealing with the AST node structure.
Version: $Id: NodeUtils.java,v 1.16.4.1 2004/03/03 23:22:59 geirm Exp $
Author: Jason van Zyl Geir Magnusson Jr.
public static String interpolate(String argStr,
Context vars)
Utility method to interpolate context variables
into string literals. So that the following will
work:
#set $name = "candy"
$image.getURI("${name}.jpg")
And the string literal argument will
be transformed into "candy.jpg" before
the method is executed.
public static String specialText(
Token t)
Collect all the s that
are carried along with a token. Special
tokens do not participate in parsing but
can still trigger certain lexical actions.
In some cases you may want to retrieve these
special tokens, this is simply a way to
extract them.
public static String tokenLiteral(
Token t)
complete node literal
Copyright B) 2002 Apache Software Foundation. All Rights Reserved.