org.apache.tapestry5.internal.services
Class ArrayEventContext

java.lang.Object
  extended by org.apache.tapestry5.internal.services.ArrayEventContext
All Implemented Interfaces:
EventContext

public class ArrayEventContext
extends Object
implements EventContext

Simple implementation of EventContext.

Since:
5.1.0.0

Constructor Summary
ArrayEventContext(TypeCoercer typeCoercer, Object... values)
           
 
Method Summary
<T> T
get(Class<T> desiredType, int index)
          Extracts a parameter value and coerces or decodes it to the desired type.
 int getCount()
          Returns the number of parameter values that can be extracted.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArrayEventContext

public ArrayEventContext(TypeCoercer typeCoercer,
                         Object... values)
Method Detail

get

public <T> T get(Class<T> desiredType,
                 int index)
Description copied from interface: EventContext
Extracts a parameter value and coerces or decodes it to the desired type.

Specified by:
get in interface EventContext
Parameters:
desiredType - the type of value required
index - identifies which parameter value to extract
Returns:
the value extracted and converted or coerced

getCount

public int getCount()
Description copied from interface: EventContext
Returns the number of parameter values that can be extracted.

Specified by:
getCount in interface EventContext


Copyright © 2006-2009 Apache Software Foundation. All Rights Reserved.