1 22 package org.jboss.mx.loading; 23 24 import java.io.ByteArrayInputStream ; 25 import java.util.Properties ; 26 27 import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfigParser; 28 29 37 public class HeirarchicalLoaderRepository3ConfigParser 38 implements LoaderRepositoryConfigParser 39 { 40 48 public void configure(LoaderRepository repository, String config) 49 throws Exception 50 { 51 HeirarchicalLoaderRepository3 hlr3 = (HeirarchicalLoaderRepository3) repository; 52 Properties props = new Properties (); 53 ByteArrayInputStream bais = new ByteArrayInputStream (config.getBytes()); 54 props.load(bais); 55 String java2ParentDelegation = props.getProperty("java2ParentDelegation"); 56 if( java2ParentDelegation == null ) 57 { 58 java2ParentDelegation = props.getProperty("java2ParentDelegaton", "false"); 60 } 61 boolean useParentFirst = Boolean.valueOf(java2ParentDelegation).booleanValue(); 62 hlr3.setUseParentFirst(useParentFirst); 63 } 64 } 65 | Popular Tags |