Refactoring from project PIN #1

Signed-off-by: Youngki Ahn <avej.com@gmail.com>