Questions tagged [library]

Libraries are reusable code. In the context of smart contracts, they are deployed only once at a specific address and their code is reused using DELEGATECALL.

Filter by
Sorted by
Tagged with
4
votes
1answer
557 views

How to access a mapping in a library?

library Lib{ struct Data { mapping (uint => uint) a; } function inc(Data self) internal{ self.a[0] =+1; } } contract Example{ address recipient = ...
4
votes
4answers
5k views

Ethereum library for iOS/Android?

Are there any existing native libraries (not whole wallets, I do not need a UI but want to sign transactions and call smart contract functions embedded in another app) for iOS or Android? If not, are ...
9
votes
1answer
3k views

Finding and Using Solidity Libraries (ie. Math functions)

How do I find and use any existing Solidity libraries like you might in Javascript? For example, Math functions: How do I implement the equivalent of Math.sqrt(x) in a solidity function? Related: ...
7
votes
3answers
3k views

How to import solidity libraries in mix?

Working in the MIX environment, I'd like to try using a libraries and contracts defined in different files. However, the main contract always gets an error from MIX, no matter how I define the "...
4
votes
1answer
325 views

Out of gas error deploying library

The following code is compiled with solc 0.3 with correct --libraries linking and deployed to morden. Math library is deployed just fine and can be accessed. However A doesn't get deployed on morden ...
1
vote
1answer
602 views

Is there something like bitcore for Ethereum?

In Bitcoin there is a library named Bitcore. It helps abstract away a number of details, including using direct RPC commands. Is there something like Bitcore for Ethereum? Or do I need to use JSON-...
2
votes
2answers
564 views

How can I program my DApp to tell my user that their action/transaction has been confirmed?

Take an example of a voting DApp. A user clicks on a vote button, then behind the scenes the transaction containing the vote gets mined on the blockchain. The DApp then wants to alert('You have ...
16
votes
5answers
18k views

Is there a C# implementation available for Ethereum?

Is there a C# / .NET / Mono implementation available for Ethereum to interact with nodes and/or the blockchain?
8
votes
1answer
479 views

How to handle library function prototype changes?

One great thing about using a library is that the library code can be modified, and as long as the api function prototype stays the same, all we need to do is point to the new address of the updated ...

1 2
3