Spring for Apache Hadoop

org.springframework.data.hadoop.fs
Class CustomResourceLoaderRegistrar

java.lang.Object
  extended by org.springframework.data.hadoop.fs.CustomResourceLoaderRegistrar
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.config.BeanFactoryPostProcessor, org.springframework.context.ApplicationContextAware, org.springframework.core.Ordered

public class CustomResourceLoaderRegistrar
extends java.lang.Object
implements org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.config.BeanFactoryPostProcessor, org.springframework.core.Ordered

Utility class that overrides the built-in ResourceEditor to allow HdfsResourceLoader to be searched first. Also sets ResourceLoader for the Application context.

Author:
Costin Leau, Janne Valkealahti

Field Summary
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
CustomResourceLoaderRegistrar()
           
 
Method Summary
 int getOrder()
           
 void postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory)
           
 void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
           
 void setLoader(org.springframework.core.io.support.ResourcePatternResolver loader)
          Sets the resource pattern loader.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CustomResourceLoaderRegistrar

public CustomResourceLoaderRegistrar()
Method Detail

postProcessBeanFactory

public void postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory)
                            throws org.springframework.beans.BeansException
Specified by:
postProcessBeanFactory in interface org.springframework.beans.factory.config.BeanFactoryPostProcessor
Throws:
org.springframework.beans.BeansException

getOrder

public int getOrder()
Specified by:
getOrder in interface org.springframework.core.Ordered

setApplicationContext

public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
                           throws org.springframework.beans.BeansException
Specified by:
setApplicationContext in interface org.springframework.context.ApplicationContextAware
Throws:
org.springframework.beans.BeansException

setLoader

public void setLoader(org.springframework.core.io.support.ResourcePatternResolver loader)
Sets the resource pattern loader.

Parameters:
loader - the new resource pattern loader

Spring for Apache Hadoop