freemarker.debug

Interface DebugModel

All Superinterfaces:
Remote
Known Subinterfaces:
DebuggedEnvironment

public interface DebugModel
extends Remote

Represents the debugger-side mirror of a TemplateModel object, a Template object, or a Configuration object. The Environment objects are also represented by instances of this model, although not directly but through a separate subinterface DebuggedEnvironment. The interface is a union of almost all of FreeMarker template models with identical method signatures. For purposes of optimizing network traffic there are bulk retrieval methods for sequences and hashes, as well as a getModelTypes() method that returns a bit mask of various TYPE_xxx constants flagging which template models are implemented by the mirrored object.
Version:
$Id: DebugModel.java,v 1.2 2003/06/08 00:58:16 herbyderby Exp $
Author:
Attila Szegedi

Field Summary

static int
TYPE_BOOLEAN
static int
TYPE_COLLECTION
static int
TYPE_CONFIGURATION
static int
TYPE_DATE
static int
TYPE_ENVIRONMENT
static int
TYPE_HASH
static int
TYPE_HASH_EX
static int
TYPE_METHOD
static int
TYPE_METHOD_EX
static int
TYPE_NUMBER
static int
TYPE_SCALAR
static int
TYPE_SEQUENCE
static int
TYPE_TEMPLATE
static int
TYPE_TRANSFORM

Method Summary

DebugModel
get(String key)
DebugModel[]
get(String[] keys)
DebugModel
get(int index)
DebugModel[]
get(int fromIndex, int toIndex)
boolean
getAsBoolean()
Date
getAsDate()
Number
getAsNumber()
String
getAsString()
DebugModel[]
getCollection()
int
getDateType()
int
getModelTypes()
String[]
keys()
int
size()

Field Details

TYPE_BOOLEAN

public static final int TYPE_BOOLEAN
Field Value:
8

TYPE_COLLECTION

public static final int TYPE_COLLECTION
Field Value:
32

TYPE_CONFIGURATION

public static final int TYPE_CONFIGURATION
Field Value:
8192

TYPE_DATE

public static final int TYPE_DATE
Field Value:
4

TYPE_ENVIRONMENT

public static final int TYPE_ENVIRONMENT
Field Value:
2048

TYPE_HASH

public static final int TYPE_HASH
Field Value:
64

TYPE_HASH_EX

public static final int TYPE_HASH_EX
Field Value:
128

TYPE_METHOD

public static final int TYPE_METHOD
Field Value:
256

TYPE_METHOD_EX

public static final int TYPE_METHOD_EX
Field Value:
512

TYPE_NUMBER

public static final int TYPE_NUMBER
Field Value:
2

TYPE_SCALAR

public static final int TYPE_SCALAR
Field Value:
1

TYPE_SEQUENCE

public static final int TYPE_SEQUENCE
Field Value:
16

TYPE_TEMPLATE

public static final int TYPE_TEMPLATE
Field Value:
4096

TYPE_TRANSFORM

public static final int TYPE_TRANSFORM
Field Value:
1024

Method Details

get

public DebugModel get(String key)
            throws TemplateModelException,
                   RemoteException

get

public DebugModel[] get(String[] keys)
            throws TemplateModelException,
                   RemoteException

get

public DebugModel get(int index)
            throws TemplateModelException,
                   RemoteException

get

public DebugModel[] get(int fromIndex,
                        int toIndex)
            throws TemplateModelException,
                   RemoteException

getAsBoolean

public boolean getAsBoolean()
            throws TemplateModelException,
                   RemoteException

getAsDate

public Date getAsDate()
            throws TemplateModelException,
                   RemoteException

getAsNumber

public Number getAsNumber()
            throws TemplateModelException,
                   RemoteException

getAsString

public String getAsString()
            throws TemplateModelException,
                   RemoteException

getCollection

public DebugModel[] getCollection()
            throws TemplateModelException,
                   RemoteException

getDateType

public int getDateType()
            throws TemplateModelException,
                   RemoteException

getModelTypes

public int getModelTypes()
            throws RemoteException

keys

public String[] keys()
            throws TemplateModelException,
                   RemoteException

size

public int size()
            throws TemplateModelException,
                   RemoteException