This is the stateful Hello World of Accord Project Templates. Executing the clause will simply echo back the text that occurs after the string `Hello` prepended to text that is passed in the request along with the number of times the clause has been called.
Hello World State
This is the stateful Hello World of Accord Project Templates. Executing the clause will simply echo back the text that occurs after the string Hello
prepended to text that is passed in the request along with the number of times the clause has been called.
Name of the person to greet: "Fred Blogs".
Thank you!
Name of the person to greet: "Fred Blogs".
Thank you!
Name of the person to greet: {{name}}.
Thank you!
{
"$class": "org.accordproject.helloworldstate.HelloWorldClause",
"clauseId": "0f9c4d1e-6ecd-4ae0-ab51-dcdcca6aa554",
"name": "Fred Blogs"
}
namespace org.accordproject.helloworldstate
import org.accordproject.cicero.contract.* from https://models.accordproject.org/cicero/contract.cto
import org.accordproject.cicero.runtime.* from https://models.accordproject.org/cicero/runtime.cto
transaction MyRequest extends Request {
o String input
}
transaction MyResponse extends Response {
o String output
}
asset HelloWorldState extends AccordContractState {
o Double counter
}
/**
* The template model
*/
asset HelloWorldClause extends AccordClause {
/**
* The name for the clause
*/
o String name
}