com.uwyn.rife.engine
Interface ElementChildTrigger


public interface ElementChildTrigger

This interface contains all the methods that a class must implement to be able to handle child trigger events.

Child triggers are setup in the site structure to drill down an element inheritance hierarchy according to value changes in inputs or cookies. This will happen both when values are sent by a client and when values are set by an element.

By registering an instance of a ElementChildTrigger class, it's possible to only allow the child to be activated according to certain conditions. This can for instance be used to validate an authentication session identifier, and only allow the child activation if the identifier is valid and not expired.

Since:
1.0
Version:
$Revision: 3634 $
Author:
Geert Bevin (gbevin[remove] at uwyn dot com)
See Also:
ElementSupport.setChildTrigger(com.uwyn.rife.engine.ElementChildTrigger)

Method Summary
 boolean childTriggered(String name, String[] values)
          This method will be called when a child trigger instance is registered and a value is provided for an input or cookie that is setup as a child trigger.
 

Method Detail

childTriggered

boolean childTriggered(String name,
                       String[] values)
This method will be called when a child trigger instance is registered and a value is provided for an input or cookie that is setup as a child trigger.

You are not allowed to access any information of the element context state besides the name and values of the child trigger variable. These are provided to you as method arguments. If you do try to access other state information, the engine will throw a RequestAccessDeniedException exception. This is needed to be able to record all the child triggers that occurred. The engine uses this information to replay child triggers automatically during subsequent requests and access a child element directly if all child triggers are still successful.

Parameters:
name - the name of the child trigger variable
values - the values of the child trigger variable
Returns:
true if the child element can be executed; or

false if the logic should continue in the element that activated the child trigger

Since:
1.0


Copyright © 2001-2007 Uwyn sprl/bvba. All Rights Reserved.