read function implemented. - Pucong