CHG: modify structure and some implements