예제 #1
0
        public static TransactionPayloadLCS FromScript(PayloadLCS payloadLCS)
        {
            var script = new ScriptLCS();

            script.Code    = payloadLCS.Code;
            script.Modules = payloadLCS.Modules;
            script.TransactionArguments = payloadLCS.TransactionArguments;
            return(new TransactionPayloadLCS
            {
                PayloadType = TransactionPayloadType.Script,
                Script = script
            });
        }
예제 #2
0
        public static TransactionPayloadLCS FromProgram(PayloadLCS payloadLCS)
        {
            var program = new ProgramLCS();

            program.Code    = payloadLCS.Code;
            program.Modules = payloadLCS.Modules;
            program.TransactionArguments = payloadLCS.TransactionArguments;
            return(new TransactionPayloadLCS
            {
                PayloadType = TransactionPayloadType.Program,
                Program = program
            });
        }