User: mulder  
  Date: 00/10/24 16:16:29

  Modified:    src/main/org/jboss/ejb/plugins/jaws/metadata
                        JawsXmlFileLoader.java
  Log:
  Move the standardjboss.xml and standardjaws.xml files to the conf
  directory.  This make it much easier to change global defaults
  (such as the JRMP JDK version, optimizations, RMI port, etc.)
  
  Add the RMI port option to standardjboss.xml
  
  Revision  Changes    Path
  1.3       +19 -19    
jboss/src/main/org/jboss/ejb/plugins/jaws/metadata/JawsXmlFileLoader.java
  
  Index: JawsXmlFileLoader.java
  ===================================================================
  RCS file: 
/products/cvs/ejboss/jboss/src/main/org/jboss/ejb/plugins/jaws/metadata/JawsXmlFileLoader.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- JawsXmlFileLoader.java    2000/09/28 01:17:05     1.2
  +++ JawsXmlFileLoader.java    2000/10/24 23:16:28     1.3
  @@ -22,56 +22,56 @@
   
   
   /**
  - *   <description> 
  - *      
  + *   <description>
  + *
    *   @see <related>
    *   @author <a href="[EMAIL PROTECTED]">Sebastien Alborini</a>
  - *   @version $Revision: 1.2 $
  + *   @version $Revision: 1.3 $
    */
   public class JawsXmlFileLoader {
  -     
  +
        // Attributes ----------------------------------------------------
       private ApplicationMetaData application;
        private ClassLoader classLoader;
       private Log log;
  -     
  -     
  +
  +
        // Constructors --------------------------------------------------
        public JawsXmlFileLoader(ApplicationMetaData app, ClassLoader cl, Log l) {
                application = app;
                classLoader = cl;
  -             log = l;                
  +             log = l;
        }
  -   
  -     
  +
  +
        // Public --------------------------------------------------------
       public JawsApplicationMetaData load() throws DeploymentException {
  -         
  +
                // first create the metadata
                JawsApplicationMetaData jamd = new 
JawsApplicationMetaData(application, classLoader);
  -             
  +
                // Load standardjaws.xml from the default classLoader
                // we always load defaults first
  -             URL stdJawsUrl = getClass().getResource("standardjaws.xml");
  -             
  +             URL stdJawsUrl = classLoader.getResource("standardjaws.xml");
  +
                if (stdJawsUrl == null) throw new DeploymentException("No 
standardjaws.xml found");
  -                             
  +
                log.debug("Loading standardjaws.xml : " + stdJawsUrl.toString());
                Document stdJawsDocument = XmlFileLoader.getDocument(stdJawsUrl);
                jamd.importXml(stdJawsDocument.getDocumentElement());
  -             
  +
                // Load jaws.xml if provided
                URL jawsUrl = classLoader.getResource("META-INF/jaws.xml");
  -             
  +
                if (jawsUrl != null) {
                        log.debug(jawsUrl.toString() + " found. Overriding defaults");
                        Document jawsDocument = XmlFileLoader.getDocument(jawsUrl);
                        jamd.importXml(jawsDocument.getDocumentElement());
  -             }       
  -             
  +             }
  +
                // this can only be done once all the beans are built
                jamd.init();
  -             
  +
                return jamd;
      }
   }
  
  
  

Reply via email to