-public class CompositeModification implements Modification {
- private final List<Modification> modifications = new ArrayList<>();
-
- @Override
- public void apply(DOMStoreWriteTransaction transaction) {
- for(Modification modification : modifications){
- modification.apply(transaction);
- }
- }
-
- public void addModification(Modification modification){
- modifications.add(modification);
- }
+public interface CompositeModification extends Modification {
+ /**
+ * Get a list of modifications contained by this composite.
+ *
+ * @return an immutable list of modifications
+ */
+ List<Modification> getModifications();