this.getSpellAbility().getModes().setMaxModes(2);
// Destroy all artifacts;
this.getSpellAbility().addEffect(new DestroyAllEffect(new FilterArtifactPermanent("artifacts")));
// or destroy all enchantments;
Mode mode = new Mode();
mode.getEffects().add(new DestroyAllEffect(new FilterEnchantmentPermanent("enchantments")));
this.getSpellAbility().getModes().addMode(mode);
// or destroy all creatures with converted mana cost 3 or less;
mode = new Mode();
mode.getEffects().add(new DestroyAllEffect(filter3orLess));
this.getSpellAbility().getModes().addMode(mode);