  We give an abstract approach to finite Ramsey theory and prove a general
Ramsey-type theorem. We deduce from it a self-dual Ramsey theorem, which is a
new result naturally generalizing both the classical Ramsey theorem and the
dual Ramsey theorem of Graham and Rothschild. In fact, we recover the pure
finite Ramsey theory from our general Ramsey-type result in the sense that the
classical Ramsey theorem, the Hales--Jewett theorem (with Shelah's bounds), the
Graham--Rothschild theorem, the versions of these results for partial rigid
surjections due to Voigt, and the new self-dual Ramsey theorem are all obtained
as iterative applications of the general result.
