import java.util.*; interface Item {} interface Container {} interface CompositeItem {} interface CompositeContainer {} public abstract aspect Broke { private C CompositeItem.container; public List CompositeContainer.itemList = new ArrayList(); public CompositeContainer CompositeContainer.addItem(I i) { itemList.add(i); i.container = this; return this; } }