This sensor takes a continuous distance reading and reports the distance as an analog voltage with a distance range of 10cm (~4") to 80cm (~30"). The interface is 3-wire with power, ground and the output voltage.
Datasheet : GP2Y0A21YK0F
Application Note From Sharp Microelectronics
Range Conversion Equation