The harmonic extension technique with applications to optimal stopping