org.apache.catalina.ssi

Interface SSIExternalResolver

public interface SSIExternalResolver

Interface used by SSIMediator to talk to the 'outside world' ( usually a servlet )

Version: $Revision: 531303 $, $Date: 2007-04-23 02:24:01 +0200 (Mon, 23 Apr 2007) $

Author: Dan Sandberg

Method Summary
voidaddVariableNames(Collection variableNames)
Adds any external variables to the variableNames collection.
DategetCurrentDate()
Returns the current date.
longgetFileLastModified(String path, boolean virtual)
longgetFileSize(String path, boolean virtual)
StringgetFileText(String path, boolean virtual)
StringgetVariableValue(String name)
voidlog(String message, Throwable throwable)
voidsetVariableValue(String name, String value)
Set the named variable to the specified value.

Method Detail

addVariableNames

public void addVariableNames(Collection variableNames)
Adds any external variables to the variableNames collection.

Parameters: variableNames the collection to add to

getCurrentDate

public Date getCurrentDate()
Returns the current date. This is useful for putting the SSI stuff in a regression test. Since you can make the current date a constant, it makes testing easier since the output won't change.

Returns: the data

getFileLastModified

public long getFileLastModified(String path, boolean virtual)

getFileSize

public long getFileSize(String path, boolean virtual)

getFileText

public String getFileText(String path, boolean virtual)

getVariableValue

public String getVariableValue(String name)

log

public void log(String message, Throwable throwable)

setVariableValue

public void setVariableValue(String name, String value)
Set the named variable to the specified value. If value is null, then the variable will be removed ( ie. a call to getVariableValue will return null )

Parameters: name of the variable value of the variable

Copyright © 2000-2011 Apache Software Foundation. All Rights Reserved.