The set of Gaussian integer
$$ \mathbb{Z} [i] =\left\{ x + iy\mid x, y \in \mathbb{Z}\right\} $$
that is, those complex numbers whose real and imaginary parts are integer numbers, constitutes a so-called integer(or integrity) domain. I would like to know if that is somehow determined by the integer nature of their parts (when the domain is extended, such as to $\mathbb{Z}[\sqrt{-5}]$ , unique factorization collapses.
Thanks in advance.