1 16 package org.apache.cocoon.portal.coplet.impl; 17 18 import java.util.ArrayList ; 19 import java.util.Iterator ; 20 import java.util.List ; 21 22 import org.apache.cocoon.portal.aspect.AspectDescription; 23 import org.apache.cocoon.portal.factory.impl.AbstractProducibleDescription; 24 25 26 33 public class DefaultCopletDescription 34 extends AbstractProducibleDescription { 35 36 protected List instanceAspects = new ArrayList (); 37 38 public List getInstanceAspectDescriptions() { 39 return this.instanceAspects; 40 } 41 42 public void addInstanceAspectDescription(AspectDescription aspect) { 43 this.instanceAspects.add(aspect); 44 } 45 46 49 public AspectDescription getInstanceAspectDescription(String name) { 50 AspectDescription desc = null; 51 Iterator i = this.instanceAspects.iterator(); 52 while (desc == null && i.hasNext() ) { 53 AspectDescription current = (AspectDescription)i.next(); 54 if ( name.equals(current.getName())) { 55 desc = current; 56 } 57 } 58 return desc; 59 } 60 61 } 62 | Popular Tags |