Example 2 Solve the equation $x^{3}+(1+\sqrt{2}) x^{2}-2=0$.


【Analysis】This is a cubic equation, which cannot be solved by conventional methods. Therefore, we adopt the idea of "reversing the roles", treating the constant $\sqrt{2}$ as an "unknown", while regarding $x$ as a constant.

Let $\sqrt{2}=t$, then the original equation becomes
$$
\begin{array}{l}
x^{3}+(1+t) x^{2}-t^{2}=0 \\
\Rightarrow t^{2}-x^{2} t-\left(x^{3}+x^{2}\right)=0 \\
\Rightarrow t_{1}=-x, t_{2}=x^{2}+x \\
\Rightarrow \sqrt{2}=-x, \sqrt{2}=x^{2}+x \\
\Rightarrow x=-\sqrt{2}, \frac{-1 \pm \sqrt{1+4 \sqrt{2}}}{2} .
\end{array}
$$