Did refactoring; devided parseType().

Signed-off-by: Kouhei Maeda <mkouhei@palmtb.net>