spring-geode/src/main/java/org/springframework/geode/core/util/ObjectAwareUtils.java
/**
	 * Returns a {@link Consumer} capable of initializing an {@link BeanFactoryAware} {@link Object}
	 * with the given {@link BeanFactory}.
	 *
	 * The {@link BeanFactoryAware#setBeanFactory(BeanFactory)} method is only called on the {@link BeanFactoryAware}
	 * {@link Object} if the {@link BeanFactory} is not {@literal null}.
	 *
	 * @param beanFactory {@link BeanFactory} set on the {@link BeanFactoryAware} {@link Object} by the {@link Consumer}.
	 * @return a {@link Consumer} capable of initializing an {@link BeanFactoryAware} {@link Object}
	 * with the given {@link BeanFactory}; never {@literal null}.
	 * @see org.springframework.beans.factory.BeanFactoryAware
	 * @see org.springframework.beans.factory.BeanFactory
	 * @see java.util.function.Consumer
	 */
Returns a  Consumer capable of initializing an  BeanFactoryAware  Object
with the given  BeanFactory.



@param beanFactory  BeanFactory set on the  BeanFactoryAware  Object by the  Consumer.
@return a  Consumer capable of initializing an  BeanFactoryAware  Object
with the given  BeanFactory; never  null.
Returns a Consumer capable of initializing an BeanFactoryAware Object with the given BeanFactory . @param beanFactory BeanFactory set on the BeanFactoryAware Object by the Consumer . @return a Consumer capable of initializing an BeanFactoryAware Object with the given BeanFactory ; never null .
public static @NonNull Consumer<Object> beanFactoryAwareObjectInitializer(@Nullable BeanFactory beanFactory) {
		return beanFactory == null ? NO_OP : target -> {
			if (target instanceof BeanFactoryAware) {
				((BeanFactoryAware) target).setBeanFactory(beanFactory);
			}
		};
	}
public static @ NonNull Consumer < Object > beanFactoryAwareObjectInitializer ( @ Nullable BeanFactory beanFactory ) { return beanFactory == null ? NO_OP : target -> { if ( target instanceof BeanFactoryAware ) { ( ( BeanFactoryAware ) target ) . setBeanFactory ( beanFactory ) ; } } ; }
Returns a {@link Consumer} capable of initializing an {@link BeanFactoryAware} {@link Object}
 with the given {@link BeanFactory}.
Returns a { @link Consumer } capable of initializing an { @link BeanFactoryAware } { @link Object } with the given { @link BeanFactory } .