Issue #37 Moved CodecChain functions to prototype