create class TpResultChain. move related logic into TpResultChain