Package org.springframework.beans.factory.annotation

# Class InjectionMetadata.InjectedElement

java.lang.Object
org.springframework.beans.factory.annotation.InjectionMetadata.InjectedElement

Enclosing class:
  InjectionMetadata

public abstract static class InjectionMetadata.InjectedElement extends Object
A single injected element.

## Field Summary

Fields
Modifier and Type
Field
Description
`protected final boolean`
`isField`
`protected final Member`
`member`
`protected final PropertyDescriptor`
`pd`
`protected Boolean`
`skip`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`InjectedElement(Member member, PropertyDescriptor pd)`

## Method Summary

Modifier and Type
Method
Description
`protected boolean`
`checkPropertySkipping(PropertyValues pvs)`
Check whether this injector's property needs to be skipped due to an explicit property value having been specified.
`protected final void`
`checkResourceType(Class<?> resourceType)`
`protected void`
`clearPropertySkipping(PropertyValues pvs)`
Clear property skipping for this element.
`boolean`
`equals(Object other)`
`final Member`
`getMember()`
`protected Object`
`getResourceToInject(Object target, String requestingBeanName)`
Either this or `inject(java.lang.Object, java.lang.String, org.springframework.beans.PropertyValues)` needs to be overridden.
`protected final Class<?>`
`getResourceType()`
`int`
`hashCode()`
`protected void`
`inject(Object target, String requestingBeanName, PropertyValues pvs)`
Either this or `getResourceToInject(java.lang.Object, java.lang.String)` needs to be overridden.
`protected boolean`
`shouldInject(PropertyValues pvs)`
Whether the property values should be injected.
`String`
`toString()`

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

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Field Details

### member

protected final Member member

### isField

protected final boolean isField

### pd

@Nullable protected final PropertyDescriptor pd

### skip

@Nullable protected volatile Boolean skip

## Constructor Details

### InjectedElement

protected InjectedElement(Member member, @Nullable PropertyDescriptor pd)

## Method Details

### getMember

public final Member getMember()

### getResourceType

protected final Class<?> getResourceType()

### checkResourceType

protected final void checkResourceType(Class<?> resourceType)

### shouldInject

protected boolean shouldInject(@Nullable PropertyValues pvs)
Whether the property values should be injected.

Parameters:
  `pvs` - property values to check
Returns:
  whether the property values should be injected
Since:
  6.0.10

### inject

protected void inject(Object target, @Nullable String requestingBeanName, @Nullable PropertyValues pvs) throws Throwable
Either this or `getResourceToInject(java.lang.Object, java.lang.String)` needs to be overridden.

Throws:
  `Throwable`

### checkPropertySkipping

protected boolean checkPropertySkipping(@Nullable PropertyValues pvs)
Check whether this injector's property needs to be skipped due to an explicit property value having been specified. Also marks the affected property as processed for other processors to ignore it.

### clearPropertySkipping

protected void clearPropertySkipping(@Nullable PropertyValues pvs)
Clear property skipping for this element.

Since:
  3.2.13

### getResourceToInject

@Nullable protected Object getResourceToInject(Object target, @Nullable String requestingBeanName)
Either this or `inject(java.lang.Object, java.lang.String, org.springframework.beans.PropertyValues)` needs to be overridden.

### equals

public boolean equals(@Nullable Object other)

Overrides:
  `equals` in class `Object`

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`

### toString

public String toString()

Overrides:
  `toString` in class `Object`