Refactoring processes that is related frame serialization by applying template method pattern