public static class ConstructorArgumentValues.ValueHolder extends java.lang.Object implements BeanMetadataElement
Modifier and Type | Field and Description |
---|---|
private boolean |
converted |
private java.lang.Object |
convertedValue |
private java.lang.String |
name |
private java.lang.Object |
source |
private java.lang.String |
type |
private java.lang.Object |
value |
Constructor and Description |
---|
ValueHolder(java.lang.Object value)
Create a new ValueHolder for the given value.
|
ValueHolder(java.lang.Object value,
java.lang.String type)
Create a new ValueHolder for the given value and type.
|
ValueHolder(java.lang.Object value,
java.lang.String type,
java.lang.String name)
Create a new ValueHolder for the given value, type and name.
|
Modifier and Type | Method and Description |
---|---|
private boolean |
contentEquals(ConstructorArgumentValues.ValueHolder other)
Determine whether the content of this ValueHolder is equal
to the content of the given other ValueHolder.
|
private int |
contentHashCode()
Determine whether the hash code of the content of this ValueHolder.
|
ConstructorArgumentValues.ValueHolder |
copy()
Create a copy of this ValueHolder: that is, an independent
ValueHolder instance with the same contents.
|
java.lang.Object |
getConvertedValue()
Return the converted value of the constructor argument,
after processed type conversion.
|
java.lang.String |
getName()
Return the name of the constructor argument.
|
java.lang.Object |
getSource()
Return the configuration source
Object for this metadata element
(may be null ). |
java.lang.String |
getType()
Return the type of the constructor argument.
|
java.lang.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(java.lang.Object value)
Set the converted value of the constructor argument,
after processed type conversion.
|
void |
setName(java.lang.String name)
Set the name of the constructor argument.
|
void |
setSource(java.lang.Object source)
Set the configuration source
Object for this metadata element. |
void |
setType(java.lang.String type)
Set the type of the constructor argument.
|
void |
setValue(java.lang.Object value)
Set the value for the constructor argument.
|
@Nullable private java.lang.Object value
@Nullable private java.lang.String type
@Nullable private java.lang.String name
@Nullable private java.lang.Object source
private boolean converted
@Nullable private java.lang.Object convertedValue
public ValueHolder(@Nullable java.lang.Object value)
value
- the argument valuepublic ValueHolder(@Nullable java.lang.Object value, @Nullable java.lang.String type)
value
- the argument valuetype
- the type of the constructor argumentpublic ValueHolder(@Nullable java.lang.Object value, @Nullable java.lang.String type, @Nullable java.lang.String name)
value
- the argument valuetype
- the type of the constructor argumentname
- the name of the constructor argumentpublic void setValue(@Nullable java.lang.Object value)
PropertyPlaceholderConfigurer
@Nullable public java.lang.Object getValue()
public void setType(@Nullable java.lang.String type)
@Nullable public java.lang.String getType()
public void setName(@Nullable java.lang.String name)
@Nullable public java.lang.String getName()
public void setSource(@Nullable java.lang.Object source)
Object
for this metadata element.
The exact type of the object will depend on the configuration mechanism used.
@Nullable public java.lang.Object getSource()
BeanMetadataElement
Object
for this metadata element
(may be null
).getSource
in interface BeanMetadataElement
public boolean isConverted()
true
),
or whether the value still needs to be converted (false
).public void setConvertedValue(@Nullable java.lang.Object value)
@Nullable public java.lang.Object getConvertedValue()
private boolean contentEquals(ConstructorArgumentValues.ValueHolder other)
Note that ValueHolder does not implement equals
directly, to allow for multiple ValueHolder instances with the
same content to reside in the same Set.
private int contentHashCode()
Note that ValueHolder does not implement hashCode
directly, to allow for multiple ValueHolder instances with the
same content to reside in the same Set.
public ConstructorArgumentValues.ValueHolder copy()