Pirichain Whitepaper
🌍 Pirichain🔮 Explorer🧰 API
  • 👋What is Pirichain?
  • Overview
    • 🔮Upcoming Projects
  • PIRICHAIN INFRASTRUCTURE
    • 🛤️Pirichain Infrastructure
      • 🅱️1.1. Pirichain specific block fields
      • ⏩1.2. Pirichain-specific transaction fields
      • 📒1.3. Pirichain Wallet Structure
        • 👤Personel Wallet
        • 💼Business Wallets
      • 👉1.4. Creation of Pirichain Transaction
      • 📎1.5. A New Concept in Blockchains! Adding Data to the Blockchain
      • 💠1.6. Pirichain's Web Server Services Structure
      • 🤝1.7. Consensus at Pirichain
  • PIRICHAIN SMART SCENARIO
    • 💡Pirichain Smart Scenario
      • 🌀2.1. Pirichain Smart Scenario Virtual Machine
        • ⚗️2.1.1. Pirichain Example Smart Scenarios
          • 🩺2.1.1.1. A Scenario on Health
          • 📦2.1.1.2. A Scenario on Inventory
        • 🎓2.1.2. Scenario of calculating the semester average with course grades and coding example
  • PIRICHAIN PLATFORMS
    • 🖥️3.1. Pirichain Desktop Wallet & Database Bridging Application (Wallet & DataBridge Application)
  • PIRICHAIN TRANSACTION TYPES
    • ⛓️4. Pirichain Transaction Types
  • PIRICHAIN COMMISSION
    • 🔥5. Pirichain Commission
  • PIRICHAIN REWARD DISTRIBUTION
    • 🎁6. Pirichain Reward Distribution
  • PIRI Coin Holders
    • 👥PIRI Tokenomics
  • 📍Pirichain Projected Roadmap
  • ⬆️Updates
    • 🚀New Fee Mechanism in Pirichain
  • REFERENCES
  • 🌎Pirichain Showcase
  • 🔎Pirichain Explorer
  • 🌐Pirichain Scanner
  • ✒️Pirichain Master Thesis
Powered by GitBook
On this page

Was this helpful?

  1. PIRICHAIN SMART SCENARIO

Pirichain Smart Scenario

Previous1.7. Consensus at PirichainNext2.1. Pirichain Smart Scenario Virtual Machine

Last updated 2 years ago

Was this helpful?

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;
}
💡
Figure 2.1: Pirichain Smart scenario relationship with modules