blockchain
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
blockchain [2017/09/21 08:17] – [Commands] stephen | blockchain [2017/12/01 01:19] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Blockchain ====== | ====== Blockchain ====== | ||
+ | |||
+ | ===== Links ===== | ||
+ | |||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | |||
+ | ===== General Notes ===== | ||
+ | |||
+ | * Make sure the constructor of the contract has the correct access modifiers: | ||
+ | < | ||
+ | function MegaContract() public payable { | ||
+ | </ | ||
+ | |||
+ | ==== Security ==== | ||
+ | |||
+ | To do anything that requires gas, either unlock the account beforehand with the password: | ||
+ | |||
+ | < | ||
+ | var address = " | ||
+ | var password = " | ||
+ | var web3 = new Web3(); | ||
+ | var unlockAccountResult = await web3.Personal.UnlockAccount.SendRequestAsync(address, | ||
+ | Assert.IsTrue(unlockAccountResult); | ||
+ | </ | ||
+ | |||
+ | Or use the private key to create the Web3 object: | ||
+ | |||
+ | < | ||
+ | var privateKey = " | ||
+ | var web3 = new Web3(new Account(privateKey)); | ||
+ | </ | ||
+ | |||
+ | ===== Questions ===== | ||
+ | |||
+ | * [[https:// | ||
+ | * How to I get the result of calling an external function with Nethereum? | ||
===== Tool Set Install ===== | ===== Tool Set Install ===== | ||
Line 19: | Line 56: | ||
| ''< | | ''< | ||
| ''< | | ''< | ||
- | | ''< | + | | ''< |
- | | ''< | + | | ''< |
+ | | ''< | ||
+ | | [Truffle Console] ''< | ||
+ | | [Truffle Console] ''< | ||
+ | | [Truffle Console] ''< | ||
+ | | [Truffle Console] ''< | ||
+ | | [Truffle Console] ''< | ||
+ | |||
+ | ===== Implementations of Ethereum blockchange ===== | ||
+ | |||
+ | ^ Implementation ^ Language ^ Pruning ^ Notes ^ | ||
+ | | Geth | Go | Yes | | | ||
+ | | Parity | Rust | Yes | | | ||
+ | | EthereumJ | Java | Yes | | | ||
+ | | Eth | C++ | No | Reference implementation is meant for developers only. | | ||
+ | | PyEthApp | Python | No | | | ||
+ | |||
+ | ===== Glossary ===== | ||
+ | |||
+ | | ABI | Application Binary Interface. Is basically how you call functions in a contract and get data back. Like a WSDL or .h file in C. | | ||
+ | |||
+ | ===== VS Code ===== | ||
+ | |||
+ | Use the [[https:// | ||
+ | * F5 - Compilation of the current contract | ||
+ | * Ctrl + F5 - Compilation of all the contracts | ||
+ | |||
+ | ===== Nethereum ===== | ||
+ | |||
+ | Start with [[https:// | ||
+ | |||
+ | ==== Tutorial ==== | ||
+ | |||
+ | Video is [[https:// | ||
+ | |||
+ | - [VS Code] Write contract | ||
+ | - [VS Code] Compile contract | ||
+ | - [Command Line] Start Geth | ||
+ | - [VS] Create unit test project. | ||
+ | - [VS] NuGet install Nethereum.Web3 + dependencies. | ||
+ | |||
+ | ===== Dev VM ===== | ||
+ | |||
+ | Geth's encrypted accounts key store files can be found in '' | ||
+ | |||
+ | ==== Run Geth ==== | ||
+ | |||
+ | - Open a // | ||
+ | - [ConEmu DOS] Run the command, '' | ||
+ | - Open a // | ||
+ | - [ConEmu PowerShell] Run the command, '' | ||
blockchain.1505981853.txt.gz · Last modified: 2017/09/22 09:17 (external edit)