Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| The Spring Framework
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.beans.factory.config
Class ConstructorArgumentValues.ValueHolder

    java.lang.Object
      org.springframework.beans.factory.config.ConstructorArgumentValues.ValueHolder

All Implemented Interfaces:
  BeanMetadataElement

Enclosing class:
  ConstructorArgumentValues

    public static class ConstructorArgumentValues.ValueHolder

extends Object
implements BeanMetadataElement

Holder for a constructor argument value, with an optional type attribute indicating the target type of the actual constructor argument.

Constructor Summary
`ConstructorArgumentValues.ValueHolder(Object value)` Create a new ValueHolder for the given value.
`ConstructorArgumentValues.ValueHolder(Object value, String type)` Create a new ValueHolder for the given value and type.

Method Summary
`ConstructorArgumentValues.ValueHolder` | `copy()` Create a copy of this ValueHolder: that is, an independent ValueHolder instance with the same contents.
`Object` | `getConvertedValue()` Return the converted value of the constructor argument, after processed type conversion.
`Object` | `getSource()` Return the configuration source `Object` for this metadata element (may be `null`).
`String` | `getType()` Return the type of the constructor argument.
`Object` | `getValue()` Return the value for the constructor argument.
`boolean` | `isConverted()` Return whether this holder contains a converted value already (`true`), or whether the value still needs to be converted (`false`).
`void` | `setConvertedValue(Object value)` Set the converted value of the constructor argument, after processed type conversion.
`void` | `setSource(Object source)` Set the configuration source `Object` for this metadata element.
`void` | `setType(String type)` Set the type of the constructor argument.
`void` | `setValue(Object value)` Set the value for the constructor argument.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ConstructorArgumentValues.ValueHolder

    public ConstructorArgumentValues.ValueHolder(Object value)

  Create a new ValueHolder for the given value.

  Parameters:
    `value` - the argument value

### ConstructorArgumentValues.ValueHolder

    public ConstructorArgumentValues.ValueHolder(Object value,
                                                 String type)

  Create a new ValueHolder for the given value and type.

  Parameters:
    `value` - the argument value
    `type` - the type of the constructor argument

Method Detail

### setValue

    public void setValue(Object value)

  Set the value for the constructor argument. Only necessary for manipulating a registered value, for example in BeanFactoryPostProcessors.

  See Also:
    `PropertyPlaceholderConfigurer`

### getValue

    public Object getValue()

  Return the value for the constructor argument.

### setType

    public void setType(String type)

  Set the type of the constructor argument. Only necessary for manipulating a registered value, for example in BeanFactoryPostProcessors.

  See Also:
    `PropertyPlaceholderConfigurer`

### getType

    public String getType()

  Return the type of the constructor argument.

### setSource

    public void setSource(Object source)

  Set the configuration source `Object` for this metadata element.

  The exact type of the object will depend on the configuration mechanism used.

### getSource

    public Object getSource()

  Description copied from interface: `BeanMetadataElement`
  Return the configuration source `Object` for this metadata element (may be `null`).

  Specified by:
    `getSource` in interface `BeanMetadataElement`

### isConverted

    public boolean isConverted()

  Return whether this holder contains a converted value already (`true`), or whether the value still needs to be converted (`false`).

### setConvertedValue

    public void setConvertedValue(Object value)

  Set the converted value of the constructor argument, after processed type conversion.

### getConvertedValue

    public Object getConvertedValue()

  Return the converted value of the constructor argument, after processed type conversion.

### copy

    public ConstructorArgumentValues.ValueHolder copy()

  Create a copy of this ValueHolder: that is, an independent ValueHolder instance with the same contents.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| The Spring Framework
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002-2008 The Spring Framework.