public class FileSystemFactoryBean extends Object implements InitializingBean, DisposableBean, FactoryBean<FileSystem>
FileSystem instances. Useful for interacting with
 HDFS from outside a Map Reduce job. If no parameter is given, a file system using the installed
 Hadoop defaults will be created.| Constructor and Description | 
|---|
| FileSystemFactoryBean() | 
| Modifier and Type | Method and Description | 
|---|---|
| void | afterPropertiesSet() | 
| void | destroy() | 
| FileSystem | getObject() | 
| Class<?> | getObjectType() | 
| boolean | isSingleton() | 
| void | setClose(boolean close)Indicates whether the Hadoop file systems should be closed once this factory is destroyed. | 
| void | setCloseAll(boolean closeAll)Indicates whether all the Hadoop file systems should be closed once this factory is destroyed. | 
| void | setConfiguration(Configuration configuration)Sets the Hadoop configuration for this file system. | 
| void | setUri(URI uri)Sets the URI (if available) for this file system. | 
| void | setUser(String user)Sets the user impersonation (optional) for creating this file-system. | 
public void afterPropertiesSet()
                        throws Exception
afterPropertiesSet in interface InitializingBeanExceptionpublic void destroy()
             throws Exception
destroy in interface DisposableBeanExceptionpublic FileSystem getObject() throws Exception
getObject in interface FactoryBean<FileSystem>Exceptionpublic Class<?> getObjectType()
getObjectType in interface FactoryBean<FileSystem>public boolean isSingleton()
isSingleton in interface FactoryBean<FileSystem>public void setConfiguration(Configuration configuration)
configuration - The configuration to set.public void setUri(URI uri)
uri - The uri to set.public void setUser(String user)
user - user/group informationpublic void setCloseAll(boolean closeAll)
closeAll - the close allFileSystem.closeAll()public void setClose(boolean close)
close - closeFileSystem.close()