We introduce layer systems for proving generalizations of the modularity of
confluence for first-order rewrite systems. Layer systems specify how terms can
be divided into layers. We establish structural conditions on those systems
that imply confluence. Our abstract framework covers known results like
modularity, many-sorted persistence, layer-preservation and currying. We
present a counterexample to an extension of persistence to order-sorted
rewriting and derive new sufficient conditions for the extension to hold. All
our proofs are constructive