  We study a noncommutative analogue of a spacetime foliated by spacelike
hypersurfaces, in both Riemannian and Lorentzian signatures. First, in the
classical commutative case, we show that the canonical Dirac operator on the
total spacetime can be reconstructed from the family of Dirac operators on the
hypersurfaces. Second, in the noncommutative case, the same construction
continues to make sense for an abstract family of spectral triples. In the case
of Riemannian signature, we prove that the construction yields in fact a
spectral triple, which we call a product spectral triple. In the case of
Lorentzian signature, we correspondingly obtain a 'Lorentzian spectral triple',
which can also be viewed as the 'reverse Wick rotation' of a product spectral
triple. This construction of 'Lorentzian spectral triples' fits well into the
Krein space approach to noncommutative Lorentzian geometry.
