avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From blorit...@apache.org
Subject cvs commit: jakarta-avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl AbstractContainer.java
Date Tue, 04 Feb 2003 20:33:33 GMT
bloritsch    2003/02/04 12:33:32

  Modified:    fortress/src/java/org/apache/avalon/fortress/impl
                        AbstractContainer.java
  Log:
  check to make sure we are not adding anything using a reserved ID
  
  Revision  Changes    Path
  1.7       +7 -1      jakarta-avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/AbstractContainer.java
  
  Index: AbstractContainer.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/fortress/src/java/org/apache/avalon/fortress/impl/AbstractContainer.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- AbstractContainer.java	4 Feb 2003 19:39:36 -0000	1.6
  +++ AbstractContainer.java	4 Feb 2003 20:33:32 -0000	1.7
  @@ -267,6 +267,12 @@
               throw new IllegalArgumentException( message );
           }
   
  +        if( DEFAULT_ENTRY.equals(metaData.getName()) ||
  +            SELECTOR_ENTRY.equals(metaData.getName()) )
  +        {
  +            throw new IllegalArgumentException("Using a reserved id name" + metaData.getName());
  +        }
  +
           // create a handler for the combo of Role+MetaData
           final ComponentHandler handler =
               getComponentHandler( roleEntry, metaData );
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: avalon-cvs-unsubscribe@jakarta.apache.org
For additional commands, e-mail: avalon-cvs-help@jakarta.apache.org


Mime
View raw message