The One Question bounty closes Thursday 10 December.

Join in
We Them Media logo We Them Media Support us

Web3bridge Students (Cohort XI) Share What They’ve Learned: Calls

The picture loads from YouTube. The player loads only when you press Play. Turn on captions in the player if you need them.

Students explain low-level calls in Solidity. They describe the three kinds, call, static call and delegate call. Static call is read-only, call can invoke other contracts or send Ether, and delegate call lets one contract run another's code to update its own state.

Not by We Them Media Channel: Web3Bridge. Published Sunday 29 December 2024.

Titles are the owner’s. It plays from their channel.

Transcript

This transcript may contain errors. This video belongs to Web3Bridge. Letters mark each change of speaker.

These are the speakers’ own words. We have not checked their claims.

0:00 A: This video is proudly brought to you by VirtueBridge with LINKS, our official sponsors for Cohort 11.

0:08 B: My team and I, we are talking about calls. What are low-level calls? Low-level calls are used to interact with other contracts or send Ether without using high-level constructs or functions and methods. So, uh, we have 3 types of low-level calls. We have what we call delegate call, static call, and we have, um, call. So static call are just used to make read-only operations only. They don't mutate the states.

0:39 C: The .call function can be used to interact with other contracts. So it can be used to invoke functions on other contracts or send Ether. When you use the .call function to interact with other contracts, you use it to invoke the functions of those contracts to interact with it. So what are delegate calls? Delegate calls are a type of low-level calls. They are calls that are used to be able to interact with other smart contracts. So for instance, let's say we have 2 contracts, Contract A and Contract B, and we declare- we deploy Contract B, then we now deploy Contract A. So let's say now Contract A needs to be able to update its, its own state. So what Contract A is going to do is to make a delegate call to Contract B and get a result from that Contract B and be able to update its own state. States.

More from this hub

Something wrong, or a video you want off this page? Write to wethem.xyz@gmail.com and it is fixed or taken down within 48 hours.