Skip to content
This repository has been archived by the owner on Mar 8, 2020. It is now read-only.

Commit

Permalink
re-brand to Hyperledger Composer (#35)
Browse files Browse the repository at this point in the history
  • Loading branch information
nklincoln committed May 3, 2017
1 parent fd38c13 commit 6d2ad6d
Show file tree
Hide file tree
Showing 49 changed files with 89 additions and 562 deletions.
2 changes: 1 addition & 1 deletion README.md
@@ -1,4 +1,4 @@
# Sample Fabric Composer Business Network Definitions
# Sample Hyperledger Composer Business Network Definitions

You must install [Lerna](https://lernajs.io) to build this multi-package repository.

Expand Down
4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -22,13 +22,13 @@
},
"repository": {
"type": "git",
"url": "https://github.com/fabric-composer/sample-networks.git"
"url": "https://github.com/hyperledger/composer-sample-networks"
},
"keywords": [
"blockchain",
"hyperledger",
"solutions"
],
"author": "Fabric Composer",
"author": "Hyperledger Composer",
"license": "Apache-2.0"
}
4 changes: 2 additions & 2 deletions packages/animaltracking-network/README.md
Expand Up @@ -10,8 +10,8 @@ visibility into the locations of all animals and all animal movements between fa
- Each Field contains a set of Animals owned by the Farmer
- Animals can be transfered between Farmers or between Fields

## Demo inside Playground
Import the sample into Playground using the `Import/Replace` button.
## Demo inside Hyperledger Composer
Import the sample into Hyperledger Composer using the `Import/Replace` button.

Submit a `SetupDemo` transaction to bootstrap a scenario to get you started.

Expand Down
2 changes: 1 addition & 1 deletion packages/animaltracking-network/jsdoc.conf
Expand Up @@ -19,7 +19,7 @@
"outputSourcePath": true,
"systemName": "Animal Tracking Network",
"footer": "",
"copyright": "Copyright IBM Corp. 2016",
"copyright": "Released under the Apache License v2.0",
"navType": "vertical",
"theme": "spacelab",
"linenums": true,
Expand Down
16 changes: 8 additions & 8 deletions packages/animaltracking-network/lib/mozart.cto.js
Expand Up @@ -19,7 +19,7 @@

/**
*
* @param {com.ibm.concerto.mozart.AnimalMovementDeparture} movementDeparture
* @param {com.biz.AnimalMovementDeparture} movementDeparture
* @transaction
*/
function onAnimalMovementDeparture(movementDeparture) {
Expand All @@ -32,7 +32,7 @@ function onAnimalMovementDeparture(movementDeparture) {
movementDeparture.animal.movementStatus = 'IN_TRANSIT';

// save the animal
return getAssetRegistry('com.ibm.concerto.mozart.Animal')
return getAssetRegistry('com.biz.Animal')
.then(function(ar) {
return ar.update(movementDeparture.animal);
})
Expand All @@ -46,7 +46,7 @@ function onAnimalMovementDeparture(movementDeparture) {
}

// save the business
return getAssetRegistry('com.ibm.concerto.mozart.Business')
return getAssetRegistry('com.biz.Business')
})
.then(function(br) {
return br.update(movementDeparture.to);
Expand All @@ -55,7 +55,7 @@ function onAnimalMovementDeparture(movementDeparture) {

/**
*
* @param {com.ibm.concerto.mozart.AnimalMovementArrival} movementArrival
* @param {com.biz.AnimalMovementArrival} movementArrival
* @transaction
*/
function onAnimalMovementArrival(movementArrival) {
Expand All @@ -76,7 +76,7 @@ function onAnimalMovementArrival(movementArrival) {
movementArrival.animal.location = movementArrival.arrivalField;

// save the animal
return getAssetRegistry('com.ibm.concerto.mozart.Animal')
return getAssetRegistry('com.biz.Animal')
.then(function(ar) {
return ar.update(movementArrival.animal);
})
Expand All @@ -93,7 +93,7 @@ function onAnimalMovementArrival(movementArrival) {
});

// save the business
return getAssetRegistry('com.ibm.concerto.mozart.Business');
return getAssetRegistry('com.biz.Business');
})
.then(function(br) {
return br.update(movementArrival.to);
Expand All @@ -102,12 +102,12 @@ function onAnimalMovementArrival(movementArrival) {

/**
*
* @param {com.ibm.concerto.mozart.SetupDemo} setupDemo
* @param {com.biz.SetupDemo} setupDemo
* @transaction
*/
function setupDemo(setupDemo) {
var factory = getFactory();
var NS = 'com.ibm.concerto.mozart';
var NS = 'com.biz';

var farmers = [
factory.newResource(NS, 'Farmer', 'FARMER_1'),
Expand Down
4 changes: 2 additions & 2 deletions packages/animaltracking-network/package.json
Expand Up @@ -14,9 +14,9 @@
},
"repository": {
"type": "git",
"url": "https://github.com/fabric-composer/fabric-composer.git"
"url": "https://github.com/hyperledger/composer"
},
"author": "Fabric Composer",
"author": "Hyperledger Composer",
"license": "Apache-2.0",
"keywords": [
"defra",
Expand Down
23 changes: 0 additions & 23 deletions packages/basic-sample-network/.travis.yml

This file was deleted.

10 changes: 5 additions & 5 deletions packages/basic-sample-network/README.md
@@ -1,17 +1,17 @@
# Welcome to Fabric Composer!
# Welcome to Hyperledger Composer!

This is the "Hello World" of Composer samples.
This is the "Hello World" of Hyperledger Composer samples.

This sample defines a business network composed of a single asset type (`SampleAsset`), a single participant type (`SampleParticipant`), and a single transaction type (`SampleTransaction`).

`SampleAssets` are owned by a `SampleParticipant`, and the value property on a `SampleAsset` can be modified by submitting a `SampleTransaction`.

To get started inside the Composer Playground you can click the Test tab and create instances of `SampleAsset` and `SampleParticipant`. Make sure that the owner property on the `SampleAsset` refers to a `SampleParticipant` that you have created.
To get started inside Hyperledger Composer you can click the Test tab and create instances of `SampleAsset` and `SampleParticipant`. Make sure that the owner property on the `SampleAsset` refers to a `SampleParticipant` that you have created.

You can then submit a `SampleTransaction`, making sure that the asset property refers to an asset that you created earlier. After the transaction has been processed you should see that the value property on the asset has been modified.

The logic for updating the asset when a `SampleTransaction` is processed is written in `logic.js`.

Don't forget you can import more advanced samples into the Composer Playground using the Import/Replace button.
Don't forget you can import more advanced samples into Hyperledger Composer using the Import/Replace button.

Have fun learning Fabric Composer!
Have fun learning Hyperledger Composer!
2 changes: 1 addition & 1 deletion packages/basic-sample-network/jsdoc.conf
Expand Up @@ -19,7 +19,7 @@
"outputSourcePath": true,
"systemName": "Sample Network",
"footer": "",
"copyright": "Copyright IBM Corp. 2016",
"copyright": "Released under the Apache License v2.0",
"navType": "vertical",
"theme": "spacelab",
"linenums": true,
Expand Down
6 changes: 3 additions & 3 deletions packages/basic-sample-network/package.json
@@ -1,7 +1,7 @@
{
"name": "basic-sample-network",
"version": "0.0.7",
"description": "The Hello World of Fabric Composer samples",
"description": "The Hello World of Hyperledger Composer samples",
"scripts": {
"prepublish": "mkdirp ./dist && composer archive create --sourceType dir --sourceName . -a ./dist/basic-sample-network.bna",
"pretest": "npm run lint",
Expand All @@ -15,13 +15,13 @@
},
"repository": {
"type": "git",
"url": "https://github.com/fabric-composer/sample-networks.git"
"url": "https://github.com/hyperledger/composer-sample-networks.git"
},
"keywords": [
"sample",
"network"
],
"author": "Fabric Composer",
"author": "Hyperledger Composer",
"license": "Apache-2.0",
"devDependencies": {
"browserfs": "^1.2.0",
Expand Down
35 changes: 0 additions & 35 deletions packages/basic-sample-network/scripts/deploy.sh

This file was deleted.

32 changes: 0 additions & 32 deletions packages/basic-sample-network/scripts/timestamp.js

This file was deleted.

2 changes: 1 addition & 1 deletion packages/basic-sample-network/test/Sample.js
Expand Up @@ -57,7 +57,7 @@ describe('Sample', () => {
const factory = businessNetworkConnection.getBusinessNetwork().getFactory();

// create the sample participant
const dan = factory.newResource(NS, 'SampleParticipant', 'daniel.selman@uk.ibm.com');
const dan = factory.newResource(NS, 'SampleParticipant', 'a.person@example.com');
dan.firstName = 'Dan';
dan.lastName = 'Selman';

Expand Down
23 changes: 0 additions & 23 deletions packages/bond-network/.travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion packages/bond-network/README.md
@@ -1,4 +1,4 @@
# Fabric Composer Bond Reference Data Demo
# Hyperledger Composer Bond Reference Data Demo

Example business network that stores information about financial bonds on the blockchain. It allows
the issuer of a bond to update the bond information whilst other members of the business network can
Expand Down
2 changes: 1 addition & 1 deletion packages/bond-network/jsdoc.conf
Expand Up @@ -19,7 +19,7 @@
"outputSourcePath": true,
"systemName": "Financial Bond Network",
"footer": "",
"copyright": "Copyright IBM Corp. 2016",
"copyright": "Released under the Apache License v2.0",
"navType": "vertical",
"theme": "spacelab",
"linenums": true,
Expand Down
4 changes: 2 additions & 2 deletions packages/bond-network/package.json
Expand Up @@ -15,14 +15,14 @@
},
"repository": {
"type": "git",
"url": "https://github.com/fabric-composer/sample-networks.git"
"url": "https://github.com/hyperledger/composer-sample-networks.git"
},
"keywords": [
"bonds",
"reference data",
"finance"
],
"author": "Fabric Composer",
"author": "Hyperledger Composer",
"license": "Apache-2.0",
"devDependencies": {
"browserfs": "^1.2.0",
Expand Down
35 changes: 0 additions & 35 deletions packages/bond-network/scripts/deploy.sh

This file was deleted.

0 comments on commit 6d2ad6d

Please sign in to comment.