Thumbs up [Q] How ClockworkMod recovery or other recovery works ?


Can somebody please explain to me how Clockworkmod recovery or any other android recovery works on low level.
I want to know how exactly it installs custom rom on phone ? What does it do with zipped rom file ?

If process is explained in steps then it will be really helpful.