💡Pirichain Smart Scenario

Pirichain smart scenario system has capacity of analyzing and processing data on the basis of typescript and javascript. The information has been added by the companies to allow the queries that the companies want with the smart scenarios written by the software experts. Besides query, it is possible to run different scenarios by creating certain conditions. The diagram in Figure 2.1 shows the relationship of smart scenarios with the whole system. In addition, the actions that smart scenarios can do on the system are also explained in the boxes in the diagram.

Pirichain smart scenarios undertake tasks that cover the entire system. According to the scenario structure to be written on the system, whether information transfers are made or the assets are sent to the desired addresses according to a certain condition, this completely changes according to the modeling to be determined by the users.

As the simplest form of expression; information added to the block network, flour, water, sugar, oil etc. Considering that they are products, either pies or breads can be made with smart scenarios. This is entirely up to the developer's own needs and abilities. Whatever the software requirement analysis requires, the desired data modeling can be done with Pirichain's ready-made functions, and the needs can be shaped with complex queries. Pirichain scenario development interface is shown in Figure 2.2 (code block below).

async function init(param1,param2,param3)
{
// Your code goes here...
 // You can execute only you 

 if (EXECUTER_ADDRESS!==OWNER_ADDRESS) 
 return "You dont have permission for execute this scenario!"; 

 var dummyTest=await Transaction.getBalance(EXECUTER_ADDRESS);
 return dummyTest;
}

Last updated