fabric-samples/chaincode
Mark S. Lewis 63cc77bdc3
Avoid usage of deprecated ioutil Go package (#843)
* Refactor Go files
1. replace deprecated ioutil functions (ioutil is deprecated since Go 1.16)
2. fix variable names that collide with imported package name
3. fix typos

Also update Go version specified by Go modules to ensure a Go version is used in which ioutil is deprecated and replacement functions are available in os and io packages.

Signed-off-by: Tommy TIAN <xtianae@connect.ust.hk>
Co-authored-by: Mark S. Lewis <mark_lewis@uk.ibm.com>

* Specify go 1.18 instead of go 1.19 in go.mod files

Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>

Signed-off-by: Tommy TIAN <xtianae@connect.ust.hk>
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
Co-authored-by: Tommy TIAN <xtianae@connect.ust.hk>
2022-10-25 07:04:39 -04:00
..
abstore Avoid usage of deprecated ioutil Go package (#843) 2022-10-25 07:04:39 -04:00
fabcar Avoid usage of deprecated ioutil Go package (#843) 2022-10-25 07:04:39 -04:00
marbles02 Update marbles_chaincode.go 2022-05-09 17:41:43 -04:00
marbles02_private Avoid usage of deprecated ioutil Go package (#843) 2022-10-25 07:04:39 -04:00
sacc Updates to asset-transfer-basic Gateway sample to align with docs (#553) 2021-12-09 10:20:52 +00:00
README.md Add Attribute based access control asset transfer sample 2021-01-13 01:43:15 -05:00

Sample smart contracts

This folder contains example smart contracts. It is recommended that users start with the Asset transfer samples and tutorials series for the most recent example smart contracts.

Smart Contract Description Languages
fabcar Basic smart contract that allows you to add and change data on the ledger using the Fabric contract API. Also contains an example on how to run chaincode as an external service. Go, Java, JavaScript, Typescript
marbles02 Sample that demonstrates how to deploy an index and use rich queries when you are using CouchDB as your state database. Go
marbles02_private Sample that demonstrates the use of private data collections. Go
sacc Simple asset chaincode that interacts with the ledger using the low-level APIs provided by the Fabric Chaincode Shim API. Go
abstore Basic smart contract that allows you to transfer data (from A to B) using the Fabric contract API. Go, Java, JavaScript

License

Hyperledger Project source code files are made available under the Apache License, Version 2.0 (Apache-2.0), located in the LICENSE file. Hyperledger Project documentation files are made available under the Creative Commons Attribution 4.0 International License (CC-BY-4.0), available at http://creativecommons.org/licenses/by/4.0/.