Cadence at a Glance

Resources to manage ownership

pub resource NFT {
pub let id: UInt64
pub var metadata: {String: String}
...
}
  • Resources can only exist in one exact place at one exact time
  • Resources cannot be copied
  • Resources have to be explicitly destroyed
let myResource <- create NFT(...)

Capabilities for access-control

account.getCapability<...>(/public/MyCapability).borrow()

Interact with transactions and scripts

transaction {
prepare (acct: AuthAccount) {
...
}
execute {
...
}
}
pub fun main () {
log("Hello world!")
}

Further readings

--

--

--

CTO & Co-Founder of https://zeedz.io - Advisor at Flow blockchain

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Summer OSPP with CHAOSS — Week 3 & 4

Getting started with Containers using Docker and Azure Container Instances(ACI)

How to land your first job as a game developer: the resume

Performance Testing with Gatling

Programming Should Be About Transforming Data

Step-by-Step Rotating Radar Charts in Power BI

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Benjamin Ebner

Benjamin Ebner

CTO & Co-Founder of https://zeedz.io - Advisor at Flow blockchain

More from Medium

NFTs Go Green

Leap into WEB3 via ETHGlobal Hackathon

官方 | 用于去中心化存储的 Web3 浏览器

Intro to LIQNFT