internal override void InternalInitialize(ISmartContractBridgeContext bridgeContext) { if (Context != null) { throw new InvalidOperationException(); } Context = new CSharpSmartContractContext(bridgeContext); State.Context = Context; }
public static T Call <T>(this CSharpSmartContractContext context, Address address, string methodName, IMessage message) where T : IMessage <T>, new() { return(context.Call <T>(address, methodName, ConvertToByteString(message))); }
public static void SendVirtualInline(this CSharpSmartContractContext context, Hash fromVirtualAddress, Address toAddress, string methodName, IMessage message) { context.SendVirtualInline(fromVirtualAddress, toAddress, methodName, ConvertToByteString(message)); }
public static void Fire <T>(this CSharpSmartContractContext context, T eventData) where T : IEvent <T> { context.FireLogEvent(eventData.ToLogEvent(context.Self)); }