In triangle $ABC$ we have $\angle C = 90^০$ and $AC = BC$. Furthermore $M$ is an interior pont in the triangle so that $MC = 1 , MA = 2$ and $MB =\sqrt2$. The value of $AB$ can be written as $\sqrt z$. What is the value of $z$ ?