implement Input Method