All Packages Class Hierarchy This Package Previous Next Index
Class org.w3c.jigsaw.ssi.commands.IfCommand
java.lang.Object
|
+----org.w3c.jigsaw.ssi.commands.IfCommand
- public class IfCommand
- extends Object
- implements ControlCommand
Implementation of the SSI if
command.
-
ifstore
-
-
IfCommand()
-
-
check(CommandRegistry, ArrayDictionary, Dictionary, Request)
-
-
execute(SSIFrame, Request, ArrayDictionary, Dictionary)
- Executes this command.
-
getName()
-
Returns the name of this command.
-
getPosition(String)
-
-
getValue(Dictionary, String, Request)
- Returns the (String) value of the given variable.
-
jumpTo(SSIFrame, Request, CommandRegistry, ArrayDictionary, Dictionary)
- Give the next position in the structure witch
store the SSIFrame.
-
setPosition(SSIFrame, Request, CommandRegistry, ArrayDictionary, Dictionary, int)
- register the command position in the structure
witch store the SSIFrame.
ifstore
protected static Hashtable ifstore
IfCommand
public IfCommand()
getValue
public String getValue(Dictionary variables,
String var,
Request request)
- Returns the (String) value of the given variable.
- Returns:
- a String instance.
getPosition
protected static int getPosition(String name) throws ControlCommandException
setPosition
public void setPosition(SSIFrame ssiframe,
Request request,
CommandRegistry registry,
ArrayDictionary parameters,
Dictionary variables,
int position)
- register the command position in the structure
witch store the SSIFrame.
execute
public Reply execute(SSIFrame ssiframe,
Request request,
ArrayDictionary parameters,
Dictionary variables)
- Executes this command. Might modify variables.
Must not modify the parameters.
It may handle conditional requests, except that if
it replies with a status of HTTP.NOT_MODIFIED, it must
still reply with a content (the same content that it would have
returned for an inconditional request). This is because
further SSI commands down the line may decide thay they have
been modified, and then a content must be emitted by SSIFrame.
- Parameters:
- request - the original HTTP request
- parameters - The parameters for this command
- variables - The global variables for the parse
- Returns:
- a Reply with the output from the command
check
protected boolean check(CommandRegistry registry,
ArrayDictionary parameters,
Dictionary variables,
Request request)
jumpTo
public int jumpTo(SSIFrame ssiframe,
Request request,
CommandRegistry registry,
ArrayDictionary parameters,
Dictionary variables) throws ControlCommandException
- Give the next position in the structure witch
store the SSIFrame.
- Returns:
- An integer
- Throws: ControlCommandException
- if action failed.
getName
public String getName()
- Returns the name of this command. (Case sensitivity is up to
the
lookupCommand
method in the command registry.)
- Returns:
- the name of the command
- See Also:
- lookupCommand
All Packages Class Hierarchy This Package Previous Next Index