The methods shown below in FIgure 1 return an iterator. I would like to see the methods return the collection rather than an iterator for these reasons:
1) it is easier to get the iterator from the collection than the other way around. To get the collection from the iterator, I would have to create a collection and go through the iterator 2) there are methods on the collection, such as size(), that are not on the iterator, and other things you can do to collection, such as sort, reate new collections, etc. Writing test cases I often want to compare one collection to another collection using the equals() method on the collection. 3) The type of collection may give some information that is lost when the iterator is returned. For example, if the type is a Sorted type, then that conveys some information that is not there in the iterator. -Robert Blumen ============================================================================================= Figure 1 ======== org.acegisecurity.intercept.ObjectDefinitionSource: getConfigAttributeDefinitions org.acegisecurity.intercept.method.MethodDefinitionAttributes: getConfigAttributeDefinitions org.acegisecurity.intercept.method.MethodDefinitionMap: getConfigAttributeDefinitions org.acegisecurity.intercept.web.RegExpBasedFilterInvocationDefinitionMap: getConfigAttributeDefinitions org.acegisecurity.intercept.web.FilterInvocationDefinitionDecorator: getConfigAttributeDefinitions org.acegisecurity.intercept.web.PathBasedFilterInvocationDefinitionMap: getConfigAttributeDefinitions org.acegisecurity.ConfigAttributeDefinition: getConfigAttributes org.acegisecurity.ui.savedrequest.SavedRequest: getHeaderNames org.acegisecurity.ui.savedrequest.SavedRequest: getHeaderValues org.acegisecurity.ui.savedrequest.SavedRequest: getLocales org.acegisecurity.ui.savedrequest.SavedRequest: getParameterNames ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Home: http://acegisecurity.org Acegisecurity-developer mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/acegisecurity-developer
