Package org.apache.velocity.runtime.parser.node

# Class PutExecutor

java.lang.Object
org.apache.velocity.runtime.parser.node.SetExecutor
org.apache.velocity.runtime.parser.node.PutExecutor

public class PutExecutor extends SetExecutor
Executor that simply tries to execute a put(key, value) operation. This will try to find a put(key) method for any type of object, not just objects that implement the Map interface as was previously the case.

Since:
  1.5
Version:
  $Id$
Author:
  Jason van Zyl, Henning P. Schmiedehausen

## Field Summary

### Fields inherited from class org.apache.velocity.runtime.parser.node.SetExecutor

`log`

## Constructor Summary

Constructors
Constructor
Description
`PutExecutor(org.slf4j.Logger log, Introspector introspector, Class<?> clazz, Object arg, String property)`

## Method Summary

Modifier and Type
Method
Description
`protected void`
`discover(Class<?> clazz, Object arg)`
`Object`
`execute(Object o, Object value)`
Execute method against context.

### Methods inherited from class org.apache.velocity.runtime.parser.node.SetExecutor

`getMethod, isAlive, setMethod`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### PutExecutor

public PutExecutor(org.slf4j.Logger log, Introspector introspector, Class<?> clazz, Object arg, String property)

Parameters:
  `log` -
  `introspector` -
  `clazz` -
  `arg` -
  `property` -

## Method Details

### discover

protected void discover(Class<?> clazz, Object arg)

Parameters:
  `clazz` -
  `arg` -

### execute

public Object execute(Object o, Object value) throws IllegalAccessException, InvocationTargetException
Description copied from class: `SetExecutor`
Execute method against context.

Specified by:
  `execute` in class `SetExecutor`
Parameters:
  `o` -
  `value` -
Returns:
  The result of the invocation.
Throws:
  `IllegalAccessException`
  `InvocationTargetException`
See Also:
  - `SetExecutor.execute(java.lang.Object, java.lang.Object)`