  We present a method to solve optimal stopping problems in infinite horizon
for a L\'evy process when the reward function can be non-monotone.
  To solve the problem we introduce two new objects. Firstly, we define a
random variable $\eta(x)$ which corresponds to the argmax of the reward
function. Secondly, we propose a certain integral transform which can be built
on any suitable random variable. It turns out that this integral transform
constructed from $\eta(x)$ and applied to the reward function produces an easy
and straightforward description of the optimal stopping rule. We check the
consistency of our method with the existing literature, and further illustrate
our results with a new example.
  The method we propose allows to avoid complicated differential or
integro-differential equations which arise if the standard methodology is used.
