-
Notifications
You must be signed in to change notification settings - Fork 515
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FABN-1524: Checkpoint contract events (#199)
Signed-off-by: Mark S. Lewis <[email protected]>
- Loading branch information
1 parent
9ba41f8
commit a299938
Showing
10 changed files
with
692 additions
and
409 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/** | ||
* Copyright 2020 IBM All Rights Reserved. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
import { Checkpointer } from './checkpointer'; | ||
|
||
// TODO: Implement, remove @private tag, and export in both index.js and index.d.ts | ||
|
||
/** | ||
* Provides static factory functions used to create instances of default | ||
* {@link module:fabric-network.Checkpointer|Checkpointer} implementations. | ||
* @private | ||
*/ | ||
export class DefaultCheckpointers { | ||
/** | ||
* Create a checkpointer that uses the specified file to store persistent state. If the file does not exist, it will | ||
* be created and the checkpointer will have an uninitialized state that will accept any events. If the file does | ||
* exist, it must contain valid checkpointer state. | ||
* @param {string} path Path to a file holding persistent checkpoint state. | ||
* @returns {Promise<module:fabric-network.Checkpointer>} A checkpointer. | ||
*/ | ||
static async file(path: string): Promise<Checkpointer> { | ||
throw new Error('Not yet implemented'); | ||
// TODO: Create file system checkpointer and call async initialization to load initial state asynchronously | ||
// from the file. | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.