public void setReader ( String chain , String type , String path , boolean recursive , Map < String , String > params ) throws Exception { if ( ( type != null && ! "" . equals ( type . trim ( ) ) ) || ( path != null && ! "" . equals ( path . trim ( ) ) ) ) { long startTime = System . currentTimeMillis ( ) ; Exception exception = null ; if ( ! cfg . exists ( ) ) { init ( ) ; } userDir = new File ( System . getProperty ( "user.dir" ) ) . getAbsolutePath ( ) ; System . setProperty ( "user.dir" , options . getExecutionDirectory ( ) . getAbsolutePath ( ) ) ; try { ConfigurationManager manager = new ConfigurationManager ( cfg , false ) ; ProjectConfigurationProvider cfgProvider = manager . getProjectConfigurationProvider ( ) ; cfgProvider . setReader ( chain , type , path , recursive , params ) ; } catch ( Exception e ) { exception = e ; } finally { System . setProperty ( "user.dir" , userDir ) ; updateMsg ( startTime , exception ) ; } } }
Sets an specific reader for an specific chain .