ASTStringLiteral (Velocity 1.4 API)
Keywords: org.apache.velocity.runtime.parser.node.ASTStringLiteral class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.velocity.runtime.parser.node
Class ASTStringLiteral

    java.lang.Object
      org.apache.velocity.runtime.parser.node.SimpleNode
          org.apache.velocity.runtime.parser.node.ASTStringLiteral

All Implemented Interfaces:
  Node

public class ASTStringLiteral
extends SimpleNode

ASTStringLiteral support. Will interpolate!

Version:
  $Id: ASTStringLiteral.java,v 1.17.4.1 2004/03/03 23:22:59 geirm Exp $
Author:
  Geir Magnusson Jr., Jason van Zyl

Field Summary
`private java.lang.String` | `image`
`private boolean` | `interpolate`
`private java.lang.String` | `interpolateimage`
`private SimpleNode` | `nodeTree`

Fields inherited from class org.apache.velocity.runtime.parser.node.SimpleNode
`children, first, id, info, invalid, last, parent, parser, rsvc, state`

Constructor Summary
`ASTStringLiteral(int id)`
`ASTStringLiteral(Parser p, int id)`

Method Summary
`java.lang.Object` | `init(InternalContextAdapter context, java.lang.Object data)` init : we don't have to do much.
`java.lang.Object` | `jjtAccept(ParserVisitor visitor, java.lang.Object data)` Accept the visitor.
`java.lang.Object` | `value(InternalContextAdapter context)` renders the value of the string literal If the properties allow, and the string literal contains a $ or a # the literal is rendered against the context Otherwise, the stringlit is returned.

Methods inherited from class org.apache.velocity.runtime.parser.node.SimpleNode
`childrenAccept, dump, evaluate, execute, getColumn, getFirstToken, getInfo, getLastToken, getLine, getType, isInvalid, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, literal, render, setFirstToken, setInfo, setInvalid, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### interpolate

    private boolean interpolate

### nodeTree

    private SimpleNode nodeTree

### image

    private java.lang.String image

### interpolateimage

    private java.lang.String interpolateimage

Constructor Detail

### ASTStringLiteral

    public ASTStringLiteral(int id)

### ASTStringLiteral

    public ASTStringLiteral(Parser p,
                            int id)

Method Detail

### init

    public java.lang.Object init(InternalContextAdapter context,
                                 java.lang.Object data)
                          throws java.lang.Exception

  init : we don't have to do much. Init the tree (there shouldn't be one) and then see if interpolation is turned on.

  Specified by:
    `init` in interface `Node`
  Overrides:
    `init` in class `SimpleNode`
  Throws:
    `java.lang.Exception`

### jjtAccept

    public java.lang.Object jjtAccept(ParserVisitor visitor,
                                      java.lang.Object data)

  Accept the visitor.

  Specified by:
    `jjtAccept` in interface `Node`
  Overrides:
    `jjtAccept` in class `SimpleNode`

### value

    public java.lang.Object value(InternalContextAdapter context)

  renders the value of the string literal If the properties allow, and the string literal contains a $ or a # the literal is rendered against the context Otherwise, the stringlit is returned.

  Specified by:
    `value` in interface `Node`
  Overrides:
    `value` in class `SimpleNode`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 Apache Software Foundation. All Rights Reserved.