SmartContractCompile()
Compile Smart Contract Code
Understanding Connector Object
Function Call
SmartContractCompile("Input here Smart Contract Code");Example
Connector connect_ = new Connector("95.111.224.219", 9091);
NodeApi.SmartContractCompileResult SmartContractCompile = connect_.SmartContractCompile("4SFfA1S2xfA3BdgkTn2tK14yDhLuD11RVz78kqx35jct");
Console.WriteLine(SmartContractCompile );Connect_ = Connector("165.22.212.253:9090")
print(Connect_.SmartContractCompile("import com.credits.scapi.annotations.*; import com.credits.scapi.v0.*; public class MySmartContract extends SmartContract { public MySmartContract() {} public String hello2(String say) { return \"Hello\" + say; } }"))
var connect_ = new Connector("194.163.152.177", 9091);
connect_.SmartContractCompile("import com.credits.scapi.annotations.*; import com.credits.scapi.v0.*; public class MySmartContract extends SmartContract { public MySmartContract() {} public String hello2(String say) { return \"Hello\" + say; } }").then((res) => {connect_.Close();console.log(res); });Output of Example
{SmartContractCompileResult}
Status: {APIResponse}
Code: 0
Message: "Success: "
ByteCodeObjects: ...
{ByteCodeObject}
Name: "MySmartContract"
ByteCode: ...
TokenStandard: 0Last updated
Was this helpful?